aws ssm list-tags-for-resource
Returns a list of the tags assigned to the specified resource. AWS CLI reference
1 example 2 options Its page in the AWS CLI reference
Examples
To list the tags applied to a patch baseline
The following list-tags-for-resource example lists the tags for a patch baseline.
aws ssm list-tags-for-resource --resource-type "PatchBaseline" --resource-id "pb-0123456789abcdef0"Identify--resource-typeReturns a list of tags for a specific resource type.--resource-idThe resource ID for which you want to see a list of tags.Its output
{
"TagList": [
{
"Key": "Environment",
"Value": "Production"
},
{
"Key": "Region",
"Value": "EMEA"
}
]
}For more information, see Working with Patch Manager resources using the AWS CLI in the AWS Systems Manager User Guide.
Options
--resource-idThe resource ID for which you want to see a list of tags.--resource-typeReturns a list of tags for a specific resource type.