Method ReadPageAsync
- Namespace
- MailFathom.Application.Mail.Delivery.Tracking
- Assembly
- MailFathom.Application.dll
ReadPageAsync(MailAccountSelector, OutgoingEmailStage?, int?, OutboxCursor?, CancellationToken)
Reads one page of what the named account of this user is sending, newest first.
public Task<UserOutboxPageResult> ReadPageAsync(MailAccountSelector account, OutgoingEmailStage? stage, int? pageSize, OutboxCursor? cursor, CancellationToken cancellationToken)
Parameters
accountMailAccountSelectorThe account to read, which is required rather than optional.
stageOutgoingEmailStage?The stage to narrow to, or null for every stage.
pageSizeint?How many sends the page may hold, or null for the default.
cursorOutboxCursor?The cursor the previous page returned, or null for the first page.
cancellationTokenCancellationTokenCancels the read.
Returns
- Task<UserOutboxPageResult>
The page, or the reason the request named none.
Exceptions
- PrincipalNotAuthorizedException
Thrown when the caller does not hold MailSend, or is acting for no user.
- MailAccountNotAccessibleException
Thrown when
accountnames an account the caller's user is not assigned.