v1

latestOpenAPI 3.0.12026-07-2696152184.1 KB
Documents

Update Document

Update a knowledge base document's name, content, metadata, or folder

patch/agents/documents/{document_id}

Path parameters

document_idstring required

The ID of the document.

Headers

Cartesia-Version'2026-03-01' date required
Example:2026-03-01

API version header.

Request body

contentstring

New document text. Maximum 1 MB. Updating this property triggers re-indexing of the document.

namestring nullable

New display name. Pass null to clear.

metadataobject

Replacement metadata map. Updating this property triggers re-indexing of the document.

folder_idstring

Move the document to a different folder.

Response

Document updated.

idstring required

The ID of the document.

namestring nullable required

The document's display name, or null if unnamed.

contentstring required

The full document text.

created_atstring date-time required

When the document was uploaded.

metadataobject required

User-defined string-keyed metadata.