talonic_documents_set_tags
Replace one document's tags with exactly the given list; an empty list clears them. Tags can control who sees a document: call only when the user asked. To add a tag without touching the others, use talonic_documents_batch_tag with mode add.
A 403 names its reason (insufficient_scope, insufficient_role, no_person, person_inactive, workspace_read_only): the key's person must be allowed the same action in the Talonic web app, and an OAuth connection must have granted the scope. Tell the user; do not retry.
Availability
Listed per area (Spec runs, ingest, ingest settings, document organising, collections, saved filters, document types) when your role can use that area of the workspace. Being listed only means the tool is visible: Talonic checks your role again on every call.
Behaviour and cost
- Changes workspace data and can't be undone. Call it only when the user asked.
Parameters
| Parameter | Type | Description |
|---|---|---|
| document_id * | string | The document, from talonic_search or talonic_filter. |
| tags * | string[] | The complete new tag list (at most 50; empty clears). |
Example
{
"document_id": "<document_id>",
"tags": [
"<tag>"
]
}Errors
A failed call comes back as a tool error with the HTTP status and a message that says what to change. Troubleshooting lists the common ones.