Show / Hide Table of Contents

Namespace Pulumi.Aws.Ses

Classes

ActiveReceiptRuleSet

Provides a resource to designate the active SES receipt rule set

Example Usage

using Pulumi;
using Aws = Pulumi.Aws;

class MyStack : Stack
{
public MyStack()
{
    var main = new Aws.Ses.ActiveReceiptRuleSet("main", new Aws.Ses.ActiveReceiptRuleSetArgs
    {
        RuleSetName = "primary-rules",
    });
}

}

ActiveReceiptRuleSetArgs

ActiveReceiptRuleSetState

ConfgurationSet

ConfgurationSetArgs

ConfgurationSetState

ConfigurationSet

Provides an SES configuration set resource

Example Usage

using Pulumi;
using Aws = Pulumi.Aws;

class MyStack : Stack
{
public MyStack()
{
    var test = new Aws.Ses.ConfigurationSet("test", new Aws.Ses.ConfigurationSetArgs
    {
    });
}

}

ConfigurationSetArgs

ConfigurationSetState

DomainDkim

Provides an SES domain DKIM generation resource.

Domain ownership needs to be confirmed first using ses_domain_identity Resource

Example Usage

using System.Collections.Generic;
using Pulumi;
using Aws = Pulumi.Aws;

class MyStack : Stack
{
public MyStack()
{
    var exampleDomainIdentity = new Aws.Ses.DomainIdentity("exampleDomainIdentity", new Aws.Ses.DomainIdentityArgs
    {
        Domain = "example.com",
    });
    var exampleDomainDkim = new Aws.Ses.DomainDkim("exampleDomainDkim", new Aws.Ses.DomainDkimArgs
    {
        Domain = exampleDomainIdentity.Domain,
    });
    var exampleAmazonsesDkimRecord = new List<Aws.Route53.Record>();
    for (var rangeIndex = 0; rangeIndex < 3; rangeIndex++)
    {
        var range = new { Value = rangeIndex };
        exampleAmazonsesDkimRecord.Add(new Aws.Route53.Record($"exampleAmazonsesDkimRecord-{range.Value}", new Aws.Route53.RecordArgs
        {
            Name = exampleDomainDkim.DkimTokens[range.Value].Apply(dkimTokens => $"{dkimTokens}._domainkey.example.com"),
            Records = 
            {
                exampleDomainDkim.DkimTokens[range.Value].Apply(dkimTokens => $"{dkimTokens}.dkim.amazonses.com"),
            },
            Ttl = "600",
            Type = "CNAME",
            ZoneId = "ABCDEFGHIJ123",
        }));
    }
}

}

DomainDkimArgs

DomainDkimState

DomainIdentity

Provides an SES domain identity resource

Example Usage

using Pulumi;
using Aws = Pulumi.Aws;

class MyStack : Stack
{
public MyStack()
{
    var example = new Aws.Ses.DomainIdentity("example", new Aws.Ses.DomainIdentityArgs
    {
        Domain = "example.com",
    });
    var exampleAmazonsesVerificationRecord = new Aws.Route53.Record("exampleAmazonsesVerificationRecord", new Aws.Route53.RecordArgs
    {
        Name = "_amazonses.example.com",
        Records = 
        {
            example.VerificationToken,
        },
        Ttl = "600",
        Type = "TXT",
        ZoneId = "ABCDEFGHIJ123",
    });
}

}

DomainIdentityArgs

DomainIdentityState

DomainIdentityVerification

Represents a successful verification of an SES domain identity.

Most commonly, this resource is used together with aws.route53.Record and aws.ses.DomainIdentity to request an SES domain identity, deploy the required DNS verification records, and wait for verification to complete.

WARNING: This resource implements a part of the verification workflow. It does not represent a real-world entity in AWS, therefore changing or deleting this resource on its own has no immediate effect.

Example Usage

using Pulumi;
using Aws = Pulumi.Aws;

