Skip to main content

subscription_targets

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

Overview

Namesubscription_targets
TypeResource
Idaws.datazone.subscription_targets

Fields

The following fields are returned by SELECT queries:

NameDatatypeDescription
idstringThe ID of the subscription target. (pattern: <code>[a-zA-Z0-9_-]{1,36}</code>)
namestringThe name of the subscription target.
applicable_asset_typesarrayThe asset types associated with the subscription target.
authorized_principalsarrayThe authorized principals of the subscription target.
created_atstring (date-time)The timestamp of when the subscription target was created.
created_bystringThe Amazon DataZone user who created the subscription target.
domain_idstringThe ID of the Amazon DataZone domain in which the subscription target exists. (pattern: <code>dzd[-][a-zA-Z0-9-]{1,36}</code>)
environment_idstringThe ID of the environment associated with the subscription target. (pattern: <code>[a-zA-Z0-9_-]{1,36}</code>)
manage_access_rolestringThe manage access role with which the subscription target was created. (pattern: <code>arn:aws(|-cn|-us-gov):iam::\d{12}:(role|role/service-role)/[\w+=,.@-]*</code>)
project_idstringThe ID of the project associated with the subscription target. (pattern: <code>[a-zA-Z0-9_-]{1,36}</code>)
providerstringThe provider of the subscription target.
subscription_grant_creation_modestringDetermines the subscription grant creation mode for this target, defining if grants are auto-created upon subscription approval or managed manually. (AUTOMATIC, MANUAL)
subscription_target_configarrayThe configuration of teh subscription target.
type_stringThe type of the subscription target.
updated_atstring (date-time)The timestamp of when the subscription target was updated.
updated_bystringThe Amazon DataZone user who updated the subscription target.

Methods

The following methods are available for this resource:

NameAccessible byRequired ParamsOptional ParamsDescription
get_subscription_targetselectdomain_identifier, environment_identifier, identifier, regionGets the subscription target in Amazon DataZone.
list_subscription_targetsselectdomain_identifier, environment_identifier, regionsortBy, sortOrder, maxResults, nextTokenLists subscription targets in Amazon DataZone.
create_subscription_targetinsertdomain_identifier, environment_identifier, region, name, type, subscriptionTargetConfig, authorizedPrincipals, manageAccessRole, applicableAssetTypesCreates a subscription target in Amazon DataZone.
update_subscription_targetupdatedomain_identifier, environment_identifier, identifier, regionUpdates the specified subscription target in Amazon DataZone.
delete_subscription_targetdeletedomain_identifier, environment_identifier, identifier, regionDeletes a subscription target in Amazon DataZone.

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
domain_identifierstringThe ID of the Amazon DataZone domain in which the subscription target is deleted.
environment_identifierstringThe ID of the Amazon DataZone environment in which the subscription target is deleted.
identifierstringThe ID of the subscription target that is deleted.
regionstringAWS region (default: us-east-1)
maxResultsintegerThe maximum number of subscription targets to return in a single call to ListSubscriptionTargets. When the number of subscription targets to be listed is greater than the value of MaxResults, the response contains a NextToken value that you can use in a subsequent call to ListSubscriptionTargets to list the next set of subscription targets.
nextTokenstringWhen the number of subscription targets is greater than the default value for the MaxResults parameter, or if you explicitly specify a value for MaxResults that is less than the number of subscription targets, the response includes a pagination token named NextToken. You can specify this NextToken value in a subsequent call to ListSubscriptionTargets to list the next set of subscription targets.
sortBystringSpecifies the way in which the results of this action are to be sorted.
sortOrderstringSpecifies the sort order for the results of this action.

SELECT examples

Gets the subscription target in Amazon DataZone.

SELECT
id,
name,
applicable_asset_types,
authorized_principals,
created_at,
created_by,
domain_id,
environment_id,
manage_access_role,
project_id,
provider,
subscription_grant_creation_mode,
subscription_target_config,
type_,
updated_at,
updated_by
FROM aws.datazone.subscription_targets
WHERE domain_identifier = '{{ domain_identifier }}' -- required
AND environment_identifier = '{{ environment_identifier }}' -- required
AND identifier = '{{ identifier }}' -- required
AND region = '{{ region }}' -- required
;

INSERT examples

Creates a subscription target in Amazon DataZone.

INSERT INTO aws.datazone.subscription_targets (
name,
type,
subscriptionTargetConfig,
authorizedPrincipals,
manageAccessRole,
applicableAssetTypes,
provider,
clientToken,
subscriptionGrantCreationMode,
domain_identifier,
environment_identifier,
region
)
SELECT
'{{ name }}' /* required */,
'{{ type }}' /* required */,
'{{ subscriptionTargetConfig }}' /* required */,
'{{ authorizedPrincipals }}' /* required */,
'{{ manageAccessRole }}' /* required */,
'{{ applicableAssetTypes }}' /* required */,
'{{ provider }}',
'{{ clientToken }}',
'{{ subscriptionGrantCreationMode }}',
'{{ domain_identifier }}',
'{{ environment_identifier }}',
'{{ region }}'
RETURNING
id,
name,
applicable_asset_types,
authorized_principals,
created_at,
created_by,
domain_id,
environment_id,
manage_access_role,
project_id,
provider,
subscription_grant_creation_mode,
subscription_target_config,
type_,
updated_at,
updated_by
;

UPDATE examples

Updates the specified subscription target in Amazon DataZone.

UPDATE aws.datazone.subscription_targets
SET
name = '{{ name }}',
authorizedPrincipals = '{{ authorizedPrincipals }}',
applicableAssetTypes = '{{ applicableAssetTypes }}',
subscriptionTargetConfig = '{{ subscriptionTargetConfig }}',
manageAccessRole = '{{ manageAccessRole }}',
provider = '{{ provider }}',
subscriptionGrantCreationMode = '{{ subscriptionGrantCreationMode }}'
WHERE
domain_identifier = '{{ domain_identifier }}' --required
AND environment_identifier = '{{ environment_identifier }}' --required
AND identifier = '{{ identifier }}' --required
AND region = '{{ region }}' --required
RETURNING
id,
name,
applicable_asset_types,
authorized_principals,
created_at,
created_by,
domain_id,
environment_id,
manage_access_role,
project_id,
provider,
subscription_grant_creation_mode,
subscription_target_config,
type_,
updated_at,
updated_by;

DELETE examples

Deletes a subscription target in Amazon DataZone.

DELETE FROM aws.datazone.subscription_targets
WHERE domain_identifier = '{{ domain_identifier }}' --required
AND environment_identifier = '{{ environment_identifier }}' --required
AND identifier = '{{ identifier }}' --required
AND region = '{{ region }}' --required
;