Skip to main content

tags

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

Overview​

Nametags
TypeResource
Idaws.resource_explorer_2.tags

Fields​

The following fields are returned by SELECT queries:

NameDatatypeDescription
tagsobjectThe tag key and value pairs that you want to attach to the specified view or index.

Methods​

The following methods are available for this resource:

NameAccessible byRequired ParamsOptional ParamsDescription
list_tags_for_resourceselectresource_arn, regionLists the tags that are attached to the specified resource.
untag_resourceupdateresource_arn, tagKeys, regionRemoves one or more tag key and value pairs from an Amazon Web Services Resource Explorer view or index.
tag_resourceupdateresource_arn, regionAdds one or more tag key and value pairs to an Amazon Web Services Resource Explorer view or index.

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)
resource_arnstringThe Amazon Resource Name (ARN) of the view or index that you want to attach tags to.
tagKeysarrayA list of the keys for the tags that you want to remove from the specified view or index.

SELECT examples​

Lists the tags that are attached to the specified resource.

SELECT
tags
FROM aws.resource_explorer_2.tags
WHERE resource_arn = '{{ resource_arn }}' -- required
AND region = '{{ region }}' -- required
;

UPDATE examples​

Removes one or more tag key and value pairs from an Amazon Web Services Resource Explorer view or index.

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