class MyStack : Stack
{
public MyStack()
{
    var example = new Aws.Ses.DomainIdentity("example", new Aws.Ses.DomainIdentityArgs
    {
        Domain = "example.com",
    });
    var exampleAmazonsesVerificationRecord = new Aws.Route53.Record("exampleAmazonsesVerificationRecord", new Aws.Route53.RecordArgs
    {
        Name = example.Id.Apply(id => $"_amazonses.{id}"),
        Records = 
        {
            example.VerificationToken,
        },
        Ttl = "600",
        Type = "TXT",
        ZoneId = aws_route53_zone.Example.Zone_id,
    });
    var exampleVerification = new Aws.Ses.DomainIdentityVerification("exampleVerification", new Aws.Ses.DomainIdentityVerificationArgs
    {
        Domain = example.Id,
    });
}

}

DomainIdentityVerificationArgs

DomainIdentityVerificationState

EmailIdentity

Provides an SES email identity resource

Example Usage

using Pulumi;
using Aws = Pulumi.Aws;

class MyStack : Stack
{
public MyStack()
{
    var example = new Aws.Ses.EmailIdentity("example", new Aws.Ses.EmailIdentityArgs
    {
        Email = "email@example.com",
    });
}

}

EmailIdentityArgs

EmailIdentityState

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",
        },
    });
}

}

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",
        },
    });
}

}

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,
        },
    });
}

}

EventDestinationArgs

EventDestinationState

IdentityNotificationTopic

Resource for managing SES Identity Notification Topics

Example Usage

using Pulumi;
using Aws = Pulumi.Aws;

class MyStack : Stack
{
public MyStack()
{
    var test = new Aws.Ses.IdentityNotificationTopic("test", new Aws.Ses.IdentityNotificationTopicArgs
    {
        Identity = aws_ses_domain_identity.Example.Domain,
        IncludeOriginalHeaders = true,
        NotificationType = "Bounce",
        TopicArn = aws_sns_topic.Example.Arn,
    });
}

}

IdentityNotificationTopicArgs

IdentityNotificationTopicState

IdentityPolicy

Manages a SES Identity Policy. More information about SES Sending Authorization Policies can be found in the SES Developer Guide.

Example Usage

using Pulumi;
using Aws = Pulumi.Aws;

class MyStack : Stack
{
public MyStack()
{
    var exampleDomainIdentity = new Aws.Ses.DomainIdentity("exampleDomainIdentity", new Aws.Ses.DomainIdentityArgs
    {
        Domain = "example.com",
    });
    var examplePolicyDocument = exampleDomainIdentity.Arn.Apply(arn => Aws.Iam.GetPolicyDocument.InvokeAsync(new Aws.Iam.GetPolicyDocumentArgs
    {
        Statements = 
        {
            new Aws.Iam.Inputs.GetPolicyDocumentStatementArgs
            {
                Actions = 
                {
                    "SES:SendEmail",
                    "SES:SendRawEmail",
                },
                Principals = 
                {
                    new Aws.Iam.Inputs.GetPolicyDocumentStatementPrincipalArgs
                    {
                        Identifiers = 
                        {
                            "*",
                        },
                        Type = "AWS",
                    },
                },
                Resources = 
                {
                    arn,
                },
            },
        },
    }));
    var exampleIdentityPolicy = new Aws.Ses.IdentityPolicy("exampleIdentityPolicy", new Aws.Ses.IdentityPolicyArgs
    {
        Identity = exampleDomainIdentity.Arn,
        Policy = examplePolicyDocument.Apply(examplePolicyDocument => examplePolicyDocument.Json),
    });
}

}

IdentityPolicyArgs

IdentityPolicyState

MailFrom

Provides an SES domain MAIL FROM resource.

NOTE: For the MAIL FROM domain to be fully usable, this resource should be paired with the aws.ses.DomainIdentity resource. To validate the MAIL FROM domain, a DNS MX record is required. To pass SPF checks, a DNS TXT record may also be required. See the Amazon SES MAIL FROM documentation for more information.

Example Usage

using Pulumi;
using Aws = Pulumi.Aws;

