Update a tag
PUT /accounts/{account_id}/alerts/{alert_id}/tags/{tag_id}
Modifies an existing tag, in order to change the label.
Parameters
account_id
(string) - Id of the accountalert_id
(number) - Id of the alerttag_id
(number) - Id of the tag
Page content
Minimal curl example
curl -ig 'https://web.mention.net/api/accounts/{account_id}/alerts/{alert_id}/tags/{tag_id}' \
-X PUT \
-H 'Authorization: Bearer YOUR_ACCESS_TOKEN' \
-H 'Content-Type: application/json' \
-H 'Accept-Version: 1.9' \
-d '{"id": , "name":"space new technos"}'
Available properties
Properties | _ | Definition | Example |
---|---|---|---|
name | *required | The new name of the tag | "space new technos" |
Request example
- Headers
Authorization: Bearer YOUR_ACCESS_TOKEN
Accept-Version: 1.9
- Body
{
"name": "space new technos"
}
Response example
If the request was successful, the response will return the full tag data, just as if you did a GET request on tags of this alert.
- Body
{
"tag": { ...tag...}
}
Where tag
's value is a json object with the full tag data:
{
"id": 46468,
"name": "space innovation",
"mention_count": 0
}
Id
id
The id given to the tag. This is the unique identifier of the tag. If you change the label (name
) of the tag later, all mentions tagged with it will keep the same tags, as they are linked to the tag by its id, not its name.
Name
name
The human-readable label given to the tag.
Mention count
mention_count
The number of mentions with that tag.