Skip to main content

tags

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

Overview

Nametags
TypeResource
Idaws.wellarchitected.tags

Fields

The following fields are returned by SELECT queries:

NameDatatypeDescription
tagsobjectThe tags for the resource.

Methods

The following methods are available for this resource:

NameAccessible byRequired ParamsOptional ParamsDescription
list_tags_for_resourceselectworkload_arn, regionList the tags for a resource. The WorkloadArn parameter can be a workload ARN, a custom lens ARN, a profile ARN, or review template ARN.
untag_resourceupdateworkload_arn, tagKeys, regionDeletes specified tags from a resource. The WorkloadArn parameter can be a workload ARN, a custom lens ARN, a profile ARN, or review template ARN. To specify multiple tags, use separate tagKeys parameters, for example: DELETE /tags/WorkloadArn?tagKeys=key1&tagKeys=key2
tag_resourceupdateworkload_arn, regionAdds one or more tags to the specified resource. The WorkloadArn parameter can be a workload ARN, a custom lens ARN, a profile ARN, or review template ARN.

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
regionstringAWS region (default: us-east-1)
tagKeysarrayA list of tag keys. Existing tags of the resource whose keys are members of this list are removed from the resource.
workload_arnstring

SELECT examples

List the tags for a resource. The WorkloadArn parameter can be a workload ARN, a custom lens ARN, a profile ARN, or review template ARN.

SELECT
tags
FROM aws.wellarchitected.tags
WHERE workload_arn = '{{ workload_arn }}' -- required
AND region = '{{ region }}' -- required
;

UPDATE examples

Deletes specified tags from a resource. The WorkloadArn parameter can be a workload ARN, a custom lens ARN, a profile ARN, or review template ARN. To specify multiple tags, use separate tagKeys parameters, for example: DELETE /tags/WorkloadArn?tagKeys=key1&tagKeys=key2

UPDATE aws.wellarchitected.tags
SET
-- No updatable properties
WHERE
workload_arn = '{{ workload_arn }}' --required
AND tagKeys = '{{ tagKeys }}' --required
AND region = '{{ region }}' --required;