class MyStack : Stack
{
public MyStack()
{
    // Example SES Domain Identity
    var exampleDomainIdentity = new Aws.Ses.DomainIdentity("exampleDomainIdentity", new Aws.Ses.DomainIdentityArgs
    {
        Domain = "example.com",
    });
    var exampleMailFrom = new Aws.Ses.MailFrom("exampleMailFrom", new Aws.Ses.MailFromArgs
    {
        Domain = exampleDomainIdentity.Domain,
        MailFromDomain = exampleDomainIdentity.Domain.Apply(domain => $"bounce.{domain}"),
    });
    // Example Route53 MX record
    var exampleSesDomainMailFromMx = new Aws.Route53.Record("exampleSesDomainMailFromMx", new Aws.Route53.RecordArgs
    {
        Name = exampleMailFrom.MailFromDomain,
        Records = 
        {
            "10 feedback-smtp.us-east-1.amazonses.com",
        },
        Ttl = "600",
        Type = "MX",
        ZoneId = aws_route53_zone.Example.Id,
    });
    // Example Route53 TXT record for SPF
    var exampleSesDomainMailFromTxt = new Aws.Route53.Record("exampleSesDomainMailFromTxt", new Aws.Route53.RecordArgs
    {
        Name = exampleMailFrom.MailFromDomain,
        Records = 
        {
            "v=spf1 include:amazonses.com -all",
        },
        Ttl = "600",
        Type = "TXT",
        ZoneId = aws_route53_zone.Example.Id,
    });
}

}

MailFromArgs

MailFromState

ReceiptFilter

Provides an SES receipt filter resource

Example Usage

using Pulumi;
using Aws = Pulumi.Aws;

class MyStack : Stack
{
public MyStack()
{
    var filter = new Aws.Ses.ReceiptFilter("filter", new Aws.Ses.ReceiptFilterArgs
    {
        Cidr = "10.10.10.10",
        Policy = "Block",
    });
}

}

ReceiptFilterArgs

ReceiptFilterState

ReceiptRule

Provides an SES receipt rule resource

Example Usage

using Pulumi;
using Aws = Pulumi.Aws;

class MyStack : Stack
{
public MyStack()
{
    // Add a header to the email and store it in S3
    var store = new Aws.Ses.ReceiptRule("store", new Aws.Ses.ReceiptRuleArgs
    {
        AddHeaderActions = 
        {
            new Aws.Ses.Inputs.ReceiptRuleAddHeaderActionArgs
            {
                HeaderName = "Custom-Header",
                HeaderValue = "Added by SES",
                Position = 1,
            },
        },
        Enabled = true,
        Recipients = 
        {
            "karen@example.com",
        },
        RuleSetName = "default-rule-set",
        S3Actions = 
        {
            new Aws.Ses.Inputs.ReceiptRuleS3ActionArgs
            {
                BucketName = "emails",
                Position = 2,
            },
        },
        ScanEnabled = true,
    });
}

}

ReceiptRuleArgs

ReceiptRuleSet

Provides an SES receipt rule set resource

Example Usage

using Pulumi;
using Aws = Pulumi.Aws;

class MyStack : Stack
{
public MyStack()
{
    var main = new Aws.Ses.ReceiptRuleSet("main", new Aws.Ses.ReceiptRuleSetArgs
    {
        RuleSetName = "primary-rules",
    });
}

}

ReceiptRuleSetArgs

ReceiptRuleSetState

ReceiptRuleState

Template

Provides a resource to create a SES template.

Example Usage

using Pulumi;
using Aws = Pulumi.Aws;

class MyStack : Stack
{
public MyStack()
{
    var myTemplate = new Aws.Ses.Template("myTemplate", new Aws.Ses.TemplateArgs
    {
        Html = "<h1>Hello {{name}},</h1><p>Your favorite animal is {{favoriteanimal}}.</p>",
        Subject = "Greetings, {{name}}!",
        Text = @"Hello {{name}},
Your favorite animal is {{favoriteanimal}}.
",
    });
}

}

TemplateArgs

TemplateState

Back to top Copyright 2016-2020, Pulumi Corporation.