Documentation ¶
Index ¶
- func NewAddHeader_Override(a AddHeader, props *AddHeaderProps)
- func NewBounceTemplate_Override(b BounceTemplate, props *BounceTemplateProps)
- func NewBounce_Override(b Bounce, props *BounceProps)
- func NewLambda_Override(l Lambda, props *LambdaProps)
- func NewS3_Override(s S3, props *S3Props)
- func NewSns_Override(s Sns, props *SnsProps)
- func NewStop_Override(s Stop, props *StopProps)
- type AddHeader
- type AddHeaderProps
- type Bounce
- type BounceProps
- type BounceTemplate
- func BounceTemplate_MAILBOX_DOES_NOT_EXIST() BounceTemplate
- func BounceTemplate_MAILBOX_FULL() BounceTemplate
- func BounceTemplate_MESSAGE_CONTENT_REJECTED() BounceTemplate
- func BounceTemplate_MESSAGE_TOO_LARGE() BounceTemplate
- func BounceTemplate_TEMPORARY_FAILURE() BounceTemplate
- func NewBounceTemplate(props *BounceTemplateProps) BounceTemplate
- type BounceTemplateProps
- type EmailEncoding
- type Lambda
- type LambdaInvocationType
- type LambdaProps
- type S3
- type S3Props
- type Sns
- type SnsProps
- type Stop
- type StopProps
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NewAddHeader_Override ¶
func NewAddHeader_Override(a AddHeader, props *AddHeaderProps)
Experimental.
func NewBounceTemplate_Override ¶
func NewBounceTemplate_Override(b BounceTemplate, props *BounceTemplateProps)
Experimental.
Types ¶
type AddHeader ¶
type AddHeader interface { awsses.IReceiptRuleAction // Returns the receipt rule action specification. // Experimental. Bind(_rule awsses.IReceiptRule) *awsses.ReceiptRuleActionConfig }
Adds a header to the received email.
Example:
import s3 "github.com/aws/aws-cdk-go/awscdk" import actions "github.com/aws/aws-cdk-go/awscdk" bucket := s3.NewBucket(this, jsii.String("Bucket")) topic := sns.NewTopic(this, jsii.String("Topic")) ses.NewReceiptRuleSet(this, jsii.String("RuleSet"), &receiptRuleSetProps{ rules: []receiptRuleOptions{ &receiptRuleOptions{ recipients: []*string{ jsii.String("hello@aws.com"), }, actions: []iReceiptRuleAction{ actions.NewAddHeader(&addHeaderProps{ name: jsii.String("X-Special-Header"), value: jsii.String("aws"), }), actions.NewS3(&s3Props{ bucket: bucket, objectKeyPrefix: jsii.String("emails/"), topic: topic, }), }, }, &receiptRuleOptions{ recipients: []*string{ jsii.String("aws.com"), }, actions: []*iReceiptRuleAction{ actions.NewSns(&snsProps{ topic: topic, }), }, }, }, })
Experimental.
type AddHeaderProps ¶
type AddHeaderProps struct { // The name of the header to add. // // Must be between 1 and 50 characters, // inclusive, and consist of alphanumeric (a-z, A-Z, 0-9) characters // and dashes only. // Experimental. Name *string `field:"required" json:"name" yaml:"name"` // The value of the header to add. // // Must be less than 2048 characters, // and must not contain newline characters ("\r" or "\n"). // Experimental. Value *string `field:"required" json:"value" yaml:"value"` }
Construction properties for a add header action.
Example:
import s3 "github.com/aws/aws-cdk-go/awscdk" import actions "github.com/aws/aws-cdk-go/awscdk" bucket := s3.NewBucket(this, jsii.String("Bucket")) topic := sns.NewTopic(this, jsii.String("Topic")) ses.NewReceiptRuleSet(this, jsii.String("RuleSet"), &receiptRuleSetProps{ rules: []receiptRuleOptions{ &receiptRuleOptions{ recipients: []*string{ jsii.String("hello@aws.com"), }, actions: []iReceiptRuleAction{ actions.NewAddHeader(&addHeaderProps{ name: jsii.String("X-Special-Header"), value: jsii.String("aws"), }), actions.NewS3(&s3Props{ bucket: bucket, objectKeyPrefix: jsii.String("emails/"), topic: topic, }), }, }, &receiptRuleOptions{ recipients: []*string{ jsii.String("aws.com"), }, actions: []*iReceiptRuleAction{ actions.NewSns(&snsProps{ topic: topic, }), }, }, }, })
Experimental.
type Bounce ¶
type Bounce interface { awsses.IReceiptRuleAction // Returns the receipt rule action specification. // Experimental. Bind(_rule awsses.IReceiptRule) *awsses.ReceiptRuleActionConfig }
Rejects the received email by returning a bounce response to the sender and, optionally, publishes a notification to Amazon SNS.
Example:
// The code below shows an example of how to instantiate this type. // The values are placeholders you should change. import "github.com/aws/aws-cdk-go/awscdk" import "github.com/aws/aws-cdk-go/awscdk" var bounceTemplate bounceTemplate var topic topic bounce := awscdk.Aws_ses_actions.NewBounce(&bounceProps{ sender: jsii.String("sender"), template: bounceTemplate, // the properties below are optional topic: topic, })
Experimental.
type BounceProps ¶
type BounceProps struct { // The email address of the sender of the bounced email. // // This is the address // from which the bounce message will be sent. // Experimental. Sender *string `field:"required" json:"sender" yaml:"sender"` // The template containing the message, reply code and status code. // Experimental. Template BounceTemplate `field:"required" json:"template" yaml:"template"` // The SNS topic to notify when the bounce action is taken. // Experimental. Topic awssns.ITopic `field:"optional" json:"topic" yaml:"topic"` }
Construction properties for a bounce action.
Example:
// The code below shows an example of how to instantiate this type. // The values are placeholders you should change. import "github.com/aws/aws-cdk-go/awscdk" import "github.com/aws/aws-cdk-go/awscdk" var bounceTemplate bounceTemplate var topic topic bounceProps := &bounceProps{ sender: jsii.String("sender"), template: bounceTemplate, // the properties below are optional topic: topic, }
Experimental.
type BounceTemplate ¶
type BounceTemplate interface { // Experimental. Props() *BounceTemplateProps }
A bounce template.
Example:
// The code below shows an example of how to instantiate this type. // The values are placeholders you should change. import "github.com/aws/aws-cdk-go/awscdk" bounceTemplate := awscdk.Aws_ses_actions.bounceTemplate_MAILBOX_DOES_NOT_EXIST()
Experimental.
func BounceTemplate_MAILBOX_DOES_NOT_EXIST ¶
func BounceTemplate_MAILBOX_DOES_NOT_EXIST() BounceTemplate
func BounceTemplate_MAILBOX_FULL ¶
func BounceTemplate_MAILBOX_FULL() BounceTemplate
func BounceTemplate_MESSAGE_CONTENT_REJECTED ¶
func BounceTemplate_MESSAGE_CONTENT_REJECTED() BounceTemplate
func BounceTemplate_MESSAGE_TOO_LARGE ¶
func BounceTemplate_MESSAGE_TOO_LARGE() BounceTemplate
func BounceTemplate_TEMPORARY_FAILURE ¶
func BounceTemplate_TEMPORARY_FAILURE() BounceTemplate
func NewBounceTemplate ¶
func NewBounceTemplate(props *BounceTemplateProps) BounceTemplate
Experimental.
type BounceTemplateProps ¶
type BounceTemplateProps struct { // Human-readable text to include in the bounce message. // Experimental. Message *string `field:"required" json:"message" yaml:"message"` // The SMTP reply code, as defined by RFC 5321. // See: https://tools.ietf.org/html/rfc5321 // // Experimental. SmtpReplyCode *string `field:"required" json:"smtpReplyCode" yaml:"smtpReplyCode"` // The SMTP enhanced status code, as defined by RFC 3463. // See: https://tools.ietf.org/html/rfc3463 // // Experimental. StatusCode *string `field:"optional" json:"statusCode" yaml:"statusCode"` }
Construction properties for a BounceTemplate.
Example:
// The code below shows an example of how to instantiate this type. // The values are placeholders you should change. import "github.com/aws/aws-cdk-go/awscdk" bounceTemplateProps := &bounceTemplateProps{ message: jsii.String("message"), smtpReplyCode: jsii.String("smtpReplyCode"), // the properties below are optional statusCode: jsii.String("statusCode"), }
Experimental.
type EmailEncoding ¶
type EmailEncoding string
The type of email encoding to use for a SNS action. Experimental.
const ( // Base 64. // Experimental. EmailEncoding_BASE64 EmailEncoding = "BASE64" // UTF-8. // Experimental. EmailEncoding_UTF8 EmailEncoding = "UTF8" )
type Lambda ¶
type Lambda interface { awsses.IReceiptRuleAction // Returns the receipt rule action specification. // Experimental. Bind(rule awsses.IReceiptRule) *awsses.ReceiptRuleActionConfig }
Calls an AWS Lambda function, and optionally, publishes a notification to Amazon SNS.
Example:
// The code below shows an example of how to instantiate this type. // The values are placeholders you should change. import "github.com/aws/aws-cdk-go/awscdk" import "github.com/aws/aws-cdk-go/awscdk" import "github.com/aws/aws-cdk-go/awscdk" var function_ function var topic topic lambda := awscdk.Aws_ses_actions.NewLambda(&lambdaProps{ function: function_, // the properties below are optional invocationType: awscdk.*Aws_ses_actions.lambdaInvocationType_EVENT, topic: topic, })
Experimental.
type LambdaInvocationType ¶
type LambdaInvocationType string
The type of invocation to use for a Lambda Action. Experimental.
const ( // The function will be invoked asynchronously. // Experimental. LambdaInvocationType_EVENT LambdaInvocationType = "EVENT" // The function will be invoked sychronously. // // Use RequestResponse only when // you want to make a mail flow decision, such as whether to stop the receipt // rule or the receipt rule set. // Experimental. LambdaInvocationType_REQUEST_RESPONSE LambdaInvocationType = "REQUEST_RESPONSE" )
type LambdaProps ¶
type LambdaProps struct { // The Lambda function to invoke. // Experimental. Function awslambda.IFunction `field:"required" json:"function" yaml:"function"` // The invocation type of the Lambda function. // Experimental. InvocationType LambdaInvocationType `field:"optional" json:"invocationType" yaml:"invocationType"` // The SNS topic to notify when the Lambda action is taken. // Experimental. Topic awssns.ITopic `field:"optional" json:"topic" yaml:"topic"` }
Construction properties for a Lambda action.
Example:
// The code below shows an example of how to instantiate this type. // The values are placeholders you should change. import "github.com/aws/aws-cdk-go/awscdk" import "github.com/aws/aws-cdk-go/awscdk" import "github.com/aws/aws-cdk-go/awscdk" var function_ function var topic topic lambdaProps := &lambdaProps{ function: function_, // the properties below are optional invocationType: awscdk.Aws_ses_actions.lambdaInvocationType_EVENT, topic: topic, }
Experimental.
type S3 ¶
type S3 interface { awsses.IReceiptRuleAction // Returns the receipt rule action specification. // Experimental. Bind(rule awsses.IReceiptRule) *awsses.ReceiptRuleActionConfig }
Saves the received message to an Amazon S3 bucket and, optionally, publishes a notification to Amazon SNS.
Example:
import s3 "github.com/aws/aws-cdk-go/awscdk" import actions "github.com/aws/aws-cdk-go/awscdk" bucket := s3.NewBucket(this, jsii.String("Bucket")) topic := sns.NewTopic(this, jsii.String("Topic")) ses.NewReceiptRuleSet(this, jsii.String("RuleSet"), &receiptRuleSetProps{ rules: []receiptRuleOptions{ &receiptRuleOptions{ recipients: []*string{ jsii.String("hello@aws.com"), }, actions: []iReceiptRuleAction{ actions.NewAddHeader(&addHeaderProps{ name: jsii.String("X-Special-Header"), value: jsii.String("aws"), }), actions.NewS3(&s3Props{ bucket: bucket, objectKeyPrefix: jsii.String("emails/"), topic: topic, }), }, }, &receiptRuleOptions{ recipients: []*string{ jsii.String("aws.com"), }, actions: []*iReceiptRuleAction{ actions.NewSns(&snsProps{ topic: topic, }), }, }, }, })
Experimental.
type S3Props ¶
type S3Props struct { // The S3 bucket that incoming email will be saved to. // Experimental. Bucket awss3.IBucket `field:"required" json:"bucket" yaml:"bucket"` // The master key that SES should use to encrypt your emails before saving them to the S3 bucket. // Experimental. KmsKey awskms.IKey `field:"optional" json:"kmsKey" yaml:"kmsKey"` // The key prefix of the S3 bucket. // Experimental. ObjectKeyPrefix *string `field:"optional" json:"objectKeyPrefix" yaml:"objectKeyPrefix"` // The SNS topic to notify when the S3 action is taken. // Experimental. Topic awssns.ITopic `field:"optional" json:"topic" yaml:"topic"` }
Construction properties for a S3 action.
Example:
import s3 "github.com/aws/aws-cdk-go/awscdk" import actions "github.com/aws/aws-cdk-go/awscdk" bucket := s3.NewBucket(this, jsii.String("Bucket")) topic := sns.NewTopic(this, jsii.String("Topic")) ses.NewReceiptRuleSet(this, jsii.String("RuleSet"), &receiptRuleSetProps{ rules: []receiptRuleOptions{ &receiptRuleOptions{ recipients: []*string{ jsii.String("hello@aws.com"), }, actions: []iReceiptRuleAction{ actions.NewAddHeader(&addHeaderProps{ name: jsii.String("X-Special-Header"), value: jsii.String("aws"), }), actions.NewS3(&s3Props{ bucket: bucket, objectKeyPrefix: jsii.String("emails/"), topic: topic, }), }, }, &receiptRuleOptions{ recipients: []*string{ jsii.String("aws.com"), }, actions: []*iReceiptRuleAction{ actions.NewSns(&snsProps{ topic: topic, }), }, }, }, })
Experimental.
type Sns ¶
type Sns interface { awsses.IReceiptRuleAction // Returns the receipt rule action specification. // Experimental. Bind(_rule awsses.IReceiptRule) *awsses.ReceiptRuleActionConfig }
Publishes the email content within a notification to Amazon SNS.
Example:
import s3 "github.com/aws/aws-cdk-go/awscdk" import actions "github.com/aws/aws-cdk-go/awscdk" bucket := s3.NewBucket(this, jsii.String("Bucket")) topic := sns.NewTopic(this, jsii.String("Topic")) ses.NewReceiptRuleSet(this, jsii.String("RuleSet"), &receiptRuleSetProps{ rules: []receiptRuleOptions{ &receiptRuleOptions{ recipients: []*string{ jsii.String("hello@aws.com"), }, actions: []iReceiptRuleAction{ actions.NewAddHeader(&addHeaderProps{ name: jsii.String("X-Special-Header"), value: jsii.String("aws"), }), actions.NewS3(&s3Props{ bucket: bucket, objectKeyPrefix: jsii.String("emails/"), topic: topic, }), }, }, &receiptRuleOptions{ recipients: []*string{ jsii.String("aws.com"), }, actions: []*iReceiptRuleAction{ actions.NewSns(&snsProps{ topic: topic, }), }, }, }, })
Experimental.
type SnsProps ¶
type SnsProps struct { // The SNS topic to notify. // Experimental. Topic awssns.ITopic `field:"required" json:"topic" yaml:"topic"` // The encoding to use for the email within the Amazon SNS notification. // Experimental. Encoding EmailEncoding `field:"optional" json:"encoding" yaml:"encoding"` }
Construction properties for a SNS action.
Example:
import s3 "github.com/aws/aws-cdk-go/awscdk" import actions "github.com/aws/aws-cdk-go/awscdk" bucket := s3.NewBucket(this, jsii.String("Bucket")) topic := sns.NewTopic(this, jsii.String("Topic")) ses.NewReceiptRuleSet(this, jsii.String("RuleSet"), &receiptRuleSetProps{ rules: []receiptRuleOptions{ &receiptRuleOptions{ recipients: []*string{ jsii.String("hello@aws.com"), }, actions: []iReceiptRuleAction{ actions.NewAddHeader(&addHeaderProps{ name: jsii.String("X-Special-Header"), value: jsii.String("aws"), }), actions.NewS3(&s3Props{ bucket: bucket, objectKeyPrefix: jsii.String("emails/"), topic: topic, }), }, }, &receiptRuleOptions{ recipients: []*string{ jsii.String("aws.com"), }, actions: []*iReceiptRuleAction{ actions.NewSns(&snsProps{ topic: topic, }), }, }, }, })
Experimental.
type Stop ¶
type Stop interface { awsses.IReceiptRuleAction // Returns the receipt rule action specification. // Experimental. Bind(_rule awsses.IReceiptRule) *awsses.ReceiptRuleActionConfig }
Terminates the evaluation of the receipt rule set and optionally publishes a notification to Amazon SNS.
Example:
// The code below shows an example of how to instantiate this type. // The values are placeholders you should change. import "github.com/aws/aws-cdk-go/awscdk" import "github.com/aws/aws-cdk-go/awscdk" var topic topic stop := awscdk.Aws_ses_actions.NewStop(&stopProps{ topic: topic, })
Experimental.
type StopProps ¶
type StopProps struct { // The SNS topic to notify when the stop action is taken. // Experimental. Topic awssns.ITopic `field:"optional" json:"topic" yaml:"topic"` }
Construction properties for a stop action.
Example:
// The code below shows an example of how to instantiate this type. // The values are placeholders you should change. import "github.com/aws/aws-cdk-go/awscdk" import "github.com/aws/aws-cdk-go/awscdk" var topic topic stopProps := &stopProps{ topic: topic, }
Experimental.