email_identities
Creates, updates, deletes, gets or lists an email_identities resource.
Overview
| Name | email_identities |
| Type | Resource |
| Id | aws.sesv2.email_identities |
Fields
The following fields are returned by SELECT queries:
- get_email_identity
- list_email_identities
| Name | Datatype | Description |
|---|---|---|
configuration_set_name | string | The name of a configuration set. Configuration sets are groups of rules that you can apply to the emails you send. You apply a configuration set to an email by including a reference to the configuration set in the headers of the email. When you apply a configuration set to an email, all of the rules in that configuration set are applied to the email. |
dkim_attributes | object | An object that contains information about the DKIM attributes for the identity. |
feedback_forwarding_status | boolean | The feedback forwarding configuration for the identity. If the value is true, you receive email notifications when bounce or complaint events occur. These notifications are sent to the address that you specified in the Return-Path header of the original email. You're required to have a method of tracking bounces and complaints. If you haven't set up another mechanism for receiving bounce or complaint notifications (for example, by setting up an event destination), you receive an email notification when these events occur (even if this setting is disabled). |
identity_type | string | The email identity type. Note: the MANAGED_DOMAIN identity type is not supported. (EMAIL_ADDRESS, DOMAIN, MANAGED_DOMAIN) |
mail_from_attributes | object | An object that contains information about the Mail-From attributes for the email identity. |
policies | object | A map of policy names to policies. |
tags | array | An array of objects that define the tags (keys and values) that are associated with the email identity. |
verification_info | object | An object that contains additional information about the verification status for the identity. |
verification_status | string | The verification status of the identity. The status can be one of the following: PENDING – The verification process was initiated, but Amazon SES hasn't yet been able to verify the identity. SUCCESS – The verification process completed successfully. FAILED – The verification process failed. TEMPORARY_FAILURE – A temporary issue is preventing Amazon SES from determining the verification status of the identity. NOT_STARTED – The verification process hasn't been initiated for the identity. (PENDING, SUCCESS, FAILED, TEMPORARY_FAILURE, NOT_STARTED) |
verified_for_sending_status | boolean | Specifies whether or not the identity is verified. You can only send email from verified email addresses or domains. For more information about verifying identities, see the Amazon Pinpoint User Guide. |
| Name | Datatype | Description |
|---|---|---|
email_identities | array | An array that includes all of the email identities associated with your Amazon Web Services account. |
next_token | string | A token that indicates that there are additional configuration sets to list. To view additional configuration sets, issue another request to ListEmailIdentities, and pass this token in the NextToken parameter. |
Methods
The following methods are available for this resource:
| Name | Accessible by | Required Params | Optional Params | Description |
|---|---|---|---|---|
get_email_identity | select | email_identity, region | Provides information about a specific identity, including the identity's verification status, sending authorization policies, its DKIM authentication status, and its custom Mail-From settings. | |
list_email_identities | select | region | NextToken, PageSize | Returns a list of all of the email identities that are associated with your Amazon Web Services account. An identity can be either an email address or a domain. This operation returns identities that are verified as well as those that aren't. This operation returns identities that are associated with Amazon SES and Amazon Pinpoint. |
create_email_identity | insert | region, EmailIdentity | Starts the process of verifying an email identity. An identity is an email address or domain that you use when you send email. Before you can use an identity to send email, you first have to verify it. By verifying an identity, you demonstrate that you're the owner of the identity, and that you've given Amazon SES API v2 permission to send email from the identity. When you verify an email address, Amazon SES sends an email to the address. Your email address is verified as soon as you follow the link in the verification email. When you verify a domain without specifying the DkimSigningAttributes object, this operation provides a set of DKIM tokens. You can convert these tokens into CNAME records, which you then add to the DNS configuration for your domain. Your domain is verified when Amazon SES detects these records in the DNS configuration for your domain. This verification method is known as Easy DKIM. Alternatively, you can perform the verification process by providing your own public-private key pair. This verification method is known as Bring Your Own DKIM (BYODKIM). To use BYODKIM, your call to the CreateEmailIdentity operation has to include the DkimSigningAttributes object. When you specify this object, you provide a selector (a component of the DNS record name that identifies the public key to use for DKIM authentication) and a private key. When you verify a domain, this operation provides a set of DKIM tokens, which you can convert into CNAME tokens. You add these CNAME tokens to the DNS configuration for your domain. Your domain is verified when Amazon SES detects these records in the DNS configuration for your domain. For some DNS providers, it can take 72 hours or more to complete the domain verification process. Additionally, you can associate an existing configuration set with the email identity that you're verifying. | |
put_email_identity_dkim_signing_attributes | replace | email_identity, region, SigningAttributesOrigin | Used to configure or change the DKIM authentication settings for an email domain identity. You can use this operation to do any of the following: Update the signing attributes for an identity that uses Bring Your Own DKIM (BYODKIM). Update the key length that should be used for Easy DKIM. Change from using no DKIM authentication to using Easy DKIM. Change from using no DKIM authentication to using BYODKIM. Change from using Easy DKIM to using BYODKIM. Change from using BYODKIM to using Easy DKIM. | |
put_email_identity_configuration_set_attributes | replace | email_identity, region | Used to associate a configuration set with an email identity. | |
delete_email_identity | delete | email_identity, region | Deletes an email identity. An identity can be either an email address or a domain name. | |
put_email_identity_dkim_attributes | exec | email_identity, region | Used to enable or disable DKIM authentication for an email identity. | |
put_email_identity_feedback_attributes | exec | email_identity, region | Used to enable or disable feedback forwarding for an identity. This setting determines what happens when an identity is used to send an email that results in a bounce or complaint event. If the value is true, you receive email notifications when bounce or complaint events occur. These notifications are sent to the address that you specified in the Return-Path header of the original email. You're required to have a method of tracking bounces and complaints. If you haven't set up another mechanism for receiving bounce or complaint notifications (for example, by setting up an event destination), you receive an email notification when these events occur (even if this setting is disabled). | |
put_email_identity_mail_from_attributes | exec | email_identity, region | Used to enable or disable the custom Mail-From domain configuration for an email identity. |
Parameters
Parameters can be passed in the WHERE clause of a query. Check the Methods section to see which parameters are required or optional for each operation.
| Name | Datatype | Description |
|---|---|---|
email_identity | string | The verified email identity. |
region | string | AWS region (default: us-east-1) |
NextToken | string | A token returned from a previous call to ListEmailIdentities to indicate the position in the list of identities. |
PageSize | integer | The number of results to show in a single call to ListEmailIdentities. If the number of results is larger than the number you specified in this parameter, then the response includes a NextToken element, which you can use to obtain additional results. The value you specify has to be at least 0, and can be no more than 1000. |
SELECT examples
- get_email_identity
- list_email_identities
Provides information about a specific identity, including the identity's verification status, sending authorization policies, its DKIM authentication status, and its custom Mail-From settings.
SELECT
configuration_set_name,
dkim_attributes,
feedback_forwarding_status,
identity_type,
mail_from_attributes,
policies,
tags,
verification_info,
verification_status,
verified_for_sending_status
FROM aws.sesv2.email_identities
WHERE email_identity = '{{ email_identity }}' -- required
AND region = '{{ region }}' -- required
;
Returns a list of all of the email identities that are associated with your Amazon Web Services account. An identity can be either an email address or a domain. This operation returns identities that are verified as well as those that aren't. This operation returns identities that are associated with Amazon SES and Amazon Pinpoint.
SELECT
email_identities,
next_token
FROM aws.sesv2.email_identities
WHERE region = '{{ region }}' -- required
AND NextToken = '{{ NextToken }}'
AND PageSize = '{{ PageSize }}'
;
INSERT examples
- create_email_identity
- Manifest
Starts the process of verifying an email identity. An identity is an email address or domain that you use when you send email. Before you can use an identity to send email, you first have to verify it. By verifying an identity, you demonstrate that you're the owner of the identity, and that you've given Amazon SES API v2 permission to send email from the identity. When you verify an email address, Amazon SES sends an email to the address. Your email address is verified as soon as you follow the link in the verification email. When you verify a domain without specifying the DkimSigningAttributes object, this operation provides a set of DKIM tokens. You can convert these tokens into CNAME records, which you then add to the DNS configuration for your domain. Your domain is verified when Amazon SES detects these records in the DNS configuration for your domain. This verification method is known as Easy DKIM. Alternatively, you can perform the verification process by providing your own public-private key pair. This verification method is known as Bring Your Own DKIM (BYODKIM). To use BYODKIM, your call to the CreateEmailIdentity operation has to include the DkimSigningAttributes object. When you specify this object, you provide a selector (a component of the DNS record name that identifies the public key to use for DKIM authentication) and a private key. When you verify a domain, this operation provides a set of DKIM tokens, which you can convert into CNAME tokens. You add these CNAME tokens to the DNS configuration for your domain. Your domain is verified when Amazon SES detects these records in the DNS configuration for your domain. For some DNS providers, it can take 72 hours or more to complete the domain verification process. Additionally, you can associate an existing configuration set with the email identity that you're verifying.
INSERT INTO aws.sesv2.email_identities (
EmailIdentity,
Tags,
DkimSigningAttributes,
ConfigurationSetName,
region
)
SELECT
'{{ EmailIdentity }}' /* required */,
'{{ Tags }}',
'{{ DkimSigningAttributes }}',
'{{ ConfigurationSetName }}',
'{{ region }}'
RETURNING
dkim_attributes,
identity_type,
verified_for_sending_status
;
# Description fields are for documentation purposes
- name: email_identities
props:
- name: region
value: "{{ region }}"
description: Required parameter for the email_identities resource.
- name: EmailIdentity
value: "{{ EmailIdentity }}"
- name: Tags
value:
- Key: "{{ Key }}"
Value: "{{ Value }}"
- name: DkimSigningAttributes
description: |
An object that contains configuration for Bring Your Own DKIM (BYODKIM), or, for Easy DKIM
value:
DomainSigningSelector: "{{ DomainSigningSelector }}"
DomainSigningPrivateKey: "{{ DomainSigningPrivateKey }}"
NextSigningKeyLength: "{{ NextSigningKeyLength }}"
DomainSigningAttributesOrigin: "{{ DomainSigningAttributesOrigin }}"
- name: ConfigurationSetName
value: "{{ ConfigurationSetName }}"
description: |
The name of a configuration set. Configuration sets are groups of rules that you can apply to the emails you send. You apply a configuration set to an email by including a reference to the configuration set in the headers of the email. When you apply a configuration set to an email, all of the rules in that configuration set are applied to the email.
REPLACE examples
- put_email_identity_dkim_signing_attributes
- put_email_identity_configuration_set_attributes
Used to configure or change the DKIM authentication settings for an email domain identity. You can use this operation to do any of the following: Update the signing attributes for an identity that uses Bring Your Own DKIM (BYODKIM). Update the key length that should be used for Easy DKIM. Change from using no DKIM authentication to using Easy DKIM. Change from using no DKIM authentication to using BYODKIM. Change from using Easy DKIM to using BYODKIM. Change from using BYODKIM to using Easy DKIM.
REPLACE aws.sesv2.email_identities
SET
SigningAttributesOrigin = '{{ SigningAttributesOrigin }}',
SigningAttributes = '{{ SigningAttributes }}'
WHERE
email_identity = '{{ email_identity }}' --required
AND region = '{{ region }}' --required
AND SigningAttributesOrigin = '{{ SigningAttributesOrigin }}' --required
RETURNING
dkim_status,
dkim_tokens,
signing_hosted_zone;
Used to associate a configuration set with an email identity.
REPLACE aws.sesv2.email_identities
SET
ConfigurationSetName = '{{ ConfigurationSetName }}'
WHERE
email_identity = '{{ email_identity }}' --required
AND region = '{{ region }}' --required;
DELETE examples
- delete_email_identity
Deletes an email identity. An identity can be either an email address or a domain name.
DELETE FROM aws.sesv2.email_identities
WHERE email_identity = '{{ email_identity }}' --required
AND region = '{{ region }}' --required
;
Lifecycle Methods
- put_email_identity_dkim_attributes
- put_email_identity_feedback_attributes
- put_email_identity_mail_from_attributes
Used to enable or disable DKIM authentication for an email identity.
EXEC aws.sesv2.email_identities.put_email_identity_dkim_attributes
@email_identity='{{ email_identity }}' --required,
@region='{{ region }}' --required
@@json=
'{
"SigningEnabled": {{ SigningEnabled }}
}'
;
Used to enable or disable feedback forwarding for an identity. This setting determines what happens when an identity is used to send an email that results in a bounce or complaint event. If the value is true, you receive email notifications when bounce or complaint events occur. These notifications are sent to the address that you specified in the Return-Path header of the original email. You're required to have a method of tracking bounces and complaints. If you haven't set up another mechanism for receiving bounce or complaint notifications (for example, by setting up an event destination), you receive an email notification when these events occur (even if this setting is disabled).
EXEC aws.sesv2.email_identities.put_email_identity_feedback_attributes
@email_identity='{{ email_identity }}' --required,
@region='{{ region }}' --required
@@json=
'{
"EmailForwardingEnabled": {{ EmailForwardingEnabled }}
}'
;
Used to enable or disable the custom Mail-From domain configuration for an email identity.
EXEC aws.sesv2.email_identities.put_email_identity_mail_from_attributes
@email_identity='{{ email_identity }}' --required,
@region='{{ region }}' --required
@@json=
'{
"MailFromDomain": "{{ MailFromDomain }}",
"BehaviorOnMxFailure": "{{ BehaviorOnMxFailure }}"
}'
;