Update a tag
/v1/tags/{tagId}Changes a tag's label, color or group. Wherever the tag is used, it shows the change at once.
Send the changes inside a tag object. A body without one fails with status
400. tagId and entityType are ignored if you send them: a tag keeps its
id and type for good, so a renamed tag keeps its old id.
Like Create a tag, it refuses a label that another tag of the same type already has. Only the fields you change are checked, so a tag saved before a rule existed can be resaved as it is.
curl -X PUT "https://api.eu.silktide.com/v1/tags/pre-production" \
-H "Authorization: silktide token=$SILKTIDE_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"tag": {
"label": "Staging",
"tagGroup": "Environment"
}
}'{
"tag": {
"tagId": "pre-production",
"entityType": "section",
"label": "Staging",
"color": "#D08736",
"tagGroup": "Environment"
}
}Request
Path parameters
tagIdstringrequired1 to 32 charactersThe tag.
Body
JSON, sent with Content-Type: application/json.
tagobjectrequiredWhat to change. Leave out what should keep its value.
tagIdandentityTypecannot change.Show 3 fieldsHide fields
labelstring1 to 127 charactersThe tag's name, as people see it.
colorstringup to 32 charactersIts color, as a hex code such as
#4256D6, or empty for none.tagGroupstringup to 64 charactersA group to show it in, such as
Region. Tags with the same group are shown together. Empty for none.
Response
200JSON.
tagobjectrequiredThe tag, as it is now.
Show 5 fieldsHide fields
tagIdstringrequired1 to 32 charactersThe tag's id. Use it in
tagIds, and in the path of Update a tag and Delete a tag.entityTypestringrequiredWhat the tag is for:
sectionfor websites and their sections,documentfor documents,taskfor tasks. Each type has its own tags.One of
sectiondocumenttasklabelstringrequiredThe tag's name, as people see it.
colorstringrequiredIts color, as a hex code such as
#ED4B4B.tagGroupstringrequiredThe group it is shown in, such as
Region. Empty when it has none.
Errors
| Status | Type | When |
|---|---|---|
| 404 | ModelNotFound | No tag with that id exists in the account. |
| 403 | AccessDenied | The API key's user cannot admin the account. |
| 400 | InvalidRequest | The body has no tag object, or a changed field is not valid: label empty, longer than 127 characters or already used by another tag of the same entityType, color not a hex code, or tagGroup longer than 64 characters. properties.field names the field. |
| 401 | NotLoggedIn | No API key was sent, or it is not a key for this region.(any operation) |
| 429 | TooManyRequests | Too many requests to this path in five seconds. Retry after the number of seconds in the Retry-After header, which properties.retryAfter repeats.(any operation) |
| 503 | - | Silktide is busy. Retry after the number of seconds in the Retry-After header.(any operation) |
Every error has the same body. See Errors.
Access
- Permission
- Can admin this account
- Plan feature
- None
- Edition
- Silktide 4 and Silktide 5
- Cost
- Free
- Available since
- v1.0.0
Try it
Sends a real request to your account from this browser. Your key stays in this tab and goes only to the Silktide API.