email_identity_policies
Creates, updates, deletes, gets or lists an email_identity_policies resource.
Overview
| Name | email_identity_policies |
| Type | Resource |
| Id | aws.sesv2.email_identity_policies |
Fields
The following fields are returned by SELECT queries:
- get_email_identity_policies
| Name | Datatype | Description |
|---|---|---|
policies | object | A map of policy names to policies. |
Methods
The following methods are available for this resource:
| Name | Accessible by | Required Params | Optional Params | Description |
|---|---|---|---|---|
get_email_identity_policies | select | email_identity, region | Returns the requested sending authorization policies for the given identity (an email address or a domain). The policies are returned as a map of policy names to policy contents. You can retrieve a maximum of 20 policies at a time. This API is for the identity owner only. If you have not verified the identity, this API will return an error. Sending authorization is a feature that enables an identity owner to authorize other senders to use its identities. For information about using sending authorization, see the Amazon SES Developer Guide. You can execute this operation no more than once per second. | |
create_email_identity_policy | insert | email_identity, policy_name, region, Policy | Creates the specified sending authorization policy for the given identity (an email address or a domain). This API is for the identity owner only. If you have not verified the identity, this API will return an error. Sending authorization is a feature that enables an identity owner to authorize other senders to use its identities. For information about using sending authorization, see the Amazon SES Developer Guide. You can execute this operation no more than once per second. | |
update_email_identity_policy | update | email_identity, policy_name, region, Policy | Updates the specified sending authorization policy for the given identity (an email address or a domain). This API returns successfully even if a policy with the specified name does not exist. This API is for the identity owner only. If you have not verified the identity, this API will return an error. Sending authorization is a feature that enables an identity owner to authorize other senders to use its identities. For information about using sending authorization, see the Amazon SES Developer Guide. You can execute this operation no more than once per second. | |
delete_email_identity_policy | delete | email_identity, policy_name, region | Deletes the specified sending authorization policy for the given identity (an email address or a domain). This API returns successfully even if a policy with the specified name does not exist. This API is for the identity owner only. If you have not verified the identity, this API will return an error. Sending authorization is a feature that enables an identity owner to authorize other senders to use its identities. For information about using sending authorization, see the Amazon SES Developer Guide. You can execute this operation no more than once per second. |
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 email identity. |
policy_name | string | The name of the policy. The policy name cannot exceed 64 characters and can only include alphanumeric characters, dashes, and underscores. |
region | string | AWS region (default: us-east-1) |
SELECT examples
- get_email_identity_policies
Returns the requested sending authorization policies for the given identity (an email address or a domain). The policies are returned as a map of policy names to policy contents. You can retrieve a maximum of 20 policies at a time. This API is for the identity owner only. If you have not verified the identity, this API will return an error. Sending authorization is a feature that enables an identity owner to authorize other senders to use its identities. For information about using sending authorization, see the Amazon SES Developer Guide. You can execute this operation no more than once per second.
SELECT
policies
FROM aws.sesv2.email_identity_policies
WHERE email_identity = '{{ email_identity }}' -- required
AND region = '{{ region }}' -- required
;
INSERT examples
- create_email_identity_policy
- Manifest
Creates the specified sending authorization policy for the given identity (an email address or a domain). This API is for the identity owner only. If you have not verified the identity, this API will return an error. Sending authorization is a feature that enables an identity owner to authorize other senders to use its identities. For information about using sending authorization, see the Amazon SES Developer Guide. You can execute this operation no more than once per second.
INSERT INTO aws.sesv2.email_identity_policies (
Policy,
email_identity,
policy_name,
region
)
SELECT
'{{ Policy }}' /* required */,
'{{ email_identity }}',
'{{ policy_name }}',
'{{ region }}'
;
# Description fields are for documentation purposes
- name: email_identity_policies
props:
- name: email_identity
value: "{{ email_identity }}"
description: Required parameter for the email_identity_policies resource.
- name: policy_name
value: "{{ policy_name }}"
description: Required parameter for the email_identity_policies resource.
- name: region
value: "{{ region }}"
description: Required parameter for the email_identity_policies resource.
- name: Policy
value: "{{ Policy }}"
description: |
The text of the policy in JSON format. The policy cannot exceed 4 KB. For information about the syntax of sending authorization policies, see the Amazon SES Developer Guide.
UPDATE examples
- update_email_identity_policy
Updates the specified sending authorization policy for the given identity (an email address or a domain). This API returns successfully even if a policy with the specified name does not exist. This API is for the identity owner only. If you have not verified the identity, this API will return an error. Sending authorization is a feature that enables an identity owner to authorize other senders to use its identities. For information about using sending authorization, see the Amazon SES Developer Guide. You can execute this operation no more than once per second.
UPDATE aws.sesv2.email_identity_policies
SET
Policy = '{{ Policy }}'
WHERE
email_identity = '{{ email_identity }}' --required
AND policy_name = '{{ policy_name }}' --required
AND region = '{{ region }}' --required
AND Policy = '{{ Policy }}' --required;
DELETE examples
- delete_email_identity_policy
Deletes the specified sending authorization policy for the given identity (an email address or a domain). This API returns successfully even if a policy with the specified name does not exist. This API is for the identity owner only. If you have not verified the identity, this API will return an error. Sending authorization is a feature that enables an identity owner to authorize other senders to use its identities. For information about using sending authorization, see the Amazon SES Developer Guide. You can execute this operation no more than once per second.
DELETE FROM aws.sesv2.email_identity_policies
WHERE email_identity = '{{ email_identity }}' --required
AND policy_name = '{{ policy_name }}' --required
AND region = '{{ region }}' --required
;