Create a collection qualifier

Last update: 2024-01-18
  • Created for:
  • Experienced
    Developer

You can create a collection qualifier (previously known as “tag”) by making a POST request to the Offer Library API.

Accept and Content-Type headers

The following table shows the valid values which comprise the Content-Type fields in the request header:

Header name Value
Content-Type application/json

API format

POST /{ENDPOINT_PATH}/tags
Parameter Description Example
{ENDPOINT_PATH} The endpoint path for persistence APIs. https://platform.adobe.io/data/core/dps/

Request

curl -X POST 'https://platform.adobe.io/data/core/dps/tags' \
-H 'Content-Type: application/json' \
-H 'Authorization: Bearer {ACCESS_TOKEN}' \
-H 'x-api-key: {API_KEY}' \
-H 'x-gw-ims-org-id: {IMS_ORG}' \
-H 'x-sandbox-name: {SANDBOX_NAME}' \
-d '{
    "name": "Black Friday",
    "description": "Tag for black friday"
}'

Response

A successful response returns information on the newly created collection qualifier, including its unique id. You can use the id in later steps to update or delete your collection qualifier. You can use your unique collection qualifier id in later tutorials to create collections and personalized offers.

{
    "id": "{ID}",
    "sandboxId": "{SANDBOX_ID}",
    "etag": 1,
    "createdDate": "2023-09-07T12:36:26.602Z",
    "lastModifiedDate": "2023-09-07T12:36:26.602Z",
    "createdBy": "{CREATED_BY}",
    "lastModifiedBy": "{MODIFIED_BY}",
    "createdByClientId": "{CREATED_CLIENT_ID}",
    "lastModifiedByClientId": "{MODIFIED_CLIENT_ID}"
}

On this page