Menu
AWS CloudFormation
User Guide (API Version 2010-05-15)

AWS::SES::ReceiptRule

The AWS::SES::ReceiptRule resource specifies which actions Amazon SES should take when it receives mail on behalf of one or more email addresses or domains that you own. For more information, see Creating Receipt Rules for Amazon SES Email Receiving in the Amazon Simple Email Service Developer Guide.

Syntax

To declare this entity in your AWS CloudFormation template, use the following syntax:

JSON

{ "Type" : "AWS::SES::ReceiptRule", "Properties" : { "After" : String, "Rule" : Rule, "RuleSetName" : String } }

YAML

Type: "AWS::SES::ReceiptRule" Properties: After: String Rule: Rule RuleSetName: String

Properties

After

The name of an existing rule after which the new rule will be placed. If this parameter is null, the new rule will be inserted at the beginning of the rule list.

Required: No

Type: String

Update requires: No interruption

Rule

The specified rule's name, actions, recipients, domains, enabled status, scan status, and TLS policy.

Required: Yes

Type: Amazon SES ReceiptRule Rule

Update requires: No interruption

RuleSetName

The name of the rule set that the receipt rule will be added to.

Required: Yes

Type: String

Update requires: Replacement

Example

JSON

{ "AWSTemplateFormatVersion": "2010-09-09", "Description": "AWS SES ReceiptRule Sample Template", "Parameters": { "RuleSetName": { "Type": "String" }, "ReceiptRuleName1": { "Type": "String" }, "ReceiptRuleName2": { "Type": "String" }, "TlsPolicy": { "Type": "String" }, "HeaderName": { "Type": "String" }, "HeaderValue": { "Type": "String" } }, "Resources": { "ReceiptRule1": { "Type": "AWS::SES::ReceiptRule", "Properties": { "RuleSetName": { "Ref": "RuleSetName" }, "Rule": { "Name": { "Ref": "ReceiptRuleName1" }, "Enabled": true, "ScanEnabled": true, "TlsPolicy": { "Ref": "TlsPolicy" }, "Actions": [ { "AddHeaderAction": { "HeaderName": { "Ref": "HeaderName" }, "HeaderValue": { "Ref": "HeaderValue" } } } ] } } }, "ReceiptRule2": { "Type": "AWS::SES::ReceiptRule", "Properties": { "RuleSetName": { "Ref": "RuleSetName" }, "After": { "Ref": "ReceiptRule1" }, "Rule": { "Name": { "Ref": "ReceiptRuleName2" } } } } } }

YAML

AWSTemplateFormatVersion: 2010-09-09 Description: 'AWS SES ReceiptRule Sample Template' Parameters: RuleSetName: Type: String ReceiptRuleName1: Type: String ReceiptRuleName2: Type: String TlsPolicy: Type: String HeaderName: Type: String HeaderValue: Type: String Resources: ReceiptRule1: Type: "AWS::SES::ReceiptRule" Properties: RuleSetName: !Ref RuleSetName Rule: Name: !Ref ReceiptRuleName1 Enabled: true ScanEnabled: true TlsPolicy: !Ref TlsPolicy Actions: - AddHeaderAction: HeaderName: !Ref HeaderName HeaderValue: !Ref HeaderValue ReceiptRule2: Type: "AWS::SES::ReceiptRule" Properties: RuleSetName: !Ref RuleSetName After: !Ref ReceiptRule1 Rule: Name: !Ref ReceiptRuleName2

See Also