Skip to content

Commit 4cf8ac2

Browse files
This release enables customers to provide attachments in the SESv2 SendEmail and SendBulkEmail APIs.
1 parent f14e3b4 commit 4cf8ac2

File tree

12 files changed

+692
-12
lines changed

12 files changed

+692
-12
lines changed

generator/ServiceModels/sesv2/sesv2-2019-09-27.api.json

Lines changed: 58 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1467,6 +1467,59 @@
14671467
"ArchiveArn":{"shape":"ArchiveArn"}
14681468
}
14691469
},
1470+
"Attachment":{
1471+
"type":"structure",
1472+
"required":[
1473+
"RawContent",
1474+
"FileName"
1475+
],
1476+
"members":{
1477+
"RawContent":{"shape":"RawAttachmentData"},
1478+
"ContentDisposition":{"shape":"AttachmentContentDisposition"},
1479+
"FileName":{"shape":"AttachmentFileName"},
1480+
"ContentDescription":{"shape":"AttachmentContentDescription"},
1481+
"ContentId":{"shape":"AttachmentContentId"},
1482+
"ContentTransferEncoding":{"shape":"AttachmentContentTransferEncoding"},
1483+
"ContentType":{"shape":"AttachmentContentType"}
1484+
}
1485+
},
1486+
"AttachmentContentDescription":{
1487+
"type":"string",
1488+
"max":1000
1489+
},
1490+
"AttachmentContentDisposition":{
1491+
"type":"string",
1492+
"enum":[
1493+
"ATTACHMENT",
1494+
"INLINE"
1495+
]
1496+
},
1497+
"AttachmentContentId":{
1498+
"type":"string",
1499+
"max":78,
1500+
"min":1
1501+
},
1502+
"AttachmentContentTransferEncoding":{
1503+
"type":"string",
1504+
"enum":[
1505+
"BASE64",
1506+
"QUOTED_PRINTABLE",
1507+
"SEVEN_BIT"
1508+
]
1509+
},
1510+
"AttachmentContentType":{
1511+
"type":"string",
1512+
"max":78,
1513+
"min":1
1514+
},
1515+
"AttachmentFileName":{
1516+
"type":"string",
1517+
"max":255
1518+
},
1519+
"AttachmentList":{
1520+
"type":"list",
1521+
"member":{"shape":"Attachment"}
1522+
},
14701523
"AttributesData":{"type":"string"},
14711524
"BadRequestException":{
14721525
"type":"structure",
@@ -3856,7 +3909,8 @@
38563909
"members":{
38573910
"Subject":{"shape":"Content"},
38583911
"Body":{"shape":"Body"},
3859-
"Headers":{"shape":"MessageHeaderList"}
3912+
"Headers":{"shape":"MessageHeaderList"},
3913+
"Attachments":{"shape":"AttachmentList"}
38603914
}
38613915
},
38623916
"MessageContent":{"type":"string"},
@@ -4490,6 +4544,7 @@
44904544
"max":255,
44914545
"min":1
44924546
},
4547+
"RawAttachmentData":{"type":"blob"},
44934548
"RawMessage":{
44944549
"type":"structure",
44954550
"required":["Data"],
@@ -4871,7 +4926,8 @@
48714926
"TemplateArn":{"shape":"AmazonResourceName"},
48724927
"TemplateContent":{"shape":"EmailTemplateContent"},
48734928
"TemplateData":{"shape":"EmailTemplateData"},
4874-
"Headers":{"shape":"MessageHeaderList"}
4929+
"Headers":{"shape":"MessageHeaderList"},
4930+
"Attachments":{"shape":"AttachmentList"}
48754931
}
48764932
},
48774933
"TemplateContent":{"type":"string"},

generator/ServiceModels/sesv2/sesv2-2019-09-27.docs.json

