Skip to main content

domain_units

Creates, updates, deletes or gets a domain_unit resource or lists domain_units in a region

Overview

Namedomain_units
TypeResource
DescriptionA domain unit enables you to easily organize your assets and other domain entities under specific business units and teams.
Idawscc.datazone.domain_units

Fields

NameDatatypeDescription
domain_identifierstringThe ID of the domain where you want to create a domain unit.
descriptionstringThe description of the domain unit.
namestringThe name of the domain unit.
parent_domain_unit_identifierstringThe ID of the parent domain unit.
created_atstringThe timestamp at which the domain unit was created.
domain_idstringThe ID of the domain where the domain unit was created.
idstringThe ID of the domain unit.
parent_domain_unit_idstringThe ID of the parent domain unit.
identifierstringThe identifier of the domain unit that you want to get.
last_updated_atstringThe timestamp at which the domain unit was last updated.
regionstringAWS region.

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

Methods

NameResourceAccessible byRequired Params
create_resourcedomain_unitsINSERTDomainIdentifier, Name, ParentDomainUnitIdentifier, region
delete_resourcedomain_unitsDELETEIdentifier, region
update_resourcedomain_unitsUPDATEIdentifier, PatchDocument, region
list_resourcesdomain_units_list_onlySELECTregion
get_resourcedomain_unitsSELECTIdentifier, region

SELECT examples

Gets all properties from an individual domain_unit.

SELECT
region,
domain_identifier,
description,
name,
parent_domain_unit_identifier,
created_at,
domain_id,
id,
parent_domain_unit_id,
identifier,
last_updated_at
FROM awscc.datazone.domain_units
WHERE
region = 'us-east-1' AND
Identifier = '{{ domain_id }}|{{ id }}';

INSERT example

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

/*+ create */
INSERT INTO awscc.datazone.domain_units (
DomainIdentifier,
Name,
ParentDomainUnitIdentifier,
region
)
SELECT
'{{ domain_identifier }}',
'{{ name }}',
'{{ parent_domain_unit_identifier }}',
'{{ region }}';

UPDATE example

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

/*+ update */
UPDATE awscc.datazone.domain_units
SET PatchDocument = string('{{ {
"Description": description,
"Name": name
} | generate_patch_document }}')
WHERE
region = '{{ region }}' AND
Identifier = '{{ domain_id }}|{{ id }}';

DELETE example

/*+ delete */
DELETE FROM awscc.datazone.domain_units
WHERE
Identifier = '{{ domain_id }}|{{ id }}' AND
region = 'us-east-1';

Permissions

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

datazone:CreateDomainUnit,
datazone:GetDomainUnit