assets
Creates, updates, deletes, gets or lists an assets resource.
Overview
| Name | assets |
| Type | Resource |
| Id | aws.datazone.assets |
Fields
The following fields are returned by SELECT queries:
- get_asset
| Name | Datatype | Description |
|---|---|---|
id | string | The ID of the asset. (pattern: <code>[a-zA-Z0-9_-]{1,36}</code>) |
name | string | The name of the asset. |
created_at | string (date-time) | The timestamp of when the asset was created. |
created_by | string | The Amazon DataZone user who created the asset. |
description | string | The description of the Amazon DataZone asset. |
domain_id | string | The ID of the Amazon DataZone domain to which the asset belongs. (pattern: <code>dzd[-][a-zA-Z0-9-]{1,36}</code>) |
external_identifier | string | The external ID of the asset. |
first_revision_created_at | string (date-time) | The timestamp of when the first revision of the asset was created. |
first_revision_created_by | string | The Amazon DataZone user who created the first revision of the asset. |
forms_output | array | The metadata forms attached to the asset. |
glossary_terms | array | The business glossary terms attached to the asset. |
governed_glossary_terms | array | The restricted glossary terms attached to an asset. |
latest_time_series_data_point_forms_output | array | The latest data point that was imported into the time series form for the asset. |
listing | object | The listing of the asset. |
owning_project_id | string | The ID of the project that owns the asset. (pattern: <code>[a-zA-Z0-9_-]{1,36}</code>) |
read_only_forms_output | array | The read-only metadata forms attached to the asset. |
revision | string | The revision of the asset. |
type_identifier | string | The ID of the asset type. (pattern: <code>(?!.)[\w.]*\w</code>) |
type_revision | string | The revision of the asset type. |
Methods
The following methods are available for this resource:
| Name | Accessible by | Required Params | Optional Params | Description |
|---|---|---|---|---|
get_asset | select | domain_identifier, identifier, region | revision | Gets an Amazon DataZone asset. An asset is the fundamental building block in Amazon DataZone, representing any data resource that needs to be cataloged and managed. It can take many forms, from Amazon S3 buckets and database tables to dashboards and machine learning models. Each asset contains comprehensive metadata about the resource, including its location, schema, ownership, and lineage information. Assets are essential for organizing and managing data resources across an organization, making them discoverable and usable while maintaining proper governance. Before using the Amazon DataZone GetAsset command, ensure the following prerequisites are met: Domain identifier must exist and be valid Asset identifier must exist User must have the required permissions to perform the action |
create_asset | insert | domain_identifier, region, name, typeIdentifier, owningProjectIdentifier | Creates an asset in Amazon DataZone catalog. Before creating assets, make sure that the following requirements are met: --domain-identifier must refer to an existing domain. --owning-project-identifier must be a valid project within the domain. Asset type must be created beforehand using create-asset-type, or be a supported system-defined type. For more information, see create-asset-type. --type-revision (if used) must match a valid revision of the asset type. formsInput is required when it is associated as required in the asset-type. For more information, see create-form-type. Form content must include all required fields as per the form schema (e.g., bucketArn). You must invoke the following pre-requisite commands before invoking this API: CreateFormType CreateAssetType | |
delete_asset | delete | domain_identifier, identifier, region | Deletes an asset in Amazon DataZone. --domain-identifier must refer to a valid and existing domain. --identifier must refer to an existing asset in the specified domain. Asset must not be referenced in any existing asset filters. Asset must not be linked to any draft or published data product. User must have delete permissions for the domain and project. |
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 asset is deleted. |
identifier | string | The identifier of the asset that is deleted. |
region | string | AWS region (default: us-east-1) |
revision | string | The revision of the Amazon DataZone asset. |
SELECT examples
- get_asset
Gets an Amazon DataZone asset. An asset is the fundamental building block in Amazon DataZone, representing any data resource that needs to be cataloged and managed. It can take many forms, from Amazon S3 buckets and database tables to dashboards and machine learning models. Each asset contains comprehensive metadata about the resource, including its location, schema, ownership, and lineage information. Assets are essential for organizing and managing data resources across an organization, making them discoverable and usable while maintaining proper governance. Before using the Amazon DataZone GetAsset command, ensure the following prerequisites are met: Domain identifier must exist and be valid Asset identifier must exist User must have the required permissions to perform the action
SELECT
id,
name,
created_at,
created_by,
description,
domain_id,
external_identifier,
first_revision_created_at,
first_revision_created_by,
forms_output,
glossary_terms,
governed_glossary_terms,
latest_time_series_data_point_forms_output,
listing,
owning_project_id,
read_only_forms_output,
revision,
type_identifier,
type_revision
FROM aws.datazone.assets
WHERE domain_identifier = '{{ domain_identifier }}' -- required
AND identifier = '{{ identifier }}' -- required
AND region = '{{ region }}' -- required
AND revision = '{{ revision }}'
;
INSERT examples
- create_asset
- Manifest
Creates an asset in Amazon DataZone catalog. Before creating assets, make sure that the following requirements are met: --domain-identifier must refer to an existing domain. --owning-project-identifier must be a valid project within the domain. Asset type must be created beforehand using create-asset-type, or be a supported system-defined type. For more information, see create-asset-type. --type-revision (if used) must match a valid revision of the asset type. formsInput is required when it is associated as required in the asset-type. For more information, see create-form-type. Form content must include all required fields as per the form schema (e.g., bucketArn). You must invoke the following pre-requisite commands before invoking this API: CreateFormType CreateAssetType
INSERT INTO aws.datazone.assets (
name,
externalIdentifier,
typeIdentifier,
typeRevision,
description,
glossaryTerms,
formsInput,
owningProjectIdentifier,
predictionConfiguration,
clientToken,
domain_identifier,
region
)
SELECT
'{{ name }}' /* required */,
'{{ externalIdentifier }}',
'{{ typeIdentifier }}' /* required */,
'{{ typeRevision }}',
'{{ description }}',
'{{ glossaryTerms }}',
'{{ formsInput }}',
'{{ owningProjectIdentifier }}' /* required */,
'{{ predictionConfiguration }}',
'{{ clientToken }}',
'{{ domain_identifier }}',
'{{ region }}'
RETURNING
id,
name,
created_at,
created_by,
description,
domain_id,
external_identifier,
first_revision_created_at,
first_revision_created_by,
forms_output,
glossary_terms,
governed_glossary_terms,
latest_time_series_data_point_forms_output,
listing,
owning_project_id,
prediction_configuration,
read_only_forms_output,
revision,
type_identifier,
type_revision
;
# Description fields are for documentation purposes
- name: assets
props:
- name: domain_identifier
value: "{{ domain_identifier }}"
description: Required parameter for the assets resource.
- name: region
value: "{{ region }}"
description: Required parameter for the assets resource.
- name: name
value: "{{ name }}"
- name: externalIdentifier
value: "{{ externalIdentifier }}"
- name: typeIdentifier
value: "{{ typeIdentifier }}"
- name: typeRevision
value: "{{ typeRevision }}"
- name: description
value: "{{ description }}"
- name: glossaryTerms
value:
- "{{ glossaryTerms }}"
- name: formsInput
value:
- formName: "{{ formName }}"
typeIdentifier: "{{ typeIdentifier }}"
typeRevision: "{{ typeRevision }}"
content: "{{ content }}"
- name: owningProjectIdentifier
value: "{{ owningProjectIdentifier }}"
- name: predictionConfiguration
description: |
The configuration of the prediction.
value:
businessNameGeneration:
enabled: {{ enabled }}
- name: clientToken
value: "{{ clientToken }}"
DELETE examples
- delete_asset
Deletes an asset in Amazon DataZone. --domain-identifier must refer to a valid and existing domain. --identifier must refer to an existing asset in the specified domain. Asset must not be referenced in any existing asset filters. Asset must not be linked to any draft or published data product. User must have delete permissions for the domain and project.
DELETE FROM aws.datazone.assets
WHERE domain_identifier = '{{ domain_identifier }}' --required
AND identifier = '{{ identifier }}' --required
AND region = '{{ region }}' --required
;