Class: SMTPMessage
smtp.SMTPMessage SMTPMessage is a message to be sent over SMTPExample
Table of contents
Constructors
Methods
Constructors
constructor
• new SMTPMessage():SMTPMessage
Returns
SMTPMessage
Defined in
smtp.ts:83Methods
Auth
▸ Auth(username
): SMTPMessage
Auth when called authenticates using username and password before sending the message
Parameters
Name | Type |
---|---|
username | string |
Returns
SMTPMessage
Example
Defined in
smtp.ts:149Body
▸ Body(msg
): SMTPMessage
Body adds the message body to the message
Parameters
Name | Type |
---|---|
msg | Uint8Array |
Returns
SMTPMessage
Example
Defined in
smtp.ts:135From
▸ From(email
): SMTPMessage
From adds the from field to the message
Parameters
Name | Type |
---|---|
email | string |
Returns
SMTPMessage
Example
Defined in
smtp.ts:93String
▸ String():string
String returns the string representation of the message
Returns
string
Example
Defined in
smtp.ts:167Subject
▸ Subject(sub
): SMTPMessage
Subject adds the subject field to the message
Parameters
Name | Type |
---|---|
sub | string |
Returns
SMTPMessage
Example
Defined in
smtp.ts:121To
▸ To(email
): SMTPMessage
To adds the to field to the message
Parameters
Name | Type |
---|---|
email | string |
Returns
SMTPMessage
Example