Skip to main content

protect_configurations

Creates, updates, deletes, gets or lists a protect_configurations resource.

Overview

Nameprotect_configurations
TypeResource
Idaws.pinpoint_sms_voice_v2.protect_configurations

Fields

The following fields are returned by SELECT queries:

NameDatatypeDescription
account_defaultbooleanThis is true if the protect configuration is set as your account default protect configuration.
created_timestampstring (date-time)The time when the protect configuration was created, in UNIX epoch time format.
deletion_protection_enabledbooleanThe 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_arnstringThe Amazon Resource Name (ARN) of the protect configuration. (pattern: <code>arn:\S+</code>)
protect_configuration_idstringThe unique identifier for the protect configuration. (pattern: <code>[A-Za-z0-9_-]+</code>)

Methods

The following methods are available for this resource:

NameAccessible byRequired ParamsOptional ParamsDescription
describe_protect_configurationsselectregionRetrieves the protect configurations that match any of filters. If a filter isn’t provided then all protect configurations are returned.
create_protect_configurationinsertregionCreate 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_configurationupdateregion, ProtectConfigurationId, ConfigurationSetNameAssociate 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_configurationupdateregion, ProtectConfigurationIdUpdate the setting for an existing protect configuration.
delete_protect_configurationdeleteregionPermanently 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_configurationdeleteregionRemoves the current account default protect configuration.
disassociate_protect_configurationexecregion, ProtectConfigurationId, ConfigurationSetNameDisassociate a protect configuration from a configuration set.
set_account_default_protect_configurationexecregion, ProtectConfigurationIdSet 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.

NameDatatypeDescription
regionstringAWS region (default: us-east-1)

SELECT examples

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 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
;

UPDATE examples

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;

DELETE examples

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
;

Lifecycle Methods

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 }}"
}'
;