Class EmailMessage
java.lang.Object
com.azure.communication.email.models.EmailMessage
Message payload for sending an email.
-
Constructor Summary
ConstructorDescriptionEmailMessage
(String sender, EmailContent content) Constructor for EmailMessage -
Method Summary
Modifier and TypeMethodDescriptionGet the attachments property: list of attachments.Get the content property: Email content to be sent.Get the customHeaders property: Custom email headers to be passed.Get the importance property: The importance type for the email.Get the recipients property: Recipients for the email.Get the replyTo property: Email addresses where recipients' replies will be sent to.Get the sender property: Sender email address from a verified domain.Get the disableUserEngagementTracking property: Indicates whether user engagement tracking should be disabled for this request if the resource-level user engagement tracking setting was already enabled in the control plane.setAttachments
(List<EmailAttachment> attachments) Set the attachments property: list of attachments.setCustomHeaders
(List<EmailCustomHeader> customHeaders) Set the customHeaders property: Custom email headers to be passed.setDisableUserEngagementTracking
(Boolean disableUserEngagementTracking) Set the disableUserEngagementTracking property: Indicates whether user engagement tracking should be disabled for this request if the resource-level user engagement tracking setting was already enabled in the control plane.setImportance
(EmailImportance importance) Set the importance property: The importance type for the email.setRecipients
(EmailRecipients recipients) Set the recipients property: Recipients for the email.setReplyTo
(Iterable<EmailAddress> replyTo) Set the replyTo property: Email addresses where recipients' replies will be sent to.
-
Constructor Details
-
EmailMessage
Constructor for EmailMessage- Parameters:
sender
- the sender email address from a verified domaincontent
- the email content to be sent
-
-
Method Details
-
getCustomHeaders
Get the customHeaders property: Custom email headers to be passed.- Returns:
- the customHeaders value.
-
setCustomHeaders
Set the customHeaders property: Custom email headers to be passed.- Parameters:
customHeaders
- the customHeaders value to set.- Returns:
- the EmailMessage object itself.
-
getSender
Get the sender property: Sender email address from a verified domain.- Returns:
- the sender value.
-
getContent
Get the content property: Email content to be sent.- Returns:
- the content value.
-
getImportance
Get the importance property: The importance type for the email.- Returns:
- the importance value.
-
setImportance
Set the importance property: The importance type for the email.- Parameters:
importance
- the importance value to set.- Returns:
- the EmailMessage object itself.
-
getRecipients
Get the recipients property: Recipients for the email.- Returns:
- the recipients value.
-
setRecipients
Set the recipients property: Recipients for the email.- Parameters:
recipients
- the recipients value to set.- Returns:
- the EmailMessage object itself.
-
getAttachments
Get the attachments property: list of attachments.- Returns:
- the attachments value.
-
setAttachments
Set the attachments property: list of attachments.- Parameters:
attachments
- the attachments value to set.- Returns:
- the EmailMessage object itself.
-
getReplyTo
Get the replyTo property: Email addresses where recipients' replies will be sent to.- Returns:
- the replyTo value.
-
setReplyTo
Set the replyTo property: Email addresses where recipients' replies will be sent to.- Parameters:
replyTo
- the replyTo value to set.- Returns:
- the EmailMessage object itself.
-
isDisableUserEngagementTracking
Get the disableUserEngagementTracking property: Indicates whether user engagement tracking should be disabled for this request if the resource-level user engagement tracking setting was already enabled in the control plane.- Returns:
- the disableUserEngagementTracking value.
-
setDisableUserEngagementTracking
Set the disableUserEngagementTracking property: Indicates whether user engagement tracking should be disabled for this request if the resource-level user engagement tracking setting was already enabled in the control plane.- Parameters:
disableUserEngagementTracking
- the disableUserEngagementTracking value to set.- Returns:
- the EmailMessage object itself.
-