List Chunks
Lists the chunks of one revision of a document, ordered by chunk ID rather than by position. Takes the document ID from List Documents, not the document file ID, plus the revision number.
To read chunks in document order, fetch every page and sort by ordinal.
Any revision can be listed, including a superseded one, as long as the document file version behind it still exists.
For how document IDs and document file IDs relate, see Browse Documents and Chunks.
1 min read
get/knowledge-fs/spaces/{knowledge_base_id}/documents/{document_id}/revisions/{revision}/chunks
Request example
Response
get/knowledge-fs/spaces/{knowledge_base_id}/documents/{document_id}/revisions/{revision}/chunks
Authorization
Path parameters
Knowledge base ID: the last segment of the Service API endpoint shown in the knowledge base's API Access dialog (
…/knowledge-fs/spaces/<knowledge base ID>), and the segment after /datasets/new/ in the address bar.The document ID, from List Documents or from the address bar of the open document (
/datasets/new/<knowledge base ID>/documents/<document ID>).Query parameters
Case-insensitive substring to match against
text. Not a semantic search. Omit it to list every chunk.Length: 1–512
Responses
application/json
One page of chunks.