Resource: awsSesReceiptRule
Provides an SES receipt rule resource
Example Usage
/*Provider bindings are generated by running cdktf get.
See https://cdk.tf/provider-generation for more details.*/
import * as aws from "./.gen/providers/aws";
new aws.sesReceiptRule.SesReceiptRule(this, "store", {
addHeaderAction: [
{
headerName: "Custom-Header",
headerValue: "Added by SES",
position: 1,
},
],
enabled: true,
name: "store",
recipients: ["karen@example.com"],
ruleSetName: "default-rule-set",
s3Action: [
{
bucketName: "emails",
position: 2,
},
],
scanEnabled: true,
});
Argument Reference
The following arguments are supported:
name
- (Required) The name of the ruleruleSetName
- (Required) The name of the rule setafter
- (Optional) The name of the rule to place this rule afterenabled
- (Optional) If true, the rule will be enabledrecipients
- (Optional) A list of email addressesscanEnabled
- (Optional) If true, incoming emails will be scanned for spam and virusestlsPolicy
- (Optional)require
oroptional
addHeaderAction
- (Optional) A list of Add Header Action blocks. Documented below.bounceAction
- (Optional) A list of Bounce Action blocks. Documented below.lambdaAction
- (Optional) A list of Lambda Action blocks. Documented below.s3Action
- (Optional) A list of S3 Action blocks. Documented below.snsAction
- (Optional) A list of SNS Action blocks. Documented below.stopAction
- (Optional) A list of Stop Action blocks. Documented below.workmailAction
- (Optional) A list of WorkMail Action blocks. Documented below.
Add header actions support the following:
headerName
- (Required) The name of the header to addheaderValue
- (Required) The value of the header to addposition
- (Required) The position of the action in the receipt rule
Bounce actions support the following:
message
- (Required) The message to sendsender
- (Required) The email address of the sendersmtpReplyCode
- (Required) The RFC 5321 SMTP reply codestatusCode
- (Optional) The RFC 3463 SMTP enhanced status codetopicArn
- (Optional) The ARN of an SNS topic to notifyposition
- (Required) The position of the action in the receipt rule
Lambda actions support the following:
functionArn
- (Required) The ARN of the Lambda function to invokeinvocationType
- (Optional)event
orrequestResponse
topicArn
- (Optional) The ARN of an SNS topic to notifyposition
- (Required) The position of the action in the receipt rule
S3 actions support the following:
bucketName
- (Required) The name of the S3 bucketkmsKeyArn
- (Optional) The ARN of the KMS keyobjectKeyPrefix
- (Optional) The key prefix of the S3 buckettopicArn
- (Optional) The ARN of an SNS topic to notifyposition
- (Required) The position of the action in the receipt rule
SNS actions support the following:
topicArn
- (Required) The ARN of an SNS topic to notifyposition
- (Required) The position of the action in the receipt ruleencoding
- (Optional) The encoding to use for the email within the Amazon SNS notification. Default value isutf8
.
Stop actions support the following:
scope
- (Required) The scope to apply. The only acceptable value isruleSet
.topicArn
- (Optional) The ARN of an SNS topic to notifyposition
- (Required) The position of the action in the receipt rule
WorkMail actions support the following:
organizationArn
- (Required) The ARN of the WorkMail organizationtopicArn
- (Optional) The ARN of an SNS topic to notifyposition
- (Required) The position of the action in the receipt rule
Attributes Reference
In addition to all arguments above, the following attributes are exported:
id
- The SES receipt rule name.arn
- The SES receipt rule ARN.
Import
SES receipt rules can be imported using the ruleset name and rule name separated by :
.