MailSlurp JS

Globals / AliasControllerApi

# Class: AliasControllerApi

AliasControllerApi - object-oriented interface

export

# Hierarchy

# Index

# Constructors

# Properties

# Methods

# Constructors

# constructor

+ new AliasControllerApi(configuration?: Configuration, basePath?: string, fetch?: FetchAPI): AliasControllerApi

Inherited from BaseAPI.constructor

Defined in src/generated/api.ts:57 (opens new window)

# Parameters:

Name Type Default value
configuration? Configuration -
basePath string BASE_PATH
fetch FetchAPI portableFetch

Returns: AliasControllerApi

# Properties

# basePath

Protected basePath: string

Inherited from BaseAPI.basePath

Defined in src/generated/api.ts:61 (opens new window)


# configuration

Protected configuration: Configuration

Inherited from BaseAPI.configuration

Defined in src/generated/api.ts:57 (opens new window)


# fetch

Protected fetch: FetchAPI

Inherited from BaseAPI.fetch

Defined in src/generated/api.ts:62 (opens new window)

# Methods

# createAlias

createAlias(createAliasOptions: CreateAliasOptions, options?: any): Promise<AliasDto>

Defined in src/generated/api.ts:5248 (opens new window)

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

summary 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.

throws {RequiredError}

memberof AliasControllerApi

# Parameters:

Name Type Description
createAliasOptions CreateAliasOptions createAliasOptions
options? any -

Returns: Promise<AliasDto>


# deleteAlias

deleteAlias(aliasId: string, options?: any): Promise<Response>

Defined in src/generated/api.ts:5263 (opens new window)

summary Delete an email alias

throws {RequiredError}

memberof AliasControllerApi

# Parameters:

Name Type Description
aliasId string aliasId
options? any -

Returns: Promise<Response>


# getAlias

getAlias(aliasId: string, options?: any): Promise<AliasDto>

Defined in src/generated/api.ts:5278 (opens new window)

Get an email alias by ID

summary Get an email alias

throws {RequiredError}

memberof AliasControllerApi

# Parameters:

Name Type Description
aliasId string aliasId
options? any -

Returns: Promise<AliasDto>


# getAliasEmails

getAliasEmails(aliasId: string, page?: number, size?: number, sort?: "ASC" | "DESC", options?: any): Promise<PageEmailProjection>

Defined in src/generated/api.ts:5296 (opens new window)

Get paginated emails for an alias by ID

summary Get emails for an alias

throws {RequiredError}

memberof AliasControllerApi

# Parameters:

Name Type Description
aliasId string aliasId
page? number -
size? number -
sort? "ASC" "DESC"
options? any -

Returns: Promise<PageEmailProjection>


# getAliasThreads

getAliasThreads(aliasId: string, page?: number, size?: number, sort?: "ASC" | "DESC", options?: any): Promise<PageThreadProjection>

Defined in src/generated/api.ts:5323 (opens new window)

Returns threads created for an email alias in paginated form

summary Get threads created for an alias

throws {RequiredError}

memberof AliasControllerApi

# Parameters:

Name Type Description
aliasId string aliasId
page? number -
size? number -
sort? "ASC" "DESC"
options? any -

Returns: Promise<PageThreadProjection>


# getAliases

getAliases(page?: number, size?: number, sort?: "ASC" | "DESC", options?: any): Promise<PageAlias>

Defined in src/generated/api.ts:5349 (opens new window)

Get all email aliases in paginated form

summary Get all email aliases you have created

throws {RequiredError}

memberof AliasControllerApi

# Parameters:

Name Type
page? number
size? number
sort? "ASC"
options? any

Returns: Promise<PageAlias>


# replyToAliasEmail

replyToAliasEmail(aliasId: string, emailId: string, replyToAliasEmailOptions: ReplyToAliasEmailOptions, options?: any): Promise<SentEmailDto>

Defined in src/generated/api.ts:5373 (opens new window)

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.

summary Reply to an email

throws {RequiredError}

memberof AliasControllerApi

# Parameters:

Name Type Description
aliasId string ID of the alias that email belongs to
emailId string ID of the email that should be replied to
replyToAliasEmailOptions ReplyToAliasEmailOptions replyToAliasEmailOptions
options? any -

Returns: Promise<SentEmailDto>


# sendAliasEmail

sendAliasEmail(aliasId: string, sendEmailOptions?: SendEmailOptions, options?: any): Promise<SentEmailDto>

Defined in src/generated/api.ts:5396 (opens new window)

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

summary Send an email from an alias inbox

throws {RequiredError}

memberof AliasControllerApi

# Parameters:

Name Type Description
aliasId string aliasId
sendEmailOptions? SendEmailOptions -
options? any -

Returns: Promise<SentEmailDto>


# updateAlias

updateAlias(aliasId: string, updateAliasOptions: UpdateAliasOptions, options?: any): Promise<Response>

Defined in src/generated/api.ts:5417 (opens new window)

summary Update an email alias

throws {RequiredError}

memberof AliasControllerApi

# Parameters:

Name Type Description
aliasId string aliasId
updateAliasOptions UpdateAliasOptions updateAliasOptions
options? any -

Returns: Promise<Response>