Class: AWSCDK::Pinpoint::CfnEmailTemplateProps
- Inherits:
-
Jsii::Struct
- Object
- Jsii::Struct
- AWSCDK::Pinpoint::CfnEmailTemplateProps
- Defined in:
- pinpoint/cfn_email_template_props.rb
Overview
Properties for defining a CfnEmailTemplate.
Instance Attribute Summary collapse
-
#default_substitutions ⇒ String?
readonly
A JSON object that specifies the default values to use for message variables in the message template.
-
#html_part ⇒ String?
readonly
The message body, in HTML format, to use in email messages that are based on the message template.
-
#subject ⇒ String
readonly
The subject line, or title, to use in email messages that are based on the message template.
-
#tags ⇒ Object?
readonly
An array of key-value pairs to apply to this resource.
-
#template_description ⇒ String?
readonly
A custom description of the message template.
-
#template_name ⇒ String
readonly
The name of the message template.
-
#text_part ⇒ String?
readonly
The message body, in plain text format, to use in email messages that are based on the message template.
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize(subject:, template_name:, default_substitutions: nil, html_part: nil, tags: nil, template_description: nil, text_part: nil) ⇒ CfnEmailTemplateProps
constructor
A new instance of CfnEmailTemplateProps.
- #to_jsii ⇒ Object
Constructor Details
#initialize(subject:, template_name:, default_substitutions: nil, html_part: nil, tags: nil, template_description: nil, text_part: nil) ⇒ CfnEmailTemplateProps
Returns a new instance of CfnEmailTemplateProps.
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 |
# File 'pinpoint/cfn_email_template_props.rb', line 16 def initialize(subject:, template_name:, default_substitutions: nil, html_part: nil, tags: nil, template_description: nil, text_part: nil) @subject = subject Jsii::Type.check_type(@subject, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "subject") @template_name = template_name Jsii::Type.check_type(@template_name, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "templateName") @default_substitutions = default_substitutions Jsii::Type.check_type(@default_substitutions, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "defaultSubstitutions") unless @default_substitutions.nil? @html_part = html_part Jsii::Type.check_type(@html_part, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "htmlPart") unless @html_part.nil? @tags = Jsii::Type.check_type(@tags, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJhbnkifQ==")), "tags") unless @tags.nil? @template_description = template_description Jsii::Type.check_type(@template_description, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "templateDescription") unless @template_description.nil? @text_part = text_part Jsii::Type.check_type(@text_part, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "textPart") unless @text_part.nil? end |
Instance Attribute Details
#default_substitutions ⇒ String? (readonly)
A JSON object that specifies the default values to use for message variables in the message template.
This object is a set of key-value pairs. Each key defines a message variable in the template. The corresponding value defines the default value for that variable. When you create a message that's based on the template, you can override these defaults with message-specific and address-specific variables and values.
49 50 51 |
# File 'pinpoint/cfn_email_template_props.rb', line 49 def default_substitutions @default_substitutions end |
#html_part ⇒ String? (readonly)
The message body, in HTML format, to use in email messages that are based on the message template.
We recommend using HTML format for email clients that render HTML content. You can include links, formatted text, and more in an HTML message.
56 57 58 |
# File 'pinpoint/cfn_email_template_props.rb', line 56 def html_part @html_part end |
#subject ⇒ String (readonly)
The subject line, or title, to use in email messages that are based on the message template.
37 38 39 |
# File 'pinpoint/cfn_email_template_props.rb', line 37 def subject @subject end |
#tags ⇒ Object? (readonly)
An array of key-value pairs to apply to this resource.
For more information, see Tag .
63 64 65 |
# File 'pinpoint/cfn_email_template_props.rb', line 63 def @tags end |
#template_description ⇒ String? (readonly)
A custom description of the message template.
68 69 70 |
# File 'pinpoint/cfn_email_template_props.rb', line 68 def template_description @template_description end |
#template_name ⇒ String (readonly)
The name of the message template.
42 43 44 |
# File 'pinpoint/cfn_email_template_props.rb', line 42 def template_name @template_name end |
#text_part ⇒ String? (readonly)
The message body, in plain text format, to use in email messages that are based on the message template.
We recommend using plain text format for email clients that don't render HTML content and clients that are connected to high-latency networks, such as mobile devices.
75 76 77 |
# File 'pinpoint/cfn_email_template_props.rb', line 75 def text_part @text_part end |
Class Method Details
.jsii_properties ⇒ Object
77 78 79 80 81 82 83 84 85 86 87 |
# File 'pinpoint/cfn_email_template_props.rb', line 77 def self.jsii_properties { :subject => "subject", :template_name => "templateName", :default_substitutions => "defaultSubstitutions", :html_part => "htmlPart", :tags => "tags", :template_description => "templateDescription", :text_part => "textPart", } end |
Instance Method Details
#to_jsii ⇒ Object
89 90 91 92 93 94 95 96 97 98 99 100 101 |
# File 'pinpoint/cfn_email_template_props.rb', line 89 def to_jsii result = {} result.merge!({ "subject" => @subject, "templateName" => @template_name, "defaultSubstitutions" => @default_substitutions, "htmlPart" => @html_part, "tags" => @tags, "templateDescription" => @template_description, "textPart" => @text_part, }) result.compact end |