interface TemplateProperty
Language | Type name |
---|---|
.NET | Amazon.CDK.AWS.SES.CfnTemplate.TemplateProperty |
Go | github.com/aws/aws-cdk-go/awscdk/v2/awsses#CfnTemplate_TemplateProperty |
Java | software.amazon.awscdk.services.ses.CfnTemplate.TemplateProperty |
Python | aws_cdk.aws_ses.CfnTemplate.TemplateProperty |
TypeScript | aws-cdk-lib » aws_ses » CfnTemplate » TemplateProperty |
An object that defines the email template to use for an email message, and the values to use for any message variables in that template.
An email template is a type of message template that contains content that you want to reuse in email messages that you send. You can specifiy the email template by providing the name or ARN of an email template previously saved in your Amazon SES account or by providing the full template content.
Example
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import { aws_ses as ses } from 'aws-cdk-lib';
const templateProperty: ses.CfnTemplate.TemplateProperty = {
subjectPart: 'subjectPart',
// the properties below are optional
htmlPart: 'htmlPart',
templateName: 'templateName',
textPart: 'textPart',
};
Properties
Name | Type | Description |
---|---|---|
subject | string | The subject line of the email. |
html | string | The HTML body of the email. |
template | string | The name of the template. |
text | string | The email body that is visible to recipients whose email clients do not display HTML content. |
subjectPart
Type:
string
The subject line of the email.
htmlPart?
Type:
string
(optional)
The HTML body of the email.
templateName?
Type:
string
(optional)
The name of the template.
You will refer to this name when you send email using the SendTemplatedEmail
or SendBulkTemplatedEmail
operations.
textPart?
Type:
string
(optional)
The email body that is visible to recipients whose email clients do not display HTML content.