Amazon Pinpoint
REST API Reference

The AWS Documentation website is getting a new look!
Try it now and let us know what you think. Switch to the new look >>

You can return to the original look by selecting English in the language selector above.

Tags

A tag is a label that you optionally define and associate with an application, campaign, or segment in Amazon Pinpoint. Tags can help you categorize and manage these types of resources in different ways, such as by purpose, owner, environment, or other criteria. An application, campaign, or segment can have as many as 50 tags.

Each tag consists of a required tag key and an associated tag value, both of which you define. A tag key is a general label that acts as a category for more specific tag values. A tag value acts as a descriptor within a tag key. For example, if you have two versions of an Amazon Pinpoint application, one for internal testing and another for external use, you might assign a Stack tag key to both applications. The value of the key might be Test for one application and Production for the other application. For more information about tags, see Tagging Amazon Pinpoint Resources in the Amazon Pinpoint Developer Guide.

You can use the Tags resource to add, retrieve, or remove tags from an application, campaign, or segment.

URI

/v1/tags/resource-arn

HTTP Methods

GET

Operation ID: ListTagsForResource

Retrieves all the tags (keys and values) that are associated with an application, campaign, or segment.

Path Parameters

Name Type Required Description
resource-arn String True

The Amazon Resource Name (ARN) of the application, campaign, or segment.

Responses

Status Code Response Model Description
200 tagsModel

The request succeeded.

POST

Operation ID: TagResource

Adds one or more tags (keys and values) to an application, campaign, or segment.

Path Parameters

Name Type Required Description
resource-arn String True

The Amazon Resource Name (ARN) of the application, campaign, or segment.

Responses

Status Code Response Model Description
204 None

The request succeeded and there's no additional content to send in the body of the response (No Content).

DELETE

Operation ID: UntagResource

Removes one or more tags (keys and values) from an application, campaign, or segment.

Path Parameters

Name Type Required Description
resource-arn String True

The Amazon Resource Name (ARN) of the application, campaign, or segment.

Query Parameters

Name Type Required Description
tagKeys String True

The key of the tag to remove from the application, campaign, or segment. To remove multiple tags, append the tagKeys parameter and argument for each additional tag to remove, separated by an ampersand (&).

Responses

Status Code Response Model Description
204 None

The request succeeded and there's no additional content to send in the body of the response (No Content).

Schemas

Request Bodies

Example POST

{ "tags": { } }

Response Bodies

Example tagsModel

{ "tags": { } }

Properties

tagsModel

Specifies the tags (keys and values) for an application, campaign, or segment.

Property Type Required Description
tags

object

True

A string-to-string map of key-value pairs that defines the tags for an application, campaign, or segment. A project, campaign, or segment can have a maximum of 50 tags.

Each tag consists of a required tag key and an associated tag value. The maximum length of a tag key is 128 characters. The maximum length of a tag value is 256 characters.

See Also

For more information about using this API in one of the language-specific AWS SDKs and references, see the following:

ListTagsForResource

TagResource

UntagResource