Skip to main content

subscription_targets

Creates, updates, deletes or gets a subscription_target resource or lists subscription_targets in a region

Overview

Namesubscription_targets
TypeResource
DescriptionSubscription targets enables one to access the data to which you have subscribed in your projects.
Idawscc.datazone.subscription_targets

Fields

NameDatatypeDescription
applicable_asset_typesarrayThe asset types that can be included in the subscription target.
authorized_principalsarrayThe authorized principals of the subscription target.
created_atstringThe 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 subscription target is created.
domain_identifierstringThe ID of the Amazon DataZone domain in which subscription target would be created.
environment_idstringThe ID of the environment in which subscription target is created.
environment_identifierstringThe ID of the environment in which subscription target would be created.
idstringThe ID of the subscription target.
manage_access_rolestringThe manage access role that is used to create the subscription target.
namestringThe name of the subscription target.
project_idstringThe identifier of the project specified in the subscription target.
providerstringThe provider of the subscription target.
subscription_target_configarrayThe configuration of the subscription target.
typestringThe type of the subscription target.
updated_atstringThe timestamp of when the subscription target was updated.
updated_bystringThe Amazon DataZone user who updated the subscription target.
regionstringAWS region.

For more information, see AWS::DataZone::SubscriptionTarget.

Methods

NameResourceAccessible byRequired Params
create_resourcesubscription_targetsINSERTApplicableAssetTypes, AuthorizedPrincipals, DomainIdentifier, EnvironmentIdentifier, Name, SubscriptionTargetConfig, Type, region
delete_resourcesubscription_targetsDELETEIdentifier, region
update_resourcesubscription_targetsUPDATEIdentifier, PatchDocument, region
list_resourcessubscription_targets_list_onlySELECTregion
get_resourcesubscription_targetsSELECTIdentifier, region

SELECT examples

Gets all properties from an individual subscription_target.

SELECT
region,
applicable_asset_types,
authorized_principals,
created_at,
created_by,
domain_id,
domain_identifier,
environment_id,
environment_identifier,
id,
manage_access_role,
name,
project_id,
provider,
subscription_target_config,
type,
updated_at,
updated_by
FROM awscc.datazone.subscription_targets
WHERE
region = '{{ region }}' AND
Identifier = '{{ domain_id }}|{{ environment_id }}|{{ id }}';

INSERT example

Use the following StackQL query and manifest file to create a new subscription_target resource, using stack-deploy.

/*+ create */
INSERT INTO awscc.datazone.subscription_targets (
ApplicableAssetTypes,
AuthorizedPrincipals,
DomainIdentifier,
EnvironmentIdentifier,
Name,
SubscriptionTargetConfig,
Type,
region
)
SELECT
'{{ applicable_asset_types }}',
'{{ authorized_principals }}',
'{{ domain_identifier }}',
'{{ environment_identifier }}',
'{{ name }}',
'{{ subscription_target_config }}',
'{{ type }}',
'{{ region }}'
RETURNING
ErrorCode,
EventTime,
Identifier,
Operation,
OperationStatus,
RequestToken,
ResourceModel,
RetryAfter,
StatusMessage,
TypeName
;

UPDATE example

Use the following StackQL query and manifest file to update a subscription_target resource, using stack-deploy.

/*+ update */
UPDATE awscc.datazone.subscription_targets
SET PatchDocument = string('{{ {
"ApplicableAssetTypes": applicable_asset_types,
"AuthorizedPrincipals": authorized_principals,
"ManageAccessRole": manage_access_role,
"Name": name,
"Provider": provider,
"SubscriptionTargetConfig": subscription_target_config
} | generate_patch_document }}')
WHERE
region = '{{ region }}' AND
Identifier = '{{ domain_id }}|{{ environment_id }}|{{ id }}'
RETURNING
ErrorCode,
EventTime,
Identifier,
Operation,
OperationStatus,
RequestToken,
ResourceModel,
RetryAfter,
StatusMessage,
TypeName
;

DELETE example

/*+ delete */
DELETE FROM awscc.datazone.subscription_targets
WHERE
Identifier = '{{ domain_id }}|{{ environment_id }}|{{ id }}' AND
region = '{{ region }}'
RETURNING
ErrorCode,
EventTime,
Identifier,
Operation,
OperationStatus,
RequestToken,
ResourceModel,
RetryAfter,
StatusMessage,
TypeName
;

Additional Parameters

Mutable resources in the Cloud Control provider support additional optional parameters which can be supplied with INSERT, UPDATE, or DELETE operations. These include:

ParameterDescription
ClientToken
A unique identifier to ensure the idempotency of the resource request.This allows the provider to accurately distinguish between retries and new requests.
A client token is valid for 36 hours once used.
After that, a resource request with the same client token is treated as a new request.
If you do not specify a client token, one is generated for inclusion in the request.
RoleArn
The ARN of the IAM role used to perform this resource operation.The role specified must have the permissions required for this operation.
If you do not specify a role, a temporary session is created using your AWS user credentials.
TypeVersionId
For private resource types, the type version to use in this resource operation.If you do not specify a resource version, the default version is used.

Permissions

To operate on the subscription_targets resource, the following permissions are required:

datazone:CreateSubscriptionTarget,
datazone:GetSubscriptionTarget,
iam:PassRole