Skip to content

Resource: awsSesDomainIdentity

Provides an SES domain identity resource

Example Usage

Basic 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.sesDomainIdentity.SesDomainIdentity(this, "example", {
  domain: "example.com",
});

With Route53 Record

/*Provider bindings are generated by running cdktf get.
See https://cdk.tf/provider-generation for more details.*/
import * as aws from "./.gen/providers/aws";
const awsSesDomainIdentityExample = new aws.sesDomainIdentity.SesDomainIdentity(
  this,
  "example",
  {
    domain: "example.com",
  }
);
new aws.route53Record.Route53Record(
  this,
  "example_amazonses_verification_record",
  {
    name: "_amazonses.example.com",
    records: [awsSesDomainIdentityExample.verificationToken],
    ttl: "600",
    type: "TXT",
    zoneId: "ABCDEFGHIJ123",
  }
);

Argument Reference

The following arguments are supported:

  • domain - (Required) The domain name to assign to SES

Attributes Reference

In addition to all arguments above, the following attributes are exported:

  • arn - The ARN of the domain identity.
  • verificationToken - A code which when added to the domain as a TXT record will signal to SES that the owner of the domain has authorised SES to act on their behalf. The domain identity will be in state "verification pending" until this is done. See the With Route53 Record example for how this might be achieved when the domain is hosted in Route 53 and managed by Terraform. Find out more about verifying domains in Amazon SES in the AWS SES docs.

Import

SES domain identities can be imported using the domain name.

$ terraform import aws_ses_domain_identity.example example.com