MailSlurpAPI.Api.AliasController (mailslurp v11.7.0)

API calls for all endpoints tagged AliasController.

Link to this section Summary

Functions

Create an email alias. Must be verified by clicking link inside verification email that will be sent to the address. Once verified the alias will be active. Email aliases use a MailSlurp randomly generated email address (or a custom domain inbox that you provide) to mask or proxy a real email address. Emails sent to the alias address will be forwarded to the hidden email address it was created for. If you want to send a reply use the threadId attached

Get an email alias Get an email alias by ID

Get emails for an alias Get paginated emails for an alias by ID

Get threads created for an alias Returns threads created for an email alias in paginated form

Get all email aliases you have created Get all email aliases in paginated form

Reply to an email Send the reply to the email sender or reply-to and include same subject cc bcc etc. Reply to an email and the contents will be sent with the existing subject to the emails to, cc, and bcc.

Send an email from an alias inbox Send an email from an alias. Replies to the email will be forwarded to the alias masked email address

Link to this section Functions

Link to this function

create_alias(connection, create_alias_options, opts \\ [])

Specs

Create an email alias. Must be verified by clicking link inside verification email that will be sent to the address. Once verified the alias will be active. Email aliases use a MailSlurp randomly generated email address (or a custom domain inbox that you provide) to mask or proxy a real email address. Emails sent to the alias address will be forwarded to the hidden email address it was created for. If you want to send a reply use the threadId attached

Parameters

  • connection (MailSlurpAPI.Connection): Connection to server
  • create_alias_options (CreateAliasOptions): createAliasOptions
  • opts (KeywordList): [optional] Optional parameters

    Returns

} on success {:error, info} on failure

Link to this function

delete_alias(connection, alias_id, opts \\ [])

Specs

delete_alias(Tesla.Env.client(), String.t(), keyword()) ::
  {:ok, nil} | {:error, Tesla.Env.t()}

Delete an email alias

Parameters

  • connection (MailSlurpAPI.Connection): Connection to server
  • alias_id (String.t): aliasId
  • opts (KeywordList): [optional] Optional parameters

    Returns

} on success {:error, info} on failure

Link to this function

get_alias(connection, alias_id, opts \\ [])

Specs

get_alias(Tesla.Env.client(), String.t(), keyword()) ::
  {:ok, MailSlurpAPI.Model.AliasDto.t()} | {:error, Tesla.Env.t()}

Get an email alias Get an email alias by ID

Parameters

  • connection (MailSlurpAPI.Connection): Connection to server
  • alias_id (String.t): aliasId
  • opts (KeywordList): [optional] Optional parameters

    Returns

} on success {:error, info} on failure

Link to this function

get_alias_emails(connection, alias_id, opts \\ [])

Specs

get_alias_emails(Tesla.Env.client(), String.t(), keyword()) ::
  {:ok, MailSlurpAPI.Model.PageEmailProjection.t()} | {:error, Tesla.Env.t()}

Get emails for an alias Get paginated emails for an alias by ID

Parameters

  • connection (MailSlurpAPI.Connection): Connection to server
  • alias_id (String.t): aliasId
  • opts (KeywordList): [optional] Optional parameters
    • :page (integer()): Optional page index alias email list pagination
    • :size (integer()): Optional page size alias email list pagination
    • :sort (String.t): Optional createdAt sort direction ASC or DESC

      Returns

} on success {:error, info} on failure

Link to this function

get_alias_threads(connection, alias_id, opts \\ [])

Specs

get_alias_threads(Tesla.Env.client(), String.t(), keyword()) ::
  {:ok, MailSlurpAPI.Model.PageThreadProjection.t()} | {:error, Tesla.Env.t()}

Get threads created for an alias Returns threads created for an email alias in paginated form

Parameters

  • connection (MailSlurpAPI.Connection): Connection to server
  • alias_id (String.t): aliasId
  • opts (KeywordList): [optional] Optional parameters
    • :page (integer()): Optional page index in thread list pagination
    • :size (integer()): Optional page size in thread list pagination
    • :sort (String.t): Optional createdAt sort direction ASC or DESC

      Returns

} on success {:error, info} on failure

Link to this function

get_aliases(connection, opts \\ [])

Specs

get_aliases(Tesla.Env.client(), keyword()) ::
  {:ok, MailSlurpAPI.Model.PageAlias.t()} | {:error, Tesla.Env.t()}

Get all email aliases you have created Get all email aliases in paginated form

Parameters

  • connection (MailSlurpAPI.Connection): Connection to server
  • opts (KeywordList): [optional] Optional parameters
    • :page (integer()): Optional page index in alias list pagination
    • :size (integer()): Optional page size in alias list pagination
    • :sort (String.t): Optional createdAt sort direction ASC or DESC

      Returns

} on success {:error, info} on failure

Link to this function

reply_to_alias_email(connection, alias_id, email_id, reply_to_alias_email_options, opts \\ [])

Specs

Reply to an email Send the reply to the email sender or reply-to and include same subject cc bcc etc. Reply to an email and the contents will be sent with the existing subject to the emails to, cc, and bcc.

Parameters

  • connection (MailSlurpAPI.Connection): Connection to server
  • alias_id (String.t): ID of the alias that email belongs to
  • email_id (String.t): ID of the email that should be replied to
  • reply_to_alias_email_options (ReplyToAliasEmailOptions): replyToAliasEmailOptions
  • opts (KeywordList): [optional] Optional parameters

    Returns

} on success {:error, info} on failure

Link to this function

send_alias_email(connection, alias_id, opts \\ [])

Specs

send_alias_email(Tesla.Env.client(), String.t(), keyword()) ::
  {:ok, MailSlurpAPI.Model.SentEmailDto.t()} | {:error, Tesla.Env.t()}

Send an email from an alias inbox Send an email from an alias. Replies to the email will be forwarded to the alias masked email address

Parameters

  • connection (MailSlurpAPI.Connection): Connection to server
  • alias_id (String.t): aliasId
  • opts (KeywordList): [optional] Optional parameters
    • :send_email_options (SendEmailOptions): Options for the email to be sent

      Returns

} on success {:error, info} on failure

Link to this function

update_alias(connection, alias_id, update_alias_options, opts \\ [])

Specs

update_alias(
  Tesla.Env.client(),
  String.t(),
  MailSlurpAPI.Model.UpdateAliasOptions.t(),
  keyword()
) :: {:ok, nil} | {:error, Tesla.Env.t()}

Update an email alias

Parameters

  • connection (MailSlurpAPI.Connection): Connection to server
  • alias_id (String.t): aliasId
  • update_alias_options (UpdateAliasOptions): updateAliasOptions
  • opts (KeywordList): [optional] Optional parameters

    Returns

} on success {:error, info} on failure