Lines changed: 57 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -169,6 +169,55 @@
169169
"GetConfigurationSetResponse$ArchivingOptions": "<p>An object that defines the MailManager archive where sent emails are archived that you send using the configuration set.</p>"
170170
}
171171
},
172+
"Attachment": {
173+
"base": "<p> Contains metadata and attachment raw content.</p>",
174+
"refs": {
175+
"AttachmentList$member": null
176+
}
177+
},
178+
"AttachmentContentDescription": {
179+
"base": null,
180+
"refs": {
181+
"Attachment$ContentDescription": "<p> A brief description of the attachment content.</p>"
182+
}
183+
},
184+
"AttachmentContentDisposition": {
185+
"base": null,
186+
"refs": {
187+
"Attachment$ContentDisposition": "<p> A standard descriptor indicating how the attachment should be rendered in the email. Supported values: <code>ATTACHMENT</code> or <code>INLINE</code>.</p>"
188+
}
189+
},
190+
"AttachmentContentId": {
191+
"base": null,
192+
"refs": {
193+
"Attachment$ContentId": "<p> Unique identifier for the attachment, used for referencing attachments with INLINE disposition in HTML content.</p>"
194+
}
195+
},
196+
"AttachmentContentTransferEncoding": {
197+
"base": null,
198+
"refs": {
199+
"Attachment$ContentTransferEncoding": "<p> Specifies how the attachment is encoded. Supported values: <code>BASE64</code>, <code>QUOTED_PRINTABLE</code>, <code>SEVEN_BIT</code>.</p>"
200+
}
201+
},
202+
"AttachmentContentType": {
203+
"base": null,
204+
"refs": {
205+
"Attachment$ContentType": "<p> The MIME type of the attachment.</p> <note> <p>Example: <code>application/pdf</code>, <code>image/jpeg</code> </p> </note>"
206+
}
207+
},
208+
"AttachmentFileName": {
209+
"base": null,
210+
"refs": {
211+
"Attachment$FileName": "<p>The file name for the attachment as it will appear in the email. Amazon SES restricts certain file extensions. To ensure attachments are accepted, check the <a href=\"https://docs.aws.amazon.com/ses/latest/dg/mime-types.html\">Unsupported attachment types</a> in the Amazon SES Developer Guide.</p>"
212+
}
213+
},
214+
"AttachmentList": {
215+
"base": null,
216+
"refs": {
217+
"Message$Attachments": "<p> The List of attachments to include in your email. All recipients will receive the same attachments.</p>",
218+
"Template$Attachments": "<p> The List of attachments to include in your email. All recipients will receive the same attachments.</p>"
219+
}
220+
},
172221
"AttributesData": {
173222
"base": null,
174223
"refs": {
@@ -1036,7 +1085,7 @@
10361085
}
10371086
},
10381087
"EmailContent": {
1039-
"base": "<p>An object that defines the entire content of the email, including the message headers and the body content. You can create a simple email message, in which you specify the subject and the text and HTML versions of the message body. You can also create raw messages, in which you specify a complete MIME-formatted message. Raw messages can include attachments and custom headers.</p>",
1088+
"base": "<p>An object that defines the entire content of the email, including the message headers, body content, and attachments. For a simple email message, you specify the subject and provide both text and HTML versions of the message body. You can also add attachments to simple and templated messages. For a raw message, you provide a complete MIME-formatted message, which can include custom headers and attachments.</p>",
10401089
"refs": {
10411090
"CreateDeliverabilityTestReportRequest$Content": "<p>The HTML body of the message that you sent when you performed the predictive inbox placement test.</p>",
10421091
"SendEmailRequest$Content": "<p>An object that contains the body of the message. You can send either a Simple message, Raw message, or a Templated message.</p>"
@@ -2124,7 +2173,7 @@
21242173
"Message": {
21252174
"base": "<p>Represents the email message that you're sending. The <code>Message</code> object consists of a subject line and a message body.</p>",
21262175
"refs": {
2127-
"EmailContent$Simple": "<p>The simple email message. The message consists of a subject and a message body.</p>"
2176+
"EmailContent$Simple": "<p>The simple email message. The message consists of a subject, message body and attachments list.</p>"
21282177
}
21292178
},
21302179
"MessageContent": {
@@ -2702,6 +2751,12 @@
27022751
"MetricDataResult$Id": "<p>The query identifier.</p>"
27032752
}
27042753
},
2754+
"RawAttachmentData": {
2755+
"base": null,
2756+
"refs": {
2757+
"Attachment$RawContent": "<p> The raw data of the attachment. It needs to be base64-encoded if you are accessing Amazon SES directly through the HTTPS interface. If you are accessing Amazon SES using an Amazon Web Services SDK, the SDK takes care of the base 64-encoding for you.</p>"
2758+
}
2759+
},
27052760
"RawMessage": {
27062761
"base": "<p>Represents the raw content of an email message.</p>",
27072762
"refs": {

generator/ServiceModels/sesv2/sesv2-2019-09-27.normal.json

Lines changed: 86 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1589,6 +1589,81 @@
15891589
},
15901590
"documentation":"<p>Used to associate a configuration set with a MailManager archive.</p>"
15911591
},
1592+
"Attachment":{
1593+
"type":"structure",
1594+
"required":[
1595+
"RawContent",
1596+
"FileName"
1597+
],
1598+
"members":{
1599+
"RawContent":{
1600+
"shape":"RawAttachmentData",
1601+
"documentation":"<p> The raw data of the attachment. It needs to be base64-encoded if you are accessing Amazon SES directly through the HTTPS interface. If you are accessing Amazon SES using an Amazon Web Services SDK, the SDK takes care of the base 64-encoding for you.</p>"
1602+
},
1603+
"ContentDisposition":{
1604+
"shape":"AttachmentContentDisposition",
1605+
"documentation":"<p> A standard descriptor indicating how the attachment should be rendered in the email. Supported values: <code>ATTACHMENT</code> or <code>INLINE</code>.</p>"
1606+
},
1607+
"FileName":{
1608+
"shape":"AttachmentFileName",
1609+
"documentation":"<p>The file name for the attachment as it will appear in the email. Amazon SES restricts certain file extensions. To ensure attachments are accepted, check the <a href=\"https://docs.aws.amazon.com/ses/latest/dg/mime-types.html\">Unsupported attachment types</a> in the Amazon SES Developer Guide.</p>"
1610+
},
1611+
"ContentDescription":{
1612+
"shape":"AttachmentContentDescription",
1613+
"documentation":"<p> A brief description of the attachment content.</p>"
1614+
},
1615+
"ContentId":{
1616+
"shape":"AttachmentContentId",
1617+
"documentation":"<p> Unique identifier for the attachment, used for referencing attachments with INLINE disposition in HTML content.</p>"
1618+
},
1619+
"ContentTransferEncoding":{
1620+
"shape":"AttachmentContentTransferEncoding",
1621+
"documentation":"<p> Specifies how the attachment is encoded. Supported values: <code>BASE64</code>, <code>QUOTED_PRINTABLE</code>, <code>SEVEN_BIT</code>.</p>"
1622+
},
1623+
"ContentType":{
1624+
"shape":"AttachmentContentType",
1625+
"documentation":"<p> The MIME type of the attachment.</p> <note> <p>Example: <code>application/pdf</code>, <code>image/jpeg</code> </p> </note>"
1626+
}
1627+
},
1628+
"documentation":"<p> Contains metadata and attachment raw content.</p>"
1629+
},
1630+
"AttachmentContentDescription":{
1631+
"type":"string",
1632+
"max":1000
1633+
},
1634+
"AttachmentContentDisposition":{
1635+
"type":"string",
1636+
"enum":[
1637+
"ATTACHMENT",
1638+
"INLINE"
1639+
]
1640+
},
1641+
"AttachmentContentId":{
1642+
"type":"string",
1643+
"max":78,
1644+
"min":1
1645+
},
1646+
"AttachmentContentTransferEncoding":{
1647+
"type":"string",
1648+
"enum":[
1649+
"BASE64",
1650+
"QUOTED_PRINTABLE",
1651+
"SEVEN_BIT"
1652+
]
1653+
},
1654+
"AttachmentContentType":{
1655+
"type":"string",
1656+
"max":78,
1657+
"min":1
1658+
},
1659+
"AttachmentFileName":{
1660+
"type":"string",
1661+
"max":255
1662+
},
1663+
"AttachmentList":{
1664+
"type":"list",
1665+
"member":{"shape":"Attachment"}
1666+
},
15921667
"AttributesData":{"type":"string"},
15931668
"BadRequestException":{
15941669
"type":"structure",
@@ -3222,7 +3297,7 @@
32223297
"members":{
32233298
"Simple":{
32243299
"shape":"Message",
3225-
"documentation":"<p>The simple email message. The message consists of a subject and a message body.</p>"
3300+
"documentation":"<p>The simple email message. The message consists of a subject, message body and attachments list.</p>"
32263301
},
32273302
"Raw":{
32283303
"shape":"RawMessage",
@@ -3233,7 +3308,7 @@
32333308
"documentation":"<p>The template to use for the email message.</p>"
32343309
}
32353310
},
3236-
"documentation":"<p>An object that defines the entire content of the email, including the message headers and the body content. You can create a simple email message, in which you specify the subject and the text and HTML versions of the message body. You can also create raw messages, in which you specify a complete MIME-formatted message. Raw messages can include attachments and custom headers.</p>"
3311+
"documentation":"<p>An object that defines the entire content of the email, including the message headers, body content, and attachments. For a simple email message, you specify the subject and provide both text and HTML versions of the message body. You can also add attachments to simple and templated messages. For a raw message, you provide a complete MIME-formatted message, which can include custom headers and attachments.</p>"
32373312
},
32383313
"EmailInsights":{
32393314
"type":"structure",
@@ -5417,6 +5492,10 @@
54175492
"Headers":{
54185493
"shape":"MessageHeaderList",
54195494
"documentation":"<p>The list of message headers that will be added to the email message.</p>"
5495+
},
5496+
"Attachments":{
5497+
"shape":"AttachmentList",
5498+
"documentation":"<p> The List of attachments to include in your email. All recipients will receive the same attachments.</p>"
54205499
}
54215500
},
54225501
"documentation":"<p>Represents the email message that you're sending. The <code>Message</code> object consists of a subject line and a message body.</p>"
@@ -6379,6 +6458,7 @@
63796458
"max":255,
63806459
"min":1
63816460
},
6461+
"RawAttachmentData":{"type":"blob"},
63826462
"RawMessage":{
63836463
"type":"structure",
63846464
"required":["Data"],
@@ -7028,6 +7108,10 @@
70287108
"Headers":{
70297109
"shape":"MessageHeaderList",
70307110
"documentation":"<p>The list of message headers that will be added to the email message.</p>"
7111+
},
7112+
"Attachments":{
7113+
"shape":"AttachmentList",
7114+
"documentation":"<p> The List of attachments to include in your email. All recipients will receive the same attachments.</p>"
70317115
}
70327116
},
70337117
"documentation":"<p>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 <i>email template</i> 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 <i>email template</i> previously saved in your Amazon SES account or by providing the full template content.</p>"

