Assigning Tags
Last updated: 20 January 2025
The api/subscribers/tags/set method is used to request the assignment of a tag to an existing recipient.
info
To assign a tag to a recipient, its unique identifier is required, specified in the EXT_USER_ID parameter at creation.
Calling the api/subscribers/tags/set method
To call the api/subscribers/tags/set method, send a POST request to the URL https://app.edna.io/api/subscribers/tags/set
If the request is successful, the method returns a response with the 200 code.
Request Body Format
{
"tag": {
"name": "best_user"
},
"subscribers": [
{
"address": "test12345",
"type": "EXT_USER_ID"
}
]
}
Request Parameters
| Parameter | Data type | Description |
|---|---|---|
tag | object | The tag object. |
tag.name | string | The name of the recipient's tag. |
subscribers | array of strings | An array of recipient IDs. |
subscribers.address | string | The unique identifier of the recipient specified as the value of the EXT_USER_ID parameter when creating the recipient. |
subscribers.type | string | The ID type. The value is EXT_USER_ID. |
Response Example
[
{
"id": 66402870,
"blacklisted": false,
"addresses": [
{
"id": "09c2dc23-715e-4cde-8034-8ddfac6d91b5",
"address": "test12345"
}
],
"parameterValues": [],
"tagValues": [
{
"name": "best_user"
}
]
}
]
Errors
400 (Constraint Violation) — validation error. Possible comments:
address cannot be null or blank— The recipient's unique identifier must not be empty.must not be blank— The parameter must not be empty.size must be between 1 and 64— The number of characters in the tag name exceeds 64.