Skip to main content

tags

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

Overview

Nametags
TypeResource
Idaws.s3tables.tags

Fields

The following fields are returned by SELECT queries:

NameDatatypeDescription
tagsobjectThe user-defined tags that are applied to the resource. For more information, see Tagging for cost allocation or attribute-based access control (ABAC).

Methods

The following methods are available for this resource:

NameAccessible byRequired ParamsOptional ParamsDescription
list_tags_for_resourceselectresource_arn, regionLists all of the tags applied to a specified Amazon S3 Tables resource. Each tag is a label consisting of a key and value pair. Tags can help you organize, track costs for, and control access to resources. For a list of S3 resources that support tagging, see Managing tags for Amazon S3 resources. Permissions For tables and table buckets, you must have the s3tables:ListTagsForResource permission to use this operation.
tag_resourceupdateresource_arn, region, tagsApplies one or more user-defined tags to an Amazon S3 Tables resource or updates existing tags. Each tag is a label consisting of a key and value pair. Tags can help you organize, track costs for, and control access to your resources. You can add up to 50 tags for each S3 resource. For a list of S3 resources that support tagging, see Managing tags for Amazon S3 resources. Permissions For tables and table buckets, you must have the s3tables:TagResource permission to use this operation.
untag_resourceupdateresource_arn, tagKeys, regionRemoves the specified user-defined tags from an Amazon S3 Tables resource. You can pass one or more tag keys. For a list of S3 resources that support tagging, see Managing tags for Amazon S3 resources. Permissions For tables and table buckets, you must have the s3tables:UntagResource permission to use this operation.

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 Amazon S3 Tables resource that you're removing tags from. The tagged resource can be a table bucket or a table. For a list of all S3 resources that support tagging, see Managing tags for Amazon S3 resources.
tagKeysarrayThe array of tag keys that you're removing from the S3 Tables resource. For more information, see Tagging for cost allocation or attribute-based access control (ABAC).

SELECT examples

Lists all of the tags applied to a specified Amazon S3 Tables resource. Each tag is a label consisting of a key and value pair. Tags can help you organize, track costs for, and control access to resources. For a list of S3 resources that support tagging, see Managing tags for Amazon S3 resources. Permissions For tables and table buckets, you must have the s3tables:ListTagsForResource permission to use this operation.

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

UPDATE examples

Applies one or more user-defined tags to an Amazon S3 Tables resource or updates existing tags. Each tag is a label consisting of a key and value pair. Tags can help you organize, track costs for, and control access to your resources. You can add up to 50 tags for each S3 resource. For a list of S3 resources that support tagging, see Managing tags for Amazon S3 resources. Permissions For tables and table buckets, you must have the s3tables:TagResource permission to use this operation.

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