protect_configurations
Creates, updates, deletes, gets or lists a protect_configurations resource.
Overview
| Name | protect_configurations |
| Type | Resource |
| Id | aws.pinpoint_sms_voice_v2.protect_configurations |
Fields
The following fields are returned by SELECT queries:
- describe_protect_configurations
| Name | Datatype | Description |
|---|---|---|
account_default | boolean | This is true if the protect configuration is set as your account default protect configuration. |
created_timestamp | string (date-time) | The time when the protect configuration was created, in UNIX epoch time format. |
deletion_protection_enabled | boolean | The status of deletion protection for the protect configuration. When set to true deletion protection is enabled. By default this is set to false. |
protect_configuration_arn | string | The Amazon Resource Name (ARN) of the protect configuration. (pattern: <code>arn:\S+</code>) |
protect_configuration_id | string | The unique identifier for the protect configuration. (pattern: <code>[A-Za-z0-9_-]+</code>) |
Methods
The following methods are available for this resource:
| Name | Accessible by | Required Params | Optional Params | Description |
|---|---|---|---|---|
describe_protect_configurations | select | region | Retrieves the protect configurations that match any of filters. If a filter isn’t provided then all protect configurations are returned. | |
create_protect_configuration | insert | region | Create a new protect configuration. By default all country rule sets for each capability are set to ALLOW. Update the country rule sets using UpdateProtectConfigurationCountryRuleSet. A protect configurations name is stored as a Tag with the key set to Name and value as the name of the protect configuration. | |
associate_protect_configuration | update | region, ProtectConfigurationId, ConfigurationSetName | Associate a protect configuration with a configuration set. This replaces the configuration sets current protect configuration. A configuration set can only be associated with one protect configuration at a time. A protect configuration can be associated with multiple configuration sets. | |
update_protect_configuration | update | region, ProtectConfigurationId | Update the setting for an existing protect configuration. | |
delete_protect_configuration | delete | region | Permanently delete the protect configuration. The protect configuration must have deletion protection disabled and must not be associated as the account default protect configuration or associated with a configuration set. | |
delete_account_default_protect_configuration | delete | region | Removes the current account default protect configuration. | |
disassociate_protect_configuration | exec | region, ProtectConfigurationId, ConfigurationSetName | Disassociate a protect configuration from a configuration set. | |
set_account_default_protect_configuration | exec | region, ProtectConfigurationId | Set a protect configuration as your account default. You can only have one account default protect configuration at a time. The current account default protect configuration is replaced with the provided protect configuration. |
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 |
|---|---|---|
region | string | AWS region (default: us-east-1) |
SELECT examples
- describe_protect_configurations
Retrieves the protect configurations that match any of filters. If a filter isn’t provided then all protect configurations are returned.
SELECT
account_default,
created_timestamp,
deletion_protection_enabled,
protect_configuration_arn,
protect_configuration_id
FROM aws.pinpoint_sms_voice_v2.protect_configurations
WHERE region = '{{ region }}' -- required
;
INSERT examples
- create_protect_configuration
- Manifest
Create a new protect configuration. By default all country rule sets for each capability are set to ALLOW. Update the country rule sets using UpdateProtectConfigurationCountryRuleSet. A protect configurations name is stored as a Tag with the key set to Name and value as the name of the protect configuration.
INSERT INTO aws.pinpoint_sms_voice_v2.protect_configurations (
ClientToken,
DeletionProtectionEnabled,
Tags,
region
)
SELECT
'{{ ClientToken }}',
{{ DeletionProtectionEnabled }},
'{{ Tags }}',
'{{ region }}'
RETURNING
account_default,
created_timestamp,
deletion_protection_enabled,
protect_configuration_arn,
protect_configuration_id,
tags
;
# Description fields are for documentation purposes
- name: protect_configurations
props:
- name: region
value: "{{ region }}"
description: Required parameter for the protect_configurations resource.
- name: ClientToken
value: "{{ ClientToken }}"
description: |
Unique, case-sensitive identifier that you provide to ensure the idempotency of the request. If you don't specify a client token, a randomly generated token is used for the request to ensure idempotency.
- name: DeletionProtectionEnabled
value: {{ DeletionProtectionEnabled }}
description: |
When set to true deletion protection is enabled. By default this is set to false.
- name: Tags
description: |
An array of key and value pair tags that are associated with the resource.
value:
- Key: "{{ Key }}"
Value: "{{ Value }}"
UPDATE examples
- associate_protect_configuration
- update_protect_configuration
Associate a protect configuration with a configuration set. This replaces the configuration sets current protect configuration. A configuration set can only be associated with one protect configuration at a time. A protect configuration can be associated with multiple configuration sets.
UPDATE aws.pinpoint_sms_voice_v2.protect_configurations
SET
ProtectConfigurationId = '{{ ProtectConfigurationId }}',
ConfigurationSetName = '{{ ConfigurationSetName }}'
WHERE
region = '{{ region }}' --required
AND ProtectConfigurationId = '{{ ProtectConfigurationId }}' --required
AND ConfigurationSetName = '{{ ConfigurationSetName }}' --required
RETURNING
configuration_set_arn,
configuration_set_name,
protect_configuration_arn,
protect_configuration_id;
Update the setting for an existing protect configuration.
UPDATE aws.pinpoint_sms_voice_v2.protect_configurations
SET
ProtectConfigurationId = '{{ ProtectConfigurationId }}',
DeletionProtectionEnabled = {{ DeletionProtectionEnabled }}
WHERE
region = '{{ region }}' --required
AND ProtectConfigurationId = '{{ ProtectConfigurationId }}' --required
RETURNING
account_default,
created_timestamp,
deletion_protection_enabled,
protect_configuration_arn,
protect_configuration_id;
DELETE examples
- delete_protect_configuration
- delete_account_default_protect_configuration
Permanently delete the protect configuration. The protect configuration must have deletion protection disabled and must not be associated as the account default protect configuration or associated with a configuration set.
DELETE FROM aws.pinpoint_sms_voice_v2.protect_configurations
WHERE region = '{{ region }}' --required
;
Removes the current account default protect configuration.
DELETE FROM aws.pinpoint_sms_voice_v2.protect_configurations
WHERE region = '{{ region }}' --required
;
Lifecycle Methods
- disassociate_protect_configuration
- set_account_default_protect_configuration
Disassociate a protect configuration from a configuration set.
EXEC aws.pinpoint_sms_voice_v2.protect_configurations.disassociate_protect_configuration
@region='{{ region }}' --required
@@json=
'{
"ProtectConfigurationId": "{{ ProtectConfigurationId }}",
"ConfigurationSetName": "{{ ConfigurationSetName }}"
}'
;
Set a protect configuration as your account default. You can only have one account default protect configuration at a time. The current account default protect configuration is replaced with the provided protect configuration.
EXEC aws.pinpoint_sms_voice_v2.protect_configurations.set_account_default_protect_configuration
@region='{{ region }}' --required
@@json=
'{
"ProtectConfigurationId": "{{ ProtectConfigurationId }}"
}'
;