Skip to main content

Add Tag to Application

Endpoint: PUT /api/applications/{id}/tags

Adds tags to an application. You can add a single tag or multiple tags in one request. If a tag with the same key already exists, this operation will update its value.

Path parameters

ParameterDescriptionTypeRequired/ Optional
idThe unique identifier of the application to which the tags are to be added.stringRequired.

Request body

ParameterDescriptionTypeRequired/ Optional
keyThe tag key.stringRequired.
valueThe tag value.stringRequired.

Example for adding multiple tags in a single request:

[
{
"key": "dev",
"value": "automation"
},
{
"key": "backend",
"value": "PR"
}
]

Response

Returns 200 OK, indicating that tags have been added to the application.

Examples

Add a single tag to an application

Request

curl -X 'PUT' \
'https://<YOUR-SERVER-URL>/api/applications/bcd1886f-3e98-4f28-ba49-1174f6482f15/tags' \
-H 'accept: */*' \
-H 'X-Authorization: <TOKEN>' \
-H 'Content-Type: application/json' \
-d '[
{
"key": "someKey",
"value": "someValue"
}
]'

Response

Returns 200 OK, indicating that the tag has been added to the application.

Add multiple tags to an application

Request

curl -X 'PUT' \
'https://<YOUR-SERVER-URL>/api/applications/bcd1886f-3e98-4f28-ba49-1174f6482f15/tags' \
-H 'accept: */*' \
-H 'X-Authorization: <TOKEN>' \
-H 'Content-Type: application/json' \
-d '[
{
"key": "dev",
"value": "automation"
},
{
"key": "backend",
"value": "PR"
}
]'

Response

Returns 200 OK, indicating that tags have been added to the application.