Introduction
The reporting team wants to find its test settings by team and environment, even when their names differ. You will add ownership tags, spot an incorrect environment label, and repair it without changing the stored settings.
Complete the workspace, regional-resource, and CLI-query labs first. The tools and four resources are prepared in a fresh environment. Work in Terminal and observe the same tags and filtered results in AWS View above Terminal.
Certification Relevance
| Certification | Exam task | Practice |
|---|---|---|
| Cloud Practitioner (CLF-C02) | Task 3.1 | Resource tags for operational grouping and selection. |
Lab Overview

Label the Finance Export Setting
In this step, you will attach team and environment labels to the finance export parameter.
The last lab found resources by a shared name prefix. Names do not always describe their team or environment. A tag adds a separate key and value to a resource, such as owner=finance or environment=staging. These labels help you find related resources without renaming them.

List the parameters:
aws ssm describe-parameters
Read their descriptions: /labex/tagging/export-format and /labex/tagging/archive-format are finance staging settings, used for testing. The two /labex/reference/ resources belong to other teams; leave them unchanged.
Tag operations identify the kind of resource and its name. For a parameter, keep --resource-type Parameter and use its full name as --resource-id. Inspect the export setting's tags:
aws ssm list-tags-for-resource \
--resource-type Parameter \
--resource-id /labex/tagging/export-format
TagList is []: this resource has no tags yet. Add two labels. Each Key=...,Value=... supplies one tag, and a space separates them:
aws ssm add-tags-to-resource \
--resource-type Parameter \
--resource-id /labex/tagging/export-format \
--tags Key=owner,Value=finance Key=environment,Value=staging
Use the lowercase keys exactly as shown; tags are case-sensitive. A successful write normally prints nothing. Read it back:
aws ssm list-tags-for-resource \
--resource-type Parameter \
--resource-id /labex/tagging/export-format
Both labels appear. Look at AWS View above Terminal: the export is included in its finance staging selection. Its stored value remains csv.
Find Resources by Owner
In this step, you will add the archive setting's owner and find both finance resources using a tag filter.
The archive is also assigned to finance. Add its owner label without changing any other tag:
aws ssm add-tags-to-resource \
--resource-type Parameter \
--resource-id /labex/tagging/archive-format \
--tags Key=owner,Value=finance
Read the full tag list:
aws ssm list-tags-for-resource \
--resource-type Parameter \
--resource-id /labex/tagging/archive-format
You should see owner=finance and an existing environment=production tag. The description said this is a staging setting; keep that mismatch in mind for the next step.
Use the filtering pattern from the previous lab, now matching a tag. Key=tag:owner selects the owner tag and Option=Equals requires an exact value:
aws ssm describe-parameters \
--parameter-filters Key=tag:owner,Option=Equals,Values=finance \
--query 'Parameters[].Name'
Both finance names appear. HR and platform are outside this selection. Labels describe the facts you supply; the service does not determine a team's owner or environment for you.
Repair the Environment Label
In this step, you will correct the archive's mislabeled environment and restore the complete finance staging selection.
A team-only list includes both finance resources. To find its test settings, require both tags: owner=finance and environment=staging. Supply two filters, separated by a space:
aws ssm describe-parameters \
--parameter-filters Key=tag:owner,Option=Equals,Values=finance Key=tag:environment,Option=Equals,Values=staging \
--query 'Parameters[].Name'
Only the export appears. The archive exists, but its incorrect production tag excludes it from this view.

Confirm the archive's stored data before repairing the label:
aws ssm get-parameter --name /labex/tagging/archive-format
It has value json, Version 1. Its description in the inventory identifies it as a finance staging archive setting. Correct the environment tag with the same add operation: supplying an existing key replaces its value and leaves other tags alone.
aws ssm add-tags-to-resource \
--resource-type Parameter \
--resource-id /labex/tagging/archive-format \
--tags Key=environment,Value=staging
You are correcting a label to match an existing test resource, not moving a production application into staging. Read the labels back:
aws ssm list-tags-for-resource \
--resource-type Parameter \
--resource-id /labex/tagging/archive-format
Both owner and environment now match the task. Run the selection again:
aws ssm describe-parameters \
--parameter-filters Key=tag:owner,Option=Equals,Values=finance Key=tag:environment,Option=Equals,Values=staging \
--query 'Parameters[].Name'
Both finance names appear. Read the stored data again:
aws ssm get-parameter --name /labex/tagging/archive-format
Its name, ARN, json value, and Version 1 are unchanged. In AWS View, both resources now appear in finance staging, and the other teams' resources remain intact.

Summary
You added business labels and repaired a misclassified setting without rewriting its data. Next, complete a short supported challenge using the same tag skills.
For further reading, see the AWS reference on Resource tags and organization.



