subscription_targets
Creates, updates, deletes, gets or lists a subscription_targets resource.
Overview
| Name | subscription_targets |
| Type | Resource |
| Id | aws.datazone.subscription_targets |
Fields
The following fields are returned by SELECT queries:
- get_subscription_target
- list_subscription_targets
| Name | Datatype | Description |
|---|---|---|
id | string | The ID of the subscription target. (pattern: <code>[a-zA-Z0-9_-]{1,36}</code>) |
name | string | The name of the subscription target. |
applicable_asset_types | array | The asset types associated with the subscription target. |
authorized_principals | array | The authorized principals of the subscription target. |
created_at | string (date-time) | The timestamp of when the subscription target was created. |
created_by | string | The Amazon DataZone user who created the subscription target. |
domain_id | string | The ID of the Amazon DataZone domain in which the subscription target exists. (pattern: <code>dzd[-][a-zA-Z0-9-]{1,36}</code>) |
environment_id | string | The ID of the environment associated with the subscription target. (pattern: <code>[a-zA-Z0-9_-]{1,36}</code>) |
manage_access_role | string | The 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_id | string | The ID of the project associated with the subscription target. (pattern: <code>[a-zA-Z0-9_-]{1,36}</code>) |
provider | string | The provider of the subscription target. |
subscription_grant_creation_mode | string | Determines the subscription grant creation mode for this target, defining if grants are auto-created upon subscription approval or managed manually. (AUTOMATIC, MANUAL) |
subscription_target_config | array | The configuration of teh subscription target. |
type_ | string | The type of the subscription target. |
updated_at | string (date-time) | The timestamp of when the subscription target was updated. |
updated_by | string | The Amazon DataZone user who updated the subscription target. |
| Name | Datatype | Description |
|---|---|---|
id | string | The identifier of the subscription target. (pattern: <code>[a-zA-Z0-9_-]{1,36}</code>) |
name | string | The name of the subscription target. |
applicable_asset_types | array | The asset types included in the subscription target. |
authorized_principals | array | The authorized principals included in the subscription target. |
created_at | string (date-time) | The timestamp of when the subscription target was created. |
created_by | string | The Amazon DataZone user who created the subscription target. |
domain_id | string | The identifier of the Amazon DataZone domain in which the subscription target exists. (pattern: <code>dzd[-][a-zA-Z0-9-]{1,36}</code>) |
environment_id | string | The identifier of the environment of the subscription target. (pattern: <code>[a-zA-Z0-9_-]{1,36}</code>) |
manage_access_role | string | The manage access role specified in the subscription target. (pattern: <code>arn:aws(|-cn|-us-gov):iam::\d{12}:(role|role/service-role)/[\w+=,.@-]*</code>) |
project_id | string | The identifier of the project specified in the subscription target. (pattern: <code>[a-zA-Z0-9_-]{1,36}</code>) |
provider | string | The provider of the subscription target. |
subscription_grant_creation_mode | string | Determines the subscription grant creation mode for this target, defining if grants are auto-created upon subscription approval or managed manually. (AUTOMATIC, MANUAL) |
subscription_target_config | array | The configuration of the subscription target. |
type_ | string | The type of the subscription target. |
updated_at | string (date-time) | The timestamp of when the subscription target was updated. |
updated_by | string | The Amazon DataZone user who updated the subscription target. |
Methods
The following methods are available for this resource:
| Name | Accessible by | Required Params | Optional Params | Description |
|---|---|---|---|---|
get_subscription_target | select | domain_identifier, environment_identifier, identifier, region | Gets the subscription target in Amazon DataZone. | |
list_subscription_targets | select | domain_identifier, environment_identifier, region | sortBy, sortOrder, maxResults, nextToken | Lists subscription targets in Amazon DataZone. |
create_subscription_target | insert | domain_identifier, environment_identifier, region, name, type, subscriptionTargetConfig, authorizedPrincipals, manageAccessRole, applicableAssetTypes | Creates a subscription target in Amazon DataZone. | |
update_subscription_target | update | domain_identifier, environment_identifier, identifier, region | Updates the specified subscription target in Amazon DataZone. | |
delete_subscription_target | delete | domain_identifier, environment_identifier, identifier, region | Deletes 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.
| Name | Datatype | Description |
|---|---|---|
domain_identifier | string | The ID of the Amazon DataZone domain in which the subscription target is deleted. |
environment_identifier | string | The ID of the Amazon DataZone environment in which the subscription target is deleted. |
identifier | string | The ID of the subscription target that is deleted. |
region | string | AWS region (default: us-east-1) |
maxResults | integer | The 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. |
nextToken | string | When 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. |
sortBy | string | Specifies the way in which the results of this action are to be sorted. |
sortOrder | string | Specifies the sort order for the results of this action. |
SELECT examples
- get_subscription_target
- list_subscription_targets
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
;
Lists subscription targets 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 region = '{{ region }}' -- required
AND sortBy = '{{ sortBy }}'
AND sortOrder = '{{ sortOrder }}'
AND maxResults = '{{ maxResults }}'
AND nextToken = '{{ nextToken }}'
;
INSERT examples
- create_subscription_target
- Manifest
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
;
# Description fields are for documentation purposes
- name: subscription_targets
props:
- name: domain_identifier
value: "{{ domain_identifier }}"
description: Required parameter for the subscription_targets resource.
- name: environment_identifier
value: "{{ environment_identifier }}"
description: Required parameter for the subscription_targets resource.
- name: region
value: "{{ region }}"
description: Required parameter for the subscription_targets resource.
- name: name
value: "{{ name }}"
- name: type
value: "{{ type }}"
- name: subscriptionTargetConfig
value:
- formName: "{{ formName }}"
content: "{{ content }}"
- name: authorizedPrincipals
value:
- "{{ authorizedPrincipals }}"
- name: manageAccessRole
value: "{{ manageAccessRole }}"
- name: applicableAssetTypes
value:
- "{{ applicableAssetTypes }}"
- name: provider
value: "{{ provider }}"
- name: clientToken
value: "{{ clientToken }}"
- name: subscriptionGrantCreationMode
value: "{{ subscriptionGrantCreationMode }}"
valid_values: ['AUTOMATIC', 'MANUAL']
UPDATE examples
- update_subscription_target
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
- delete_subscription_target
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
;