TTMSFNCCloudSendGridMailTemplate Class
Describes a mail message to send, including sender, reply-to, recipients, carbon copies and template content.
API unit family: TMSFNCCloudSendGrid
Inherits from: TPersistent
Syntax
TTMSFNCCloudSendGridMailTemplate = class(TPersistent)
Properties
| Name | Description |
|---|---|
| Attachments | File attachments of the message. |
| BCCList | Blind carbon-copy (BCC) recipients of the message. |
| CCList | Carbon-copy (CC) recipients of the message. |
| Categories | Categories used to classify the message for reporting. |
| Content | Content bodies of the message, such as plain-text and HTML parts. |
| DynamicTemplateData | Key/value data used to populate a dynamic template (template identifier starting with d-). |
| From | Sender of the message. |
| RecipientsList | Primary recipients (To) of the message. |
| ReplyTo | Address replies to the message are directed to. |
| ReplyToList | Reply-to addresses of the message. |
| SendAt | Scheduled delivery time of the message. |
| Subject | Subject line of the message. |
| Substitutions | Substitution tokens replaced in the message body, mapping a key to its replacement lines. |
| TemplateID | Identifier of a stored template to render the message from. |
Methods
| Name | Description |
|---|---|
| AddAttachment | Adds a file as an attachment, encoding its content and deriving the file name and MIME type from the file. |
| AddBCC | Creates an empty blind carbon-copy recipient, adds it to the BCC list and returns it. |
| AddCC | Creates an empty carbon-copy recipient, adds it to the CC list and returns it. |
| AddContent | Adds a content body to the message and returns it. |
| AddRecipient | Creates an empty recipient, adds it to the recipient list and returns it. |
| AddReplyTo | Creates an empty reply-to entry, adds it to the reply-to list and returns it. |
| AddSubstitution | Registers a substitution token and its replacement lines. |
| ToJSON | Builds the full JSON payload sent to the mail service. |