Class OAuthConnectionApi
Represents a collection of functions to interact with the API endpoints
Inherited Members
Namespace: mailslurp.Api
Assembly: mailslurp.dll
Syntax
public class OAuthConnectionApi : IOAuthConnectionApi, IOAuthConnectionApiSync, IOAuthConnectionApiAsync, IApiAccessor
Constructors
View SourceOAuthConnectionApi()
Initializes a new instance of the OAuthConnectionApi class.
Declaration
public OAuthConnectionApi()
OAuthConnectionApi(string)
Initializes a new instance of the OAuthConnectionApi class.
Declaration
public OAuthConnectionApi(string basePath)
Parameters
Type | Name | Description |
---|---|---|
string | basePath |
OAuthConnectionApi(Configuration)
Initializes a new instance of the OAuthConnectionApi class using Configuration object
Declaration
public OAuthConnectionApi(Configuration configuration)
Parameters
Type | Name | Description |
---|---|---|
Configuration | configuration | An instance of Configuration |
OAuthConnectionApi(ISynchronousClient, IAsynchronousClient, IReadableConfiguration)
Initializes a new instance of the OAuthConnectionApi class using a Configuration object and client instance.
Declaration
public OAuthConnectionApi(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. |
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 SourceCreateOAuthConnection(string, string, string, int)
Create an OAuth connection Configure an inbox for OAuth sync with MailSlurp
Declaration
public CreateOAuthConnectionResult CreateOAuthConnection(string redirectBase, string oAuthConnectionType, string emailAddress = null, int operationIndex = 0)
Parameters
Type | Name | Description |
---|---|---|
string | redirectBase | |
string | oAuthConnectionType | |
string | emailAddress | (optional) |
int | operationIndex | Index associated with the operation. |
Returns
Type | Description |
---|---|
CreateOAuthConnectionResult | CreateOAuthConnectionResult |
Exceptions
Type | Condition |
---|---|
ApiException | Thrown when fails to make API call |
CreateOAuthConnectionAsync(string, string, string, int, CancellationToken)
Create an OAuth connection Configure an inbox for OAuth sync with MailSlurp
Declaration
public Task<CreateOAuthConnectionResult> CreateOAuthConnectionAsync(string redirectBase, string oAuthConnectionType, string emailAddress = null, int operationIndex = 0, CancellationToken cancellationToken = default)
Parameters
Type | Name | Description |
---|---|---|
string | redirectBase | |
string | oAuthConnectionType | |
string | emailAddress | (optional) |
int | operationIndex | Index associated with the operation. |
CancellationToken | cancellationToken | Cancellation Token to cancel the request. |
Returns
Type | Description |
---|---|
Task<CreateOAuthConnectionResult> | Task of CreateOAuthConnectionResult |
Exceptions
Type | Condition |
---|---|
ApiException | Thrown when fails to make API call |
CreateOAuthConnectionWithHttpInfo(string, string, string, int)
Create an OAuth connection Configure an inbox for OAuth sync with MailSlurp
Declaration
public ApiResponse<CreateOAuthConnectionResult> CreateOAuthConnectionWithHttpInfo(string redirectBase, string oAuthConnectionType, string emailAddress = null, int operationIndex = 0)
Parameters
Type | Name | Description |
---|---|---|
string | redirectBase | |
string | oAuthConnectionType | |
string | emailAddress | (optional) |
int | operationIndex | Index associated with the operation. |
Returns
Type | Description |
---|---|
ApiResponse<CreateOAuthConnectionResult> | ApiResponse of CreateOAuthConnectionResult |
Exceptions
Type | Condition |
---|---|
ApiException | Thrown when fails to make API call |
CreateOAuthConnectionWithHttpInfoAsync(string, string, string, int, CancellationToken)
Create an OAuth connection Configure an inbox for OAuth sync with MailSlurp
Declaration
public Task<ApiResponse<CreateOAuthConnectionResult>> CreateOAuthConnectionWithHttpInfoAsync(string redirectBase, string oAuthConnectionType, string emailAddress = null, int operationIndex = 0, CancellationToken cancellationToken = default)
Parameters
Type | Name | Description |
---|---|---|
string | redirectBase | |
string | oAuthConnectionType | |
string | emailAddress | (optional) |
int | operationIndex | Index associated with the operation. |
CancellationToken | cancellationToken | Cancellation Token to cancel the request. |
Returns
Type | Description |
---|---|
Task<ApiResponse<CreateOAuthConnectionResult>> | Task of ApiResponse (CreateOAuthConnectionResult) |
Exceptions
Type | Condition |
---|---|
ApiException | Thrown when fails to make API call |
ExchangeAuthorizationTokenAndCreateOrUpdateInbox(string, string, int)
Exchange authorization code for access token and create inbox Exchange an OAuth code for an access token and create an inbox connection in MailSlurp
Declaration
public CreateOAuthExchangeResult ExchangeAuthorizationTokenAndCreateOrUpdateInbox(string authorizationCode, string redirectUri, int operationIndex = 0)
Parameters
Type | Name | Description |
---|---|---|
string | authorizationCode | |
string | redirectUri | |
int | operationIndex | Index associated with the operation. |
Returns
Type | Description |
---|---|
CreateOAuthExchangeResult | CreateOAuthExchangeResult |
Exceptions
Type | Condition |
---|---|
ApiException | Thrown when fails to make API call |
ExchangeAuthorizationTokenAndCreateOrUpdateInboxAsync(string, string, int, CancellationToken)
Exchange authorization code for access token and create inbox Exchange an OAuth code for an access token and create an inbox connection in MailSlurp
Declaration
public Task<CreateOAuthExchangeResult> ExchangeAuthorizationTokenAndCreateOrUpdateInboxAsync(string authorizationCode, string redirectUri, int operationIndex = 0, CancellationToken cancellationToken = default)
Parameters
Type | Name | Description |
---|---|---|
string | authorizationCode | |
string | redirectUri | |
int | operationIndex | Index associated with the operation. |
CancellationToken | cancellationToken | Cancellation Token to cancel the request. |
Returns
Type | Description |
---|---|
Task<CreateOAuthExchangeResult> | Task of CreateOAuthExchangeResult |
Exceptions
Type | Condition |
---|---|
ApiException | Thrown when fails to make API call |
ExchangeAuthorizationTokenAndCreateOrUpdateInboxWithHttpInfo(string, string, int)
Exchange authorization code for access token and create inbox Exchange an OAuth code for an access token and create an inbox connection in MailSlurp
Declaration
public ApiResponse<CreateOAuthExchangeResult> ExchangeAuthorizationTokenAndCreateOrUpdateInboxWithHttpInfo(string authorizationCode, string redirectUri, int operationIndex = 0)
Parameters
Type | Name | Description |
---|---|---|
string | authorizationCode | |
string | redirectUri | |
int | operationIndex | Index associated with the operation. |
Returns
Type | Description |
---|---|
ApiResponse<CreateOAuthExchangeResult> | ApiResponse of CreateOAuthExchangeResult |
Exceptions
Type | Condition |
---|---|
ApiException | Thrown when fails to make API call |
ExchangeAuthorizationTokenAndCreateOrUpdateInboxWithHttpInfoAsync(string, string, int, CancellationToken)
Exchange authorization code for access token and create inbox Exchange an OAuth code for an access token and create an inbox connection in MailSlurp
Declaration
public Task<ApiResponse<CreateOAuthExchangeResult>> ExchangeAuthorizationTokenAndCreateOrUpdateInboxWithHttpInfoAsync(string authorizationCode, string redirectUri, int operationIndex = 0, CancellationToken cancellationToken = default)
Parameters
Type | Name | Description |
---|---|---|
string | authorizationCode | |
string | redirectUri | |
int | operationIndex | Index associated with the operation. |
CancellationToken | cancellationToken | Cancellation Token to cancel the request. |
Returns
Type | Description |
---|---|
Task<ApiResponse<CreateOAuthExchangeResult>> | Task of ApiResponse (CreateOAuthExchangeResult) |
Exceptions
Type | Condition |
---|---|
ApiException | Thrown when fails to make API call |
GetBasePath()
Gets the base path of the API client.
Declaration
public string GetBasePath()
Returns
Type | Description |
---|---|
string | The base path |