sdk/code-analysis/ServiceAnalysis/SimpleEmailV2/Generated/PropertyValueRules.xml

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -243,6 +243,24 @@
243243
<max>1011</max>
244244
<pattern>arn:(aws|aws-[a-z-]+):ses:[a-z]{2}-[a-z-]+-[0-9]:[0-9]{1,20}:mailmanager-archive/a-[a-z0-9]{24,62}</pattern>
245245
</property-value-rule>
246+
<property-value-rule>
247+
<property>Amazon.SimpleEmailV2.Model.Attachment.ContentDescription</property>
248+
<max>1000</max>
249+
</property-value-rule>
250+
<property-value-rule>
251+
<property>Amazon.SimpleEmailV2.Model.Attachment.ContentId</property>
252+
<min>1</min>
253+
<max>78</max>
254+
</property-value-rule>
255+
<property-value-rule>
256+
<property>Amazon.SimpleEmailV2.Model.Attachment.ContentType</property>
257+
<min>1</min>
258+
<max>78</max>
259+
</property-value-rule>
260+
<property-value-rule>
261+
<property>Amazon.SimpleEmailV2.Model.Attachment.FileName</property>
262+
<max>255</max>
263+
</property-value-rule>
246264
<property-value-rule>
247265
<property>Amazon.SimpleEmailV2.Model.BatchGetMetricDataQuery.Id</property>
248266
<min>1</min>

0 commit comments

Comments
 (0)