Delete AWS resource tags from a configuration
You remove tags from a configuration with the UntagResource operation,
passing the configuration's ARN and the tag keys to remove. You can also remove tags by
setting the tags parameter with PutStorageLensConfiguration to a tag
set that omits the entries you want to remove, because that parameter replaces the entire tag
set. You can delete resource tags by using the Amazon S3 console, the AWS CLI, or the AWS
SDKs.
In the Amazon S3 console, you remove a configuration's tags in the General step of the edit wizard.
To remove tags from a configuration
Sign in to the AWS Management Console and open the Amazon S3 console at https://console.aws.amazon.com/s3/
. -
In the left navigation pane, choose Storage Lens, and then choose the Table buckets tab.
-
Choose the dashboard, and then choose Edit.
-
In the General step, under Tags - optional, remove the tags that you no longer want.
-
Proceed through the remaining steps, and then on the Review and create step, choose Submit.
Example
The following example command removes tags by key from an Amazon S3 Storage Lens for
Tables configuration. To use this example, replace the with your own information.user input
placeholders
aws s3tables untag-resource --resource-arn=arn:aws:s3tables:us-east-1:222222222222:storage-lens/your-configuration-id--tag-keysprojectdepartment
The following example removes tags by key from an Amazon S3 Storage Lens for Tables
configuration in SDK for Java. To use this example, replace the with your own information.user input
placeholders
Example– Delete tags from an Amazon S3 Storage Lens for Tables configuration
import software.amazon.awssdk.regions.Region; import software.amazon.awssdk.services.s3tables.S3TablesClient; import software.amazon.awssdk.services.s3tables.model.UntagResourceRequest; import java.util.List; public class DeleteStorageLensTags { public static void main(String[] args) { String resourceArn = "arn:aws:s3tables:us-east-1:111122223333:storage-lens/your-configuration-id"; try (S3TablesClient s3TablesClient = S3TablesClient.builder() .region(Region.US_EAST_1) .build()) { s3TablesClient.untagResource(UntagResourceRequest.builder() .resourceArn(resourceArn) .tagKeys(List.of("key-1", "key-2")) .build()); } } }