Update a document (re-indexes on content change)
PATCH/v1/knowledge-bases/:kb_id/documents/:document_id
Update a document's content, title or metadata.
Changing content re-chunks and re-embeds the document and replaces its old
chunks, so stale text stops surfacing in search results. metadata is merged
rather than replaced, so you can add keys without resending the whole object.
Title-only or metadata-only edits skip re-indexing and return immediately.
Requires the knowledge:write scope.
Request
Responses
- 200
- 400
- 401
- 403
- 404
- 422
- 429
Successful Response
Error
Error
Error
Error
Validation Error
Error