curl --request GET \
--url https://zeus-api.agentspro.cn/api/knowledge-base/kb_abc123/documents/doc_xyz789/chunks \
--header 'Authorization: Bearer <token>'
{
"chunks": [
{
"chunk_index": 0,
"content": "# Product User Guide\n\nThis document covers the installation, configuration, and usage of the product.",
"metadata": {
"source": "product-guide.pdf",
"page": 1
}
},
{
"chunk_index": 1,
"content": "## Installation Steps\n\n1. Download the latest installer package\n2. Run the installer...",
"metadata": {
"source": "product-guide.pdf",
"page": 2
}
}
],
"total": 45
}
Document API
Get Document Chunks
Get all semantic chunks of a document
GET
/
api
/
knowledge-base
/
{id}
/
documents
/
{docId}
/
chunks
curl --request GET \
--url https://zeus-api.agentspro.cn/api/knowledge-base/kb_abc123/documents/doc_xyz789/chunks \
--header 'Authorization: Bearer <token>'
{
"chunks": [
{
"chunk_index": 0,
"content": "# Product User Guide\n\nThis document covers the installation, configuration, and usage of the product.",
"metadata": {
"source": "product-guide.pdf",
"page": 1
}
},
{
"chunk_index": 1,
"content": "## Installation Steps\n\n1. Download the latest installer package\n2. Run the installer...",
"metadata": {
"source": "product-guide.pdf",
"page": 2
}
}
],
"total": 45
}
Returns all semantic chunks produced by SmartChunker for a document, including the content and metadata of each chunk. Only available after the document reaches
status: completed.
curl --request GET \
--url https://zeus-api.agentspro.cn/api/knowledge-base/kb_abc123/documents/doc_xyz789/chunks \
--header 'Authorization: Bearer <token>'
{
"chunks": [
{
"chunk_index": 0,
"content": "# Product User Guide\n\nThis document covers the installation, configuration, and usage of the product.",
"metadata": {
"source": "product-guide.pdf",
"page": 1
}
},
{
"chunk_index": 1,
"content": "## Installation Steps\n\n1. Download the latest installer package\n2. Run the installer...",
"metadata": {
"source": "product-guide.pdf",
"page": 2
}
}
],
"total": 45
}