When to reach for tags
Audience slicing
b2b, b2c, enterprise — surface different subsets of the same KB to
different chatbots.Search filters
Let users narrow KB search by topic without rebuilding your category tree.
Internal flags
needs-review, legal-approved, stale — workflow state that doesn’t belong
on the status field.Anatomy
The two surfaces
Tags live behind two related endpoints:Tag CRUD
POST /article-tags, GET /article-tags, DELETE /article-tags/{id} manage
the tag rows themselves — create reusable labels, list them, retire them.Article tag assignments
GET /articles/{id}/tags returns the tags on one article. PUT /articles/{id} /tags replaces the full set of assignments in a single call.tag_ids you want the article to carry.
Creating tags
Listing tags
GET /article-tags paginates. Pass search to fuzzy-match on name.
Assigning tags to an article
PUT /articles/{id}/tags replaces the assignment set. Send the complete list of tag_ids you want; anything not in the list is unassigned.
{"tag_ids": []}. To add a single tag to an article that already has tags, first GET /articles/{id}/tags, append the new id, then PUT the full list back.
Deleting a tag
DELETE /article-tags/{id} removes the tag and unassigns it from every article that carried it. Articles themselves are untouched. There is no soft-delete — recreate the tag and re-assign if you change your mind.
204 confirms the delete. The articles that had the tag remain — only the assignment rows are dropped.
