EventDestination
Provides an SES event destination
Example Usage
CloudWatch Destination
using Pulumi;
using Aws = Pulumi.Aws;
class MyStack : Stack
{
public MyStack()
{
var cloudwatch = new Aws.Ses.EventDestination("cloudwatch", new Aws.Ses.EventDestinationArgs
{
CloudwatchDestinations =
{
new Aws.Ses.Inputs.EventDestinationCloudwatchDestinationArgs
{
DefaultValue = "default",
DimensionName = "dimension",
ValueSource = "emailHeader",
},
},
ConfigurationSetName = aws_ses_configuration_set.Example.Name,
Enabled = true,
MatchingTypes =
{
"bounce",
"send",
},
});
}
}
package main
import (
"github.com/pulumi/pulumi-aws/sdk/v2/go/aws/ses"
"github.com/pulumi/pulumi/sdk/v2/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := ses.NewEventDestination(ctx, "cloudwatch", &ses.EventDestinationArgs{
CloudwatchDestinations: ses.EventDestinationCloudwatchDestinationArray{
&ses.EventDestinationCloudwatchDestinationArgs{
DefaultValue: pulumi.String("default"),
DimensionName: pulumi.String("dimension"),
ValueSource: pulumi.String("emailHeader"),
},
},
ConfigurationSetName: pulumi.String(aws_ses_configuration_set.Example.Name),
Enabled: pulumi.Bool(true),
MatchingTypes: pulumi.StringArray{
pulumi.String("bounce"),
pulumi.String("send"),
},
})
if err != nil {
return err
}
return nil
})
}import pulumi
import pulumi_aws as aws
cloudwatch = aws.ses.EventDestination("cloudwatch",
cloudwatch_destinations=[{
"default_value": "default",
"dimensionName": "dimension",
"valueSource": "emailHeader",
}],
configuration_set_name=aws_ses_configuration_set["example"]["name"],
enabled=True,
matching_types=[
"bounce",
"send",
])import * as pulumi from "@pulumi/pulumi";
import * as aws from "@pulumi/aws";
const cloudwatch = new aws.ses.EventDestination("cloudwatch", {
cloudwatchDestinations: [{
defaultValue: "default",
dimensionName: "dimension",
valueSource: "emailHeader",
}],
configurationSetName: aws_ses_configuration_set_example.name,
enabled: true,
matchingTypes: [
"bounce",
"send",
],
});Kinesis Destination
using Pulumi;
using Aws = Pulumi.Aws;
class MyStack : Stack
{
public MyStack()
{
var kinesis = new Aws.Ses.EventDestination("kinesis", new Aws.Ses.EventDestinationArgs
{
ConfigurationSetName = aws_ses_configuration_set.Example.Name,
Enabled = true,
KinesisDestination = new Aws.Ses.Inputs.EventDestinationKinesisDestinationArgs
{
RoleArn = aws_iam_role.Example.Arn,
StreamArn = aws_kinesis_firehose_delivery_stream.Example.Arn,
},
MatchingTypes =
{
"bounce",
"send",
},
});
}
}
package main
import (
"github.com/pulumi/pulumi-aws/sdk/v2/go/aws/ses"
"github.com/pulumi/pulumi/sdk/v2/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := ses.NewEventDestination(ctx, "kinesis", &ses.EventDestinationArgs{
ConfigurationSetName: pulumi.String(aws_ses_configuration_set.Example.Name),
Enabled: pulumi.Bool(true),
KinesisDestination: &ses.EventDestinationKinesisDestinationArgs{
RoleArn: pulumi.String(aws_iam_role.Example.Arn),
StreamArn: pulumi.String(aws_kinesis_firehose_delivery_stream.Example.Arn),
},
MatchingTypes: pulumi.StringArray{
pulumi.String("bounce"),
pulumi.String("send"),
},
})
if err != nil {
return err
}
return nil
})
}import pulumi
import pulumi_aws as aws
kinesis = aws.ses.EventDestination("kinesis",
configuration_set_name=aws_ses_configuration_set["example"]["name"],
enabled=True,
kinesis_destination={
"role_arn": aws_iam_role["example"]["arn"],
"stream_arn": aws_kinesis_firehose_delivery_stream["example"]["arn"],
},
matching_types=[
"bounce",
"send",
])import * as pulumi from "@pulumi/pulumi";
import * as aws from "@pulumi/aws";
const kinesis = new aws.ses.EventDestination("kinesis", {
configurationSetName: aws_ses_configuration_set_example.name,
enabled: true,
kinesisDestination: {
roleArn: aws_iam_role_example.arn,
streamArn: aws_kinesis_firehose_delivery_stream_example.arn,
},
matchingTypes: [
"bounce",
"send",
],
});SNS Destination
using Pulumi;
using Aws = Pulumi.Aws;
class MyStack : Stack
{
public MyStack()
{
var sns = new Aws.Ses.EventDestination("sns", new Aws.Ses.EventDestinationArgs
{
ConfigurationSetName = aws_ses_configuration_set.Example.Name,
Enabled = true,
MatchingTypes =
{
"bounce",
"send",
},
SnsDestination = new Aws.Ses.Inputs.EventDestinationSnsDestinationArgs
{
TopicArn = aws_sns_topic.Example.Arn,
},
});
}
}
package main
import (
"github.com/pulumi/pulumi-aws/sdk/v2/go/aws/ses"
"github.com/pulumi/pulumi/sdk/v2/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := ses.NewEventDestination(ctx, "sns", &ses.EventDestinationArgs{
ConfigurationSetName: pulumi.String(aws_ses_configuration_set.Example.Name),
Enabled: pulumi.Bool(true),
MatchingTypes: pulumi.StringArray{
pulumi.String("bounce"),
pulumi.String("send"),
},
SnsDestination: &ses.EventDestinationSnsDestinationArgs{
TopicArn: pulumi.String(aws_sns_topic.Example.Arn),
},
})
if err != nil {
return err
}
return nil
})
}import pulumi
import pulumi_aws as aws
sns = aws.ses.EventDestination("sns",
configuration_set_name=aws_ses_configuration_set["example"]["name"],
enabled=True,
matching_types=[
"bounce",
"send",
],
sns_destination={
"topic_arn": aws_sns_topic["example"]["arn"],
})import * as pulumi from "@pulumi/pulumi";
import * as aws from "@pulumi/aws";
const sns = new aws.ses.EventDestination("sns", {
configurationSetName: aws_ses_configuration_set_example.name,
enabled: true,
matchingTypes: [
"bounce",
"send",
],
snsDestination: {
topicArn: aws_sns_topic_example.arn,
},
});Create a EventDestination Resource
new EventDestination(name: string, args: EventDestinationArgs, opts?: CustomResourceOptions);def EventDestination(resource_name, opts=None, cloudwatch_destinations=None, configuration_set_name=None, enabled=None, kinesis_destination=None, matching_types=None, name=None, sns_destination=None, __props__=None);func NewEventDestination(ctx *Context, name string, args EventDestinationArgs, opts ...ResourceOption) (*EventDestination, error)public EventDestination(string name, EventDestinationArgs args, CustomResourceOptions? opts = null)- name string
- The unique name of the resource.
- args EventDestinationArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- resource_name str
- The unique name of the resource.
- opts ResourceOptions
- A bag of options that control this resource's behavior.
- ctx Context
- Context object for the current deployment.
- name string
- The unique name of the resource.
- args EventDestinationArgs
- The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args EventDestinationArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
EventDestination Resource Properties
To learn more about resource properties and how to use them, see Inputs and Outputs in the Programming Model docs.
Inputs
The EventDestination resource accepts the following input properties:
- Configuration
Set stringName The name of the configuration set
- Matching
Types List<string> A list of matching types. May be any of
"send","reject","bounce","complaint","delivery","open","click", or"renderingFailure".- Cloudwatch
Destinations List<EventDestination Cloudwatch Destination Args> CloudWatch destination for the events
- Enabled bool
If true, the event destination will be enabled
- Kinesis
Destination EventDestination Kinesis Destination Args Send the events to a kinesis firehose destination
- Name string
The name of the event destination
- Sns
Destination EventDestination Sns Destination Args Send the events to an SNS Topic destination
- Configuration
Set stringName The name of the configuration set
- Matching
Types []string A list of matching types. May be any of
"send","reject","bounce","complaint","delivery","open","click", or"renderingFailure".- Cloudwatch
Destinations []EventDestination Cloudwatch Destination CloudWatch destination for the events
- Enabled bool
If true, the event destination will be enabled
- Kinesis
Destination EventDestination Kinesis Destination Send the events to a kinesis firehose destination
- Name string
The name of the event destination
- Sns
Destination EventDestination Sns Destination Send the events to an SNS Topic destination
- configuration
Set stringName The name of the configuration set
- matching
Types string[] A list of matching types. May be any of
"send","reject","bounce","complaint","delivery","open","click", or"renderingFailure".- cloudwatch
Destinations EventDestination Cloudwatch Destination[] CloudWatch destination for the events
- enabled boolean
If true, the event destination will be enabled
- kinesis
Destination EventDestination Kinesis Destination Send the events to a kinesis firehose destination
- name string
The name of the event destination
- sns
Destination EventDestination Sns Destination Send the events to an SNS Topic destination
- configuration_
set_ strname The name of the configuration set
- matching_
types List[str] A list of matching types. May be any of
"send","reject","bounce","complaint","delivery","open","click", or"renderingFailure".- cloudwatch_
destinations List[EventDestination Cloudwatch Destination] CloudWatch destination for the events
- enabled bool
If true, the event destination will be enabled
- kinesis_
destination Dict[EventDestination Kinesis Destination] Send the events to a kinesis firehose destination
- name str
The name of the event destination
- sns_
destination Dict[EventDestination Sns Destination] Send the events to an SNS Topic destination
Outputs
All input properties are implicitly available as output properties. Additionally, the EventDestination resource produces the following output properties:
Look up an Existing EventDestination Resource
Get an existing EventDestination resource’s state with the given name, ID, and optional extra properties used to qualify the lookup.
public static get(name: string, id: Input<ID>, state?: EventDestinationState, opts?: CustomResourceOptions): EventDestinationstatic get(resource_name, id, opts=None, cloudwatch_destinations=None, configuration_set_name=None, enabled=None, kinesis_destination=None, matching_types=None, name=None, sns_destination=None, __props__=None);func GetEventDestination(ctx *Context, name string, id IDInput, state *EventDestinationState, opts ...ResourceOption) (*EventDestination, error)public static EventDestination Get(string name, Input<string> id, EventDestinationState? state, CustomResourceOptions? opts = null)- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- resource_name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
The following state arguments are supported:
- Cloudwatch
Destinations List<EventDestination Cloudwatch Destination Args> CloudWatch destination for the events
- Configuration
Set stringName The name of the configuration set
- Enabled bool
If true, the event destination will be enabled
- Kinesis
Destination EventDestination Kinesis Destination Args Send the events to a kinesis firehose destination
- Matching
Types List<string> A list of matching types. May be any of
"send","reject","bounce","complaint","delivery","open","click", or"renderingFailure".- Name string
The name of the event destination
- Sns
Destination EventDestination Sns Destination Args Send the events to an SNS Topic destination
- Cloudwatch
Destinations []EventDestination Cloudwatch Destination CloudWatch destination for the events
- Configuration
Set stringName The name of the configuration set
- Enabled bool
If true, the event destination will be enabled
- Kinesis
Destination EventDestination Kinesis Destination Send the events to a kinesis firehose destination
- Matching
Types []string A list of matching types. May be any of
"send","reject","bounce","complaint","delivery","open","click", or"renderingFailure".- Name string
The name of the event destination
- Sns
Destination EventDestination Sns Destination Send the events to an SNS Topic destination
- cloudwatch
Destinations EventDestination Cloudwatch Destination[] CloudWatch destination for the events
- configuration
Set stringName The name of the configuration set
- enabled boolean
If true, the event destination will be enabled
- kinesis
Destination EventDestination Kinesis Destination Send the events to a kinesis firehose destination
- matching
Types string[] A list of matching types. May be any of
"send","reject","bounce","complaint","delivery","open","click", or"renderingFailure".- name string
The name of the event destination
- sns
Destination EventDestination Sns Destination Send the events to an SNS Topic destination
- cloudwatch_
destinations List[EventDestination Cloudwatch Destination] CloudWatch destination for the events
- configuration_
set_ strname The name of the configuration set
- enabled bool
If true, the event destination will be enabled
- kinesis_
destination Dict[EventDestination Kinesis Destination] Send the events to a kinesis firehose destination
- matching_
types List[str] A list of matching types. May be any of
"send","reject","bounce","complaint","delivery","open","click", or"renderingFailure".- name str
The name of the event destination
- sns_
destination Dict[EventDestination Sns Destination] Send the events to an SNS Topic destination
Supporting Types
EventDestinationCloudwatchDestination
- Default
Value string The default value for the event
- Dimension
Name string The name for the dimension
- Value
Source string The source for the value. It can be either
"messageTag"or"emailHeader"
- Default
Value string The default value for the event
- Dimension
Name string The name for the dimension
- Value
Source string The source for the value. It can be either
"messageTag"or"emailHeader"
- default
Value string The default value for the event
- dimension
Name string The name for the dimension
- value
Source string The source for the value. It can be either
"messageTag"or"emailHeader"
- default_
value str The default value for the event
- dimension
Name str The name for the dimension
- value
Source str The source for the value. It can be either
"messageTag"or"emailHeader"
EventDestinationKinesisDestination
- role_
arn str The ARN of the role that has permissions to access the Kinesis Stream
- stream_
arn str The ARN of the Kinesis Stream
EventDestinationSnsDestination
Package Details
- Repository
- https://github.com/pulumi/pulumi-aws
- License
- Apache-2.0
- Notes
- This Pulumi package is based on the
awsTerraform Provider.