Class WaitForControllerApi
Represents a collection of functions to interact with the API endpoints
Inherited Members
Namespace: mailslurp.Api
Assembly: mailslurp.dll
Syntax
public class WaitForControllerApi : IWaitForControllerApi, IWaitForControllerApiSync, IWaitForControllerApiAsync, IApiAccessor
Constructors
View SourceWaitForControllerApi()
Initializes a new instance of the WaitForControllerApi class.
Declaration
public WaitForControllerApi()
WaitForControllerApi(Configuration)
Initializes a new instance of the WaitForControllerApi class using Configuration object
Declaration
public WaitForControllerApi(Configuration configuration)
Parameters
Type | Name | Description |
---|---|---|
Configuration | configuration | An instance of Configuration |
WaitForControllerApi(ISynchronousClient, IAsynchronousClient, IReadableConfiguration)
Initializes a new instance of the WaitForControllerApi class using a Configuration object and client instance.
Declaration
public WaitForControllerApi(ISynchronousClient client, IAsynchronousClient asyncClient, IReadableConfiguration configuration)
Parameters
Type | Name | Description |
---|---|---|
ISynchronousClient | client | The client interface for synchronous API access. |
IAsynchronousClient | asyncClient | The client interface for asynchronous API access. |
IReadableConfiguration | configuration | The configuration object. |
WaitForControllerApi(string)
Initializes a new instance of the WaitForControllerApi class.
Declaration
public WaitForControllerApi(string basePath)
Parameters
Type | Name | Description |
---|---|---|
string | basePath |
Properties
View SourceAsynchronousClient
The client for accessing this underlying API asynchronously.
Declaration
public IAsynchronousClient AsynchronousClient { get; set; }
Property Value
Type | Description |
---|---|
IAsynchronousClient |
Client
The client for accessing this underlying API synchronously.
Declaration
public ISynchronousClient Client { get; set; }
Property Value
Type | Description |
---|---|
ISynchronousClient |
Configuration
Gets or sets the configuration object
Declaration
public IReadableConfiguration Configuration { get; set; }
Property Value
Type | Description |
---|---|
IReadableConfiguration | An instance of the Configuration |
ExceptionFactory
Provides a factory method hook for the creation of exceptions.
Declaration
public ExceptionFactory ExceptionFactory { get; set; }
Property Value
Type | Description |
---|---|
ExceptionFactory |
Methods
View SourceGetBasePath()
Gets the base path of the API client.
Declaration
public string GetBasePath()
Returns
Type | Description |
---|---|
string | The base path |
WaitFor(WaitForConditions, int)
Wait for an email to match the provided filter conditions such as subject contains keyword. Generic waitFor method that will wait until an inbox meets given conditions or return immediately if already met
Declaration
public List<EmailPreview> WaitFor(WaitForConditions waitForConditions, int operationIndex = 0)
Parameters
Type | Name | Description |
---|---|---|
WaitForConditions | waitForConditions | |
int | operationIndex | Index associated with the operation. |
Returns
Type | Description |
---|---|
System.Collections.Generic.List<T><EmailPreview> | List<EmailPreview> |
Exceptions
Type | Condition |
---|---|
ApiException | Thrown when fails to make API call |
WaitForAsync(WaitForConditions, int, CancellationToken)
Wait for an email to match the provided filter conditions such as subject contains keyword. Generic waitFor method that will wait until an inbox meets given conditions or return immediately if already met
Declaration
public Task<List<EmailPreview>> WaitForAsync(WaitForConditions waitForConditions, int operationIndex = 0, CancellationToken cancellationToken = default)
Parameters
Type | Name | Description |
---|---|---|
WaitForConditions | waitForConditions | |
int | operationIndex | Index associated with the operation. |
CancellationToken | cancellationToken | Cancellation Token to cancel the request. |
Returns
Type | Description |
---|---|
Task<System.Collections.Generic.List<T><EmailPreview>> | Task of List<EmailPreview> |
Exceptions
Type | Condition |
---|---|
ApiException | Thrown when fails to make API call |
WaitForEmailCount(Guid, int, long?, bool?, DateTime?, DateTime?, string, long?, int)
Wait for and return count number of emails. Hold connection until inbox count matches expected or timeout occurs If inbox contains count or more emails at time of request then return count worth of emails. If not wait until the count is reached and return those or return an error if timeout is exceeded.
Declaration
public List<EmailPreview> WaitForEmailCount(Guid inboxId, int count, long? timeout = null, bool? unreadOnly = null, DateTime? before = null, DateTime? since = null, string sort = null, long? delay = null, int operationIndex = 0)
Parameters
Type | Name | Description |
---|---|---|
System.Guid | inboxId | Id of the inbox we are fetching emails from |
int | count | Number of emails to wait for. Must be greater that 1 |
long? | timeout | Max milliseconds to wait (optional) |
bool? | unreadOnly | Optional filter for unread only (optional, default to false) |
DateTime? | before | Filter for emails that were received before the given timestamp (optional) |
DateTime? | since | Filter for emails that were received after the given timestamp (optional) |
string | sort | Sort direction (optional) |
long? | delay | Max milliseconds delay between calls (optional) |
int | operationIndex | Index associated with the operation. |
Returns
Type | Description |
---|---|
System.Collections.Generic.List<T><EmailPreview> | List<EmailPreview> |
Exceptions
Type | Condition |
---|---|
ApiException | Thrown when fails to make API call |
WaitForEmailCountAsync(Guid, int, long?, bool?, DateTime?, DateTime?, string, long?, int, CancellationToken)
Wait for and return count number of emails. Hold connection until inbox count matches expected or timeout occurs If inbox contains count or more emails at time of request then return count worth of emails. If not wait until the count is reached and return those or return an error if timeout is exceeded.
Declaration
public Task<List<EmailPreview>> WaitForEmailCountAsync(Guid inboxId, int count, long? timeout = null, bool? unreadOnly = null, DateTime? before = null, DateTime? since = null, string sort = null, long? delay = null, int operationIndex = 0, CancellationToken cancellationToken = default)
Parameters
Type | Name | Description |
---|---|---|
System.Guid | inboxId | Id of the inbox we are fetching emails from |
int | count | Number of emails to wait for. Must be greater that 1 |
long? | timeout | Max milliseconds to wait (optional) |
bool? | unreadOnly | Optional filter for unread only (optional, default to false) |
DateTime? | before | Filter for emails that were received before the given timestamp (optional) |
DateTime? | since | Filter for emails that were received after the given timestamp (optional) |
string | sort | Sort direction (optional) |
long? | delay | Max milliseconds delay between calls (optional) |
int | operationIndex | Index associated with the operation. |
CancellationToken | cancellationToken | Cancellation Token to cancel the request. |
Returns
Type | Description |
---|---|
Task<System.Collections.Generic.List<T><EmailPreview>> | Task of List<EmailPreview> |
Exceptions
Type | Condition |
---|---|
ApiException | Thrown when fails to make API call |
WaitForEmailCountWithHttpInfo(Guid, int, long?, bool?, DateTime?, DateTime?, string, long?, int)
Wait for and return count number of emails. Hold connection until inbox count matches expected or timeout occurs If inbox contains count or more emails at time of request then return count worth of emails. If not wait until the count is reached and return those or return an error if timeout is exceeded.
Declaration
public ApiResponse<List<EmailPreview>> WaitForEmailCountWithHttpInfo(Guid inboxId, int count, long? timeout = null, bool? unreadOnly = null, DateTime? before = null, DateTime? since = null, string sort = null, long? delay = null, int operationIndex = 0)
Parameters
Type | Name | Description |
---|---|---|
System.Guid | inboxId | Id of the inbox we are fetching emails from |
int | count | Number of emails to wait for. Must be greater that 1 |
long? | timeout | Max milliseconds to wait (optional) |
bool? | unreadOnly | Optional filter for unread only (optional, default to false) |
DateTime? | before | Filter for emails that were received before the given timestamp (optional) |
DateTime? | since | Filter for emails that were received after the given timestamp (optional) |
string | sort | Sort direction (optional) |
long? | delay | Max milliseconds delay between calls (optional) |
int | operationIndex | Index associated with the operation. |
Returns
Type | Description |
---|---|
ApiResponse<System.Collections.Generic.List<T><EmailPreview>> | ApiResponse of List<EmailPreview> |
Exceptions
Type | Condition |
---|---|
ApiException | Thrown when fails to make API call |
WaitForEmailCountWithHttpInfoAsync(Guid, int, long?, bool?, DateTime?, DateTime?, string, long?, int, CancellationToken)
Wait for and return count number of emails. Hold connection until inbox count matches expected or timeout occurs If inbox contains count or more emails at time of request then return count worth of emails. If not wait until the count is reached and return those or return an error if timeout is exceeded.
Declaration
public Task<ApiResponse<List<EmailPreview>>> WaitForEmailCountWithHttpInfoAsync(Guid inboxId, int count, long? timeout = null, bool? unreadOnly = null, DateTime? before = null, DateTime? since = null, string sort = null, long? delay = null, int operationIndex = 0, CancellationToken cancellationToken = default)
Parameters
Type | Name | Description |
---|---|---|
System.Guid | inboxId | Id of the inbox we are fetching emails from |
int | count | Number of emails to wait for. Must be greater that 1 |
long? | timeout | Max milliseconds to wait (optional) |
bool? | unreadOnly | Optional filter for unread only (optional, default to false) |
DateTime? | before | Filter for emails that were received before the given timestamp (optional) |
DateTime? | since | Filter for emails that were received after the given timestamp (optional) |
string | sort | Sort direction (optional) |
long? | delay | Max milliseconds delay between calls (optional) |
int | operationIndex | Index associated with the operation. |
CancellationToken | cancellationToken | Cancellation Token to cancel the request. |
Returns
Type | Description |
---|---|
Task<ApiResponse<System.Collections.Generic.List<T><EmailPreview>>> | Task of ApiResponse (List<EmailPreview>) |
Exceptions
Type | Condition |
---|---|
ApiException | Thrown when fails to make API call |
WaitForLatestEmail(Guid?, long?, bool?, DateTime?, DateTime?, string, long?, int)
Fetch inbox's latest email or if empty wait for an email to arrive Will return either the last received email or wait for an email to arrive and return that. If you need to wait for an email for a non-empty inbox set unreadOnly=true
or see the other receive methods such as waitForNthEmail
or waitForEmailCount
.
Declaration
public Email WaitForLatestEmail(Guid? inboxId = null, long? timeout = null, bool? unreadOnly = null, DateTime? before = null, DateTime? since = null, string sort = null, long? delay = null, int operationIndex = 0)
Parameters
Type | Name | Description |
---|---|---|
System.Guid? | inboxId | Id of the inbox we are fetching emails from (optional) |
long? | timeout | Max milliseconds to wait (optional) |
bool? | unreadOnly | Optional filter for unread only. (optional, default to false) |
DateTime? | before | Filter for emails that were before after the given timestamp (optional) |
DateTime? | since | Filter for emails that were received after the given timestamp (optional) |
string | sort | Sort direction (optional) |
long? | delay | Max milliseconds delay between calls (optional) |
int | operationIndex | Index associated with the operation. |
Returns
Type | Description |
---|---|
Exceptions
Type | Condition |
---|---|
ApiException | Thrown when fails to make API call |
WaitForLatestEmailAsync(Guid?, long?, bool?, DateTime?, DateTime?, string, long?, int, CancellationToken)
Fetch inbox's latest email or if empty wait for an email to arrive Will return either the last received email or wait for an email to arrive and return that. If you need to wait for an email for a non-empty inbox set unreadOnly=true
or see the other receive methods such as waitForNthEmail
or waitForEmailCount
.
Declaration
public Task<Email> WaitForLatestEmailAsync(Guid? inboxId = null, long? timeout = null, bool? unreadOnly = null, DateTime? before = null, DateTime? since = null, string sort = null, long? delay = null, int operationIndex = 0, CancellationToken cancellationToken = default)
Parameters
Type | Name | Description |
---|---|---|
System.Guid? | inboxId | Id of the inbox we are fetching emails from (optional) |
long? | timeout | Max milliseconds to wait (optional) |
bool? | unreadOnly | Optional filter for unread only. (optional, default to false) |
DateTime? | before | Filter for emails that were before after the given timestamp (optional) |
DateTime? | since | Filter for emails that were received after the given timestamp (optional) |
string | sort | Sort direction (optional) |
long? | delay | Max milliseconds delay between calls (optional) |
int | operationIndex | Index associated with the operation. |
CancellationToken | cancellationToken | Cancellation Token to cancel the request. |
Returns
Type | Description |
---|---|
Task<Email> | Task of Email |
Exceptions
Type | Condition |
---|---|
ApiException | Thrown when fails to make API call |
WaitForLatestEmailWithHttpInfo(Guid?, long?, bool?, DateTime?, DateTime?, string, long?, int)
Fetch inbox's latest email or if empty wait for an email to arrive Will return either the last received email or wait for an email to arrive and return that. If you need to wait for an email for a non-empty inbox set unreadOnly=true
or see the other receive methods such as waitForNthEmail
or waitForEmailCount
.
Declaration
public ApiResponse<Email> WaitForLatestEmailWithHttpInfo(Guid? inboxId = null, long? timeout = null, bool? unreadOnly = null, DateTime? before = null, DateTime? since = null, string sort = null, long? delay = null, int operationIndex = 0)
Parameters
Type | Name | Description |
---|---|---|
System.Guid? | inboxId | Id of the inbox we are fetching emails from (optional) |
long? | timeout | Max milliseconds to wait (optional) |
bool? | unreadOnly | Optional filter for unread only. (optional, default to false) |
DateTime? | before | Filter for emails that were before after the given timestamp (optional) |
DateTime? | since | Filter for emails that were received after the given timestamp (optional) |
string | sort | Sort direction (optional) |
long? | delay | Max milliseconds delay between calls (optional) |
int | operationIndex | Index associated with the operation. |
Returns
Type | Description |
---|---|
ApiResponse<Email> | ApiResponse of Email |
Exceptions
Type | Condition |
---|---|
ApiException | Thrown when fails to make API call |
WaitForLatestEmailWithHttpInfoAsync(Guid?, long?, bool?, DateTime?, DateTime?, string, long?, int, CancellationToken)
Fetch inbox's latest email or if empty wait for an email to arrive Will return either the last received email or wait for an email to arrive and return that. If you need to wait for an email for a non-empty inbox set unreadOnly=true
or see the other receive methods such as waitForNthEmail
or waitForEmailCount
.
Declaration
public Task<ApiResponse<Email>> WaitForLatestEmailWithHttpInfoAsync(Guid? inboxId = null, long? timeout = null, bool? unreadOnly = null, DateTime? before = null, DateTime? since = null, string sort = null, long? delay = null, int operationIndex = 0, CancellationToken cancellationToken = default)
Parameters
Type | Name | Description |
---|---|---|
System.Guid? | inboxId | Id of the inbox we are fetching emails from (optional) |
long? | timeout | Max milliseconds to wait (optional) |
bool? | unreadOnly | Optional filter for unread only. (optional, default to false) |
DateTime? | before | Filter for emails that were before after the given timestamp (optional) |
DateTime? | since | Filter for emails that were received after the given timestamp (optional) |
string | sort | Sort direction (optional) |
long? | delay | Max milliseconds delay between calls (optional) |
int | operationIndex | Index associated with the operation. |
CancellationToken | cancellationToken | Cancellation Token to cancel the request. |
Returns
Type | Description |
---|---|
Task<ApiResponse<Email>> | Task of ApiResponse (Email) |
Exceptions
Type | Condition |
---|---|
ApiException | Thrown when fails to make API call |
WaitForLatestSms(WaitForSingleSmsOptions, int)
Wait for the latest SMS message to match the provided filter conditions such as body contains keyword. Wait until a phone number meets given conditions or return immediately if already met
Declaration
public SmsDto WaitForLatestSms(WaitForSingleSmsOptions waitForSingleSmsOptions, int operationIndex = 0)
Parameters
Type | Name | Description |
---|---|---|
WaitForSingleSmsOptions | waitForSingleSmsOptions | |
int | operationIndex | Index associated with the operation. |
Returns
Type | Description |
---|---|
SmsDto | SmsDto |
Exceptions
Type | Condition |
---|---|
ApiException | Thrown when fails to make API call |
WaitForLatestSmsAsync(WaitForSingleSmsOptions, int, CancellationToken)
Wait for the latest SMS message to match the provided filter conditions such as body contains keyword. Wait until a phone number meets given conditions or return immediately if already met
Declaration
public Task<SmsDto> WaitForLatestSmsAsync(WaitForSingleSmsOptions waitForSingleSmsOptions, int operationIndex = 0, CancellationToken cancellationToken = default)
Parameters
Type | Name | Description |
---|---|---|
WaitForSingleSmsOptions | waitForSingleSmsOptions | |
int | operationIndex | Index associated with the operation. |
CancellationToken | cancellationToken | Cancellation Token to cancel the request. |
Returns
Type | Description |
---|---|
Task<SmsDto> | Task of SmsDto |
Exceptions
Type | Condition |
---|---|
ApiException | Thrown when fails to make API call |
WaitForLatestSmsWithHttpInfo(WaitForSingleSmsOptions, int)
Wait for the latest SMS message to match the provided filter conditions such as body contains keyword. Wait until a phone number meets given conditions or return immediately if already met
Declaration
public ApiResponse<SmsDto> WaitForLatestSmsWithHttpInfo(WaitForSingleSmsOptions waitForSingleSmsOptions, int operationIndex = 0)
Parameters
Type | Name | Description |
---|---|---|
WaitForSingleSmsOptions | waitForSingleSmsOptions | |
int | operationIndex | Index associated with the operation. |
Returns
Type | Description |
---|---|
ApiResponse<SmsDto> | ApiResponse of SmsDto |
Exceptions
Type | Condition |
---|---|
ApiException | Thrown when fails to make API call |
WaitForLatestSmsWithHttpInfoAsync(WaitForSingleSmsOptions, int, CancellationToken)
Wait for the latest SMS message to match the provided filter conditions such as body contains keyword. Wait until a phone number meets given conditions or return immediately if already met
Declaration
public Task<ApiResponse<SmsDto>> WaitForLatestSmsWithHttpInfoAsync(WaitForSingleSmsOptions waitForSingleSmsOptions, int operationIndex = 0, CancellationToken cancellationToken = default)
Parameters
Type | Name | Description |
---|---|---|
WaitForSingleSmsOptions | waitForSingleSmsOptions | |
int | operationIndex | Index associated with the operation. |
CancellationToken | cancellationToken | Cancellation Token to cancel the request. |
Returns
Type | Description |
---|---|
Task<ApiResponse<SmsDto>> | Task of ApiResponse (SmsDto) |
Exceptions
Type | Condition |
---|---|
ApiException | Thrown when fails to make API call |
WaitForMatchingEmails(Guid, int, MatchOptions, DateTime?, DateTime?, string, long?, long?, bool?, int)
Wait or return list of emails that match simple matching patterns Perform a search of emails in an inbox with the given patterns. If results match expected count then return or else retry the search until results are found or timeout is reached. Match options allow simple CONTAINS or EQUALS filtering on SUBJECT, TO, BCC, CC, and FROM. See the MatchOptions
object for options. An example payload is { matches: [{field: 'SUBJECT',should:'CONTAIN',value:'needle'}] }
. You can use an array of matches and they will be applied sequentially to filter out emails. If you want to perform matches and extractions of content using Regex patterns see the EmailController getEmailContentMatch
method.
Declaration
public List<EmailPreview> WaitForMatchingEmails(Guid inboxId, int count, MatchOptions matchOptions, DateTime? before = null, DateTime? since = null, string sort = null, long? delay = null, long? timeout = null, bool? unreadOnly = null, int operationIndex = 0)
Parameters
Type | Name | Description |
---|---|---|
System.Guid | inboxId | Id of the inbox we are fetching emails from |
int | count | Number of emails to wait for. Must be greater or equal to 1 |
MatchOptions | matchOptions | |
DateTime? | before | Filter for emails that were received before the given timestamp (optional) |
DateTime? | since | Filter for emails that were received after the given timestamp (optional) |
string | sort | Sort direction (optional) |
long? | delay | Max milliseconds delay between calls (optional) |
long? | timeout | Max milliseconds to wait (optional) |
bool? | unreadOnly | Optional filter for unread only (optional, default to false) |
int | operationIndex | Index associated with the operation. |
Returns
Type | Description |
---|---|
System.Collections.Generic.List<T><EmailPreview> | List<EmailPreview> |
Exceptions
Type | Condition |
---|---|
ApiException | Thrown when fails to make API call |
WaitForMatchingEmailsAsync(Guid, int, MatchOptions, DateTime?, DateTime?, string, long?, long?, bool?, int, CancellationToken)
Wait or return list of emails that match simple matching patterns Perform a search of emails in an inbox with the given patterns. If results match expected count then return or else retry the search until results are found or timeout is reached. Match options allow simple CONTAINS or EQUALS filtering on SUBJECT, TO, BCC, CC, and FROM. See the MatchOptions
object for options. An example payload is { matches: [{field: 'SUBJECT',should:'CONTAIN',value:'needle'}] }
. You can use an array of matches and they will be applied sequentially to filter out emails. If you want to perform matches and extractions of content using Regex patterns see the EmailController getEmailContentMatch
method.
Declaration
public Task<List<EmailPreview>> WaitForMatchingEmailsAsync(Guid inboxId, int count, MatchOptions matchOptions, DateTime? before = null, DateTime? since = null, string sort = null, long? delay = null, long? timeout = null, bool? unreadOnly = null, int operationIndex = 0, CancellationToken cancellationToken = default)
Parameters
Type | Name | Description |
---|---|---|
System.Guid | inboxId | Id of the inbox we are fetching emails from |
int | count | Number of emails to wait for. Must be greater or equal to 1 |
MatchOptions | matchOptions | |
DateTime? | before | Filter for emails that were received before the given timestamp (optional) |
DateTime? | since | Filter for emails that were received after the given timestamp (optional) |
string | sort | Sort direction (optional) |
long? | delay | Max milliseconds delay between calls (optional) |
long? | timeout | Max milliseconds to wait (optional) |
bool? | unreadOnly | Optional filter for unread only (optional, default to false) |
int | operationIndex | Index associated with the operation. |
CancellationToken | cancellationToken | Cancellation Token to cancel the request. |
Returns
Type | Description |
---|---|
Task<System.Collections.Generic.List<T><EmailPreview>> | Task of List<EmailPreview> |
Exceptions
Type | Condition |
---|---|
ApiException | Thrown when fails to make API call |
WaitForMatchingEmailsWithHttpInfo(Guid, int, MatchOptions, DateTime?, DateTime?, string, long?, long?, bool?, int)
Wait or return list of emails that match simple matching patterns Perform a search of emails in an inbox with the given patterns. If results match expected count then return or else retry the search until results are found or timeout is reached. Match options allow simple CONTAINS or EQUALS filtering on SUBJECT, TO, BCC, CC, and FROM. See the MatchOptions
object for options. An example payload is { matches: [{field: 'SUBJECT',should:'CONTAIN',value:'needle'}] }
. You can use an array of matches and they will be applied sequentially to filter out emails. If you want to perform matches and extractions of content using Regex patterns see the EmailController getEmailContentMatch
method.
Declaration
public ApiResponse<List<EmailPreview>> WaitForMatchingEmailsWithHttpInfo(Guid inboxId, int count, MatchOptions matchOptions, DateTime? before = null, DateTime? since = null, string sort = null, long? delay = null, long? timeout = null, bool? unreadOnly = null, int operationIndex = 0)
Parameters
Type | Name | Description |
---|---|---|
System.Guid | inboxId | Id of the inbox we are fetching emails from |
int | count | Number of emails to wait for. Must be greater or equal to 1 |
MatchOptions | matchOptions | |
DateTime? | before | Filter for emails that were received before the given timestamp (optional) |
DateTime? | since | Filter for emails that were received after the given timestamp (optional) |
string | sort | Sort direction (optional) |
long? | delay | Max milliseconds delay between calls (optional) |
long? | timeout | Max milliseconds to wait (optional) |
bool? | unreadOnly | Optional filter for unread only (optional, default to false) |
int | operationIndex | Index associated with the operation. |
Returns
Type | Description |
---|---|
ApiResponse<System.Collections.Generic.List<T><EmailPreview>> | ApiResponse of List<EmailPreview> |
Exceptions
Type | Condition |
---|---|
ApiException | Thrown when fails to make API call |
WaitForMatchingEmailsWithHttpInfoAsync(Guid, int, MatchOptions, DateTime?, DateTime?, string, long?, long?, bool?, int, CancellationToken)
Wait or return list of emails that match simple matching patterns Perform a search of emails in an inbox with the given patterns. If results match expected count then return or else retry the search until results are found or timeout is reached. Match options allow simple CONTAINS or EQUALS filtering on SUBJECT, TO, BCC, CC, and FROM. See the MatchOptions
object for options. An example payload is { matches: [{field: 'SUBJECT',should:'CONTAIN',value:'needle'}] }
. You can use an array of matches and they will be applied sequentially to filter out emails. If you want to perform matches and extractions of content using Regex patterns see the EmailController getEmailContentMatch
method.
Declaration
public Task<ApiResponse<List<EmailPreview>>> WaitForMatchingEmailsWithHttpInfoAsync(Guid inboxId, int count, MatchOptions matchOptions, DateTime? before = null, DateTime? since = null, string sort = null, long? delay = null, long? timeout = null, bool? unreadOnly = null, int operationIndex = 0, CancellationToken cancellationToken = default)
Parameters
Type | Name | Description |
---|---|---|
System.Guid | inboxId | Id of the inbox we are fetching emails from |
int | count | Number of emails to wait for. Must be greater or equal to 1 |
MatchOptions | matchOptions | |
DateTime? | before | Filter for emails that were received before the given timestamp (optional) |
DateTime? | since | Filter for emails that were received after the given timestamp (optional) |
string | sort | Sort direction (optional) |
long? | delay | Max milliseconds delay between calls (optional) |
long? | timeout | Max milliseconds to wait (optional) |
bool? | unreadOnly | Optional filter for unread only (optional, default to false) |
int | operationIndex | Index associated with the operation. |
CancellationToken | cancellationToken | Cancellation Token to cancel the request. |
Returns
Type | Description |
---|---|
Task<ApiResponse<System.Collections.Generic.List<T><EmailPreview>>> | Task of ApiResponse (List<EmailPreview>) |
Exceptions
Type | Condition |
---|---|
ApiException | Thrown when fails to make API call |
WaitForMatchingFirstEmail(Guid, MatchOptions, long?, bool?, DateTime?, DateTime?, string, long?, int)
Wait for or return the first email that matches provided MatchOptions array Perform a search of emails in an inbox with the given patterns. If a result if found then return or else retry the search until a result is found or timeout is reached. Match options allow simple CONTAINS or EQUALS filtering on SUBJECT, TO, BCC, CC, and FROM. See the MatchOptions
object for options. An example payload is { matches: [{field: 'SUBJECT',should:'CONTAIN',value:'needle'}] }
. You can use an array of matches and they will be applied sequentially to filter out emails. If you want to perform matches and extractions of content using Regex patterns see the EmailController getEmailContentMatch
method.
Declaration
public Email WaitForMatchingFirstEmail(Guid inboxId, MatchOptions matchOptions, long? timeout = null, bool? unreadOnly = null, DateTime? since = null, DateTime? before = null, string sort = null, long? delay = null, int operationIndex = 0)
Parameters
Type | Name | Description |
---|---|---|
System.Guid | inboxId | Id of the inbox we are matching an email for |
MatchOptions | matchOptions | |
long? | timeout | Max milliseconds to wait (optional) |
bool? | unreadOnly | Optional filter for unread only (optional, default to false) |
DateTime? | since | Filter for emails that were received after the given timestamp (optional) |
DateTime? | before | Filter for emails that were received before the given timestamp (optional) |
string | sort | Sort direction (optional) |
long? | delay | Max milliseconds delay between calls (optional) |
int | operationIndex | Index associated with the operation. |
Returns
Type | Description |
---|---|
Exceptions
Type | Condition |
---|---|
ApiException | Thrown when fails to make API call |
WaitForMatchingFirstEmailAsync(Guid, MatchOptions, long?, bool?, DateTime?, DateTime?, string, long?, int, CancellationToken)
Wait for or return the first email that matches provided MatchOptions array Perform a search of emails in an inbox with the given patterns. If a result if found then return or else retry the search until a result is found or timeout is reached. Match options allow simple CONTAINS or EQUALS filtering on SUBJECT, TO, BCC, CC, and FROM. See the MatchOptions
object for options. An example payload is { matches: [{field: 'SUBJECT',should:'CONTAIN',value:'needle'}] }
. You can use an array of matches and they will be applied sequentially to filter out emails. If you want to perform matches and extractions of content using Regex patterns see the EmailController getEmailContentMatch
method.
Declaration
public Task<Email> WaitForMatchingFirstEmailAsync(Guid inboxId, MatchOptions matchOptions, long? timeout = null, bool? unreadOnly = null, DateTime? since = null, DateTime? before = null, string sort = null, long? delay = null, int operationIndex = 0, CancellationToken cancellationToken = default)
Parameters
Type | Name | Description |
---|---|---|
System.Guid | inboxId | Id of the inbox we are matching an email for |
MatchOptions | matchOptions | |
long? | timeout | Max milliseconds to wait (optional) |
bool? | unreadOnly | Optional filter for unread only (optional, default to false) |
DateTime? | since | Filter for emails that were received after the given timestamp (optional) |
DateTime? | before | Filter for emails that were received before the given timestamp (optional) |
string | sort | Sort direction (optional) |
long? | delay | Max milliseconds delay between calls (optional) |
int | operationIndex | Index associated with the operation. |
CancellationToken | cancellationToken | Cancellation Token to cancel the request. |
Returns
Type | Description |
---|---|
Task<Email> | Task of Email |
Exceptions
Type | Condition |
---|---|
ApiException | Thrown when fails to make API call |
WaitForMatchingFirstEmailWithHttpInfo(Guid, MatchOptions, long?, bool?, DateTime?, DateTime?, string, long?, int)
Wait for or return the first email that matches provided MatchOptions array Perform a search of emails in an inbox with the given patterns. If a result if found then return or else retry the search until a result is found or timeout is reached. Match options allow simple CONTAINS or EQUALS filtering on SUBJECT, TO, BCC, CC, and FROM. See the MatchOptions
object for options. An example payload is { matches: [{field: 'SUBJECT',should:'CONTAIN',value:'needle'}] }
. You can use an array of matches and they will be applied sequentially to filter out emails. If you want to perform matches and extractions of content using Regex patterns see the EmailController getEmailContentMatch
method.
Declaration
public ApiResponse<Email> WaitForMatchingFirstEmailWithHttpInfo(Guid inboxId, MatchOptions matchOptions, long? timeout = null, bool? unreadOnly = null, DateTime? since = null, DateTime? before = null, string sort = null, long? delay = null, int operationIndex = 0)
Parameters
Type | Name | Description |
---|---|---|
System.Guid | inboxId | Id of the inbox we are matching an email for |
MatchOptions | matchOptions | |
long? | timeout | Max milliseconds to wait (optional) |
bool? | unreadOnly | Optional filter for unread only (optional, default to false) |
DateTime? | since | Filter for emails that were received after the given timestamp (optional) |
DateTime? | before | Filter for emails that were received before the given timestamp (optional) |
string | sort | Sort direction (optional) |
long? | delay | Max milliseconds delay between calls (optional) |
int | operationIndex | Index associated with the operation. |
Returns
Type | Description |
---|---|
ApiResponse<Email> | ApiResponse of Email |
Exceptions
Type | Condition |
---|---|
ApiException | Thrown when fails to make API call |
WaitForMatchingFirstEmailWithHttpInfoAsync(Guid, MatchOptions, long?, bool?, DateTime?, DateTime?, string, long?, int, CancellationToken)
Wait for or return the first email that matches provided MatchOptions array Perform a search of emails in an inbox with the given patterns. If a result if found then return or else retry the search until a result is found or timeout is reached. Match options allow simple CONTAINS or EQUALS filtering on SUBJECT, TO, BCC, CC, and FROM. See the MatchOptions
object for options. An example payload is { matches: [{field: 'SUBJECT',should:'CONTAIN',value:'needle'}] }
. You can use an array of matches and they will be applied sequentially to filter out emails. If you want to perform matches and extractions of content using Regex patterns see the EmailController getEmailContentMatch
method.
Declaration
public Task<ApiResponse<Email>> WaitForMatchingFirstEmailWithHttpInfoAsync(Guid inboxId, MatchOptions matchOptions, long? timeout = null, bool? unreadOnly = null, DateTime? since = null, DateTime? before = null, string sort = null, long? delay = null, int operationIndex = 0, CancellationToken cancellationToken = default)
Parameters
Type | Name | Description |
---|---|---|
System.Guid | inboxId | Id of the inbox we are matching an email for |
MatchOptions | matchOptions | |
long? | timeout | Max milliseconds to wait (optional) |
bool? | unreadOnly | Optional filter for unread only (optional, default to false) |
DateTime? | since | Filter for emails that were received after the given timestamp (optional) |
DateTime? | before | Filter for emails that were received before the given timestamp (optional) |
string | sort | Sort direction (optional) |
long? | delay | Max milliseconds delay between calls (optional) |
int | operationIndex | Index associated with the operation. |
CancellationToken | cancellationToken | Cancellation Token to cancel the request. |
Returns
Type | Description |
---|---|
Task<ApiResponse<Email>> | Task of ApiResponse (Email) |
Exceptions
Type | Condition |
---|---|
ApiException | Thrown when fails to make API call |
WaitForNthEmail(Guid?, int?, long?, bool?, DateTime?, DateTime?, string, long?, int)
Wait for or fetch the email with a given index in the inbox specified. If index doesn't exist waits for it to exist or timeout to occur. If nth email is already present in inbox then return it. If not hold the connection open until timeout expires or the nth email is received and returned.
Declaration
public Email WaitForNthEmail(Guid? inboxId = null, int? index = null, long? timeout = null, bool? unreadOnly = null, DateTime? since = null, DateTime? before = null, string sort = null, long? delay = null, int operationIndex = 0)
Parameters
Type | Name | Description |
---|---|---|
System.Guid? | inboxId | Id of the inbox you are fetching emails from (optional) |
int? | index | Zero based index of the email to wait for. If an inbox has 1 email already and you want to wait for the 2nd email pass index=1 (optional, default to 0) |
long? | timeout | Max milliseconds to wait for the nth email if not already present (optional) |
bool? | unreadOnly | Optional filter for unread only (optional, default to false) |
DateTime? | since | Filter for emails that were received after the given timestamp (optional) |
DateTime? | before | Filter for emails that were received before the given timestamp (optional) |
string | sort | Sort direction (optional) |
long? | delay | Max milliseconds delay between calls (optional) |
int | operationIndex | Index associated with the operation. |
Returns
Type | Description |
---|---|
Exceptions
Type | Condition |
---|---|
ApiException | Thrown when fails to make API call |
WaitForNthEmailAsync(Guid?, int?, long?, bool?, DateTime?, DateTime?, string, long?, int, CancellationToken)
Wait for or fetch the email with a given index in the inbox specified. If index doesn't exist waits for it to exist or timeout to occur. If nth email is already present in inbox then return it. If not hold the connection open until timeout expires or the nth email is received and returned.
Declaration
public Task<Email> WaitForNthEmailAsync(Guid? inboxId = null, int? index = null, long? timeout = null, bool? unreadOnly = null, DateTime? since = null, DateTime? before = null, string sort = null, long? delay = null, int operationIndex = 0, CancellationToken cancellationToken = default)
Parameters
Type | Name | Description |
---|---|---|
System.Guid? | inboxId | Id of the inbox you are fetching emails from (optional) |
int? | index | Zero based index of the email to wait for. If an inbox has 1 email already and you want to wait for the 2nd email pass index=1 (optional, default to 0) |
long? | timeout | Max milliseconds to wait for the nth email if not already present (optional) |
bool? | unreadOnly | Optional filter for unread only (optional, default to false) |
DateTime? | since | Filter for emails that were received after the given timestamp (optional) |
DateTime? | before | Filter for emails that were received before the given timestamp (optional) |
string | sort | Sort direction (optional) |
long? | delay | Max milliseconds delay between calls (optional) |
int | operationIndex | Index associated with the operation. |
CancellationToken | cancellationToken | Cancellation Token to cancel the request. |
Returns
Type | Description |
---|---|
Task<Email> | Task of Email |
Exceptions
Type | Condition |
---|---|
ApiException | Thrown when fails to make API call |
WaitForNthEmailWithHttpInfo(Guid?, int?, long?, bool?, DateTime?, DateTime?, string, long?, int)
Wait for or fetch the email with a given index in the inbox specified. If index doesn't exist waits for it to exist or timeout to occur. If nth email is already present in inbox then return it. If not hold the connection open until timeout expires or the nth email is received and returned.
Declaration
public ApiResponse<Email> WaitForNthEmailWithHttpInfo(Guid? inboxId = null, int? index = null, long? timeout = null, bool? unreadOnly = null, DateTime? since = null, DateTime? before = null, string sort = null, long? delay = null, int operationIndex = 0)
Parameters
Type | Name | Description |
---|---|---|
System.Guid? | inboxId | Id of the inbox you are fetching emails from (optional) |
int? | index | Zero based index of the email to wait for. If an inbox has 1 email already and you want to wait for the 2nd email pass index=1 (optional, default to 0) |
long? | timeout | Max milliseconds to wait for the nth email if not already present (optional) |
bool? | unreadOnly | Optional filter for unread only (optional, default to false) |
DateTime? | since | Filter for emails that were received after the given timestamp (optional) |
DateTime? | before | Filter for emails that were received before the given timestamp (optional) |
string | sort | Sort direction (optional) |
long? | delay | Max milliseconds delay between calls (optional) |
int | operationIndex | Index associated with the operation. |
Returns
Type | Description |
---|---|
ApiResponse<Email> | ApiResponse of Email |
Exceptions
Type | Condition |
---|---|
ApiException | Thrown when fails to make API call |
WaitForNthEmailWithHttpInfoAsync(Guid?, int?, long?, bool?, DateTime?, DateTime?, string, long?, int, CancellationToken)
Wait for or fetch the email with a given index in the inbox specified. If index doesn't exist waits for it to exist or timeout to occur. If nth email is already present in inbox then return it. If not hold the connection open until timeout expires or the nth email is received and returned.
Declaration
public Task<ApiResponse<Email>> WaitForNthEmailWithHttpInfoAsync(Guid? inboxId = null, int? index = null, long? timeout = null, bool? unreadOnly = null, DateTime? since = null, DateTime? before = null, string sort = null, long? delay = null, int operationIndex = 0, CancellationToken cancellationToken = default)
Parameters
Type | Name | Description |
---|---|---|
System.Guid? | inboxId | Id of the inbox you are fetching emails from (optional) |
int? | index | Zero based index of the email to wait for. If an inbox has 1 email already and you want to wait for the 2nd email pass index=1 (optional, default to 0) |
long? | timeout | Max milliseconds to wait for the nth email if not already present (optional) |
bool? | unreadOnly | Optional filter for unread only (optional, default to false) |
DateTime? | since | Filter for emails that were received after the given timestamp (optional) |
DateTime? | before | Filter for emails that were received before the given timestamp (optional) |
string | sort | Sort direction (optional) |
long? | delay | Max milliseconds delay between calls (optional) |
int | operationIndex | Index associated with the operation. |
CancellationToken | cancellationToken | Cancellation Token to cancel the request. |
Returns
Type | Description |
---|---|
Task<ApiResponse<Email>> | Task of ApiResponse (Email) |
Exceptions
Type | Condition |
---|---|
ApiException | Thrown when fails to make API call |
WaitForSms(WaitForSmsConditions, int)
Wait for an SMS message to match the provided filter conditions such as body contains keyword. Generic waitFor method that will wait until a phone number meets given conditions or return immediately if already met
Declaration
public List<SmsPreview> WaitForSms(WaitForSmsConditions waitForSmsConditions, int operationIndex = 0)
Parameters
Type | Name | Description |
---|---|---|
WaitForSmsConditions | waitForSmsConditions | |
int | operationIndex | Index associated with the operation. |
Returns
Type | Description |
---|---|
System.Collections.Generic.List<T><SmsPreview> | List<SmsPreview> |
Exceptions
Type | Condition |
---|---|
ApiException | Thrown when fails to make API call |
WaitForSmsAsync(WaitForSmsConditions, int, CancellationToken)
Wait for an SMS message to match the provided filter conditions such as body contains keyword. Generic waitFor method that will wait until a phone number meets given conditions or return immediately if already met
Declaration
public Task<List<SmsPreview>> WaitForSmsAsync(WaitForSmsConditions waitForSmsConditions, int operationIndex = 0, CancellationToken cancellationToken = default)
Parameters
Type | Name | Description |
---|---|---|
WaitForSmsConditions | waitForSmsConditions | |
int | operationIndex | Index associated with the operation. |
CancellationToken | cancellationToken | Cancellation Token to cancel the request. |
Returns
Type | Description |
---|---|
Task<System.Collections.Generic.List<T><SmsPreview>> | Task of List<SmsPreview> |
Exceptions
Type | Condition |
---|---|
ApiException | Thrown when fails to make API call |
WaitForSmsWithHttpInfo(WaitForSmsConditions, int)
Wait for an SMS message to match the provided filter conditions such as body contains keyword. Generic waitFor method that will wait until a phone number meets given conditions or return immediately if already met
Declaration
public ApiResponse<List<SmsPreview>> WaitForSmsWithHttpInfo(WaitForSmsConditions waitForSmsConditions, int operationIndex = 0)
Parameters
Type | Name | Description |
---|---|---|
WaitForSmsConditions | waitForSmsConditions | |
int | operationIndex | Index associated with the operation. |
Returns
Type | Description |
---|---|
ApiResponse<System.Collections.Generic.List<T><SmsPreview>> | ApiResponse of List<SmsPreview> |
Exceptions
Type | Condition |
---|---|
ApiException | Thrown when fails to make API call |
WaitForSmsWithHttpInfoAsync(WaitForSmsConditions, int, CancellationToken)
Wait for an SMS message to match the provided filter conditions such as body contains keyword. Generic waitFor method that will wait until a phone number meets given conditions or return immediately if already met
Declaration
public Task<ApiResponse<List<SmsPreview>>> WaitForSmsWithHttpInfoAsync(WaitForSmsConditions waitForSmsConditions, int operationIndex = 0, CancellationToken cancellationToken = default)
Parameters
Type | Name | Description |
---|---|---|
WaitForSmsConditions | waitForSmsConditions | |
int | operationIndex | Index associated with the operation. |
CancellationToken | cancellationToken | Cancellation Token to cancel the request. |
Returns
Type | Description |
---|---|
Task<ApiResponse<System.Collections.Generic.List<T><SmsPreview>>> | Task of ApiResponse (List<SmsPreview>) |
Exceptions
Type | Condition |
---|---|
ApiException | Thrown when fails to make API call |
WaitForWithHttpInfo(WaitForConditions, int)
Wait for an email to match the provided filter conditions such as subject contains keyword. Generic waitFor method that will wait until an inbox meets given conditions or return immediately if already met
Declaration
public ApiResponse<List<EmailPreview>> WaitForWithHttpInfo(WaitForConditions waitForConditions, int operationIndex = 0)
Parameters
Type | Name | Description |
---|---|---|
WaitForConditions | waitForConditions | |
int | operationIndex | Index associated with the operation. |
Returns
Type | Description |
---|---|
ApiResponse<System.Collections.Generic.List<T><EmailPreview>> | ApiResponse of List<EmailPreview> |
Exceptions
Type | Condition |
---|---|
ApiException | Thrown when fails to make API call |
WaitForWithHttpInfoAsync(WaitForConditions, int, CancellationToken)
Wait for an email to match the provided filter conditions such as subject contains keyword. Generic waitFor method that will wait until an inbox meets given conditions or return immediately if already met
Declaration
public Task<ApiResponse<List<EmailPreview>>> WaitForWithHttpInfoAsync(WaitForConditions waitForConditions, int operationIndex = 0, CancellationToken cancellationToken = default)
Parameters
Type | Name | Description |
---|---|---|
WaitForConditions | waitForConditions | |
int | operationIndex | Index associated with the operation. |
CancellationToken | cancellationToken | Cancellation Token to cancel the request. |
Returns
Type | Description |
---|---|
Task<ApiResponse<System.Collections.Generic.List<T><EmailPreview>>> | Task of ApiResponse (List<EmailPreview>) |
Exceptions
Type | Condition |
---|---|
ApiException | Thrown when fails to make API call |