Skip to main content

tags

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

Overview

Nametags
TypeResource
Idaws.lex_models.tags

Fields

The following fields are returned by SELECT queries:

NameDatatypeDescription
tagsarrayThe tags associated with a resource.

Methods

The following methods are available for this resource:

NameAccessible byRequired ParamsOptional ParamsDescription
list_tags_for_resourceselectresource_arn, regionGets a list of tags associated with the specified resource. Only bots, bot aliases, and bot channels can have tags associated with them.
tag_resourceupdateresource_arn, region, tagsAdds the specified tags to the specified resource. If a tag key already exists, the existing value is replaced with the new value.
untag_resourceupdateresource_arn, tagKeys, regionRemoves tags from a bot, bot alias or bot channel.

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 resource to remove the tags from.
tagKeysarrayA list of tag keys to remove from the resource. If a tag key does not exist on the resource, it is ignored.

SELECT examples

Gets a list of tags associated with the specified resource. Only bots, bot aliases, and bot channels can have tags associated with them.

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

UPDATE examples

Adds the specified tags to the specified resource. If a tag key already exists, the existing value is replaced with the new value.

UPDATE aws.lex_models.tags
SET
tags = '{{ tags }}'
WHERE
resource_arn = '{{ resource_arn }}' --required
AND region = '{{ region }}' --required
AND tags = '{{ tags }}' --required;