> ## Documentation Index
> Fetch the complete documentation index at: https://docs.zeus.agentspro.cn/llms.txt
> Use this file to discover all available pages before exploring further.

# Get Document Chunks

> Get all semantic chunks of a document

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`.

<ParamField header="Authorization" type="string" required>
  Bearer JWT Token
</ParamField>

<ParamField path="id" type="string" required>
  Knowledge base ID
</ParamField>

<ParamField path="docId" type="string" required>
  Document ID
</ParamField>

<ResponseField name="chunks" type="array">
  List of semantic chunks

  <Expandable title="chunk object">
    <ResponseField name="chunk_index" type="number">
      Chunk index (starting from 0)
    </ResponseField>

    <ResponseField name="content" type="string">
      Chunk text content
    </ResponseField>

    <ResponseField name="metadata" type="object">
      Chunk metadata

      <Expandable title="metadata">
        <ResponseField name="source" type="string">
          Source file name
        </ResponseField>

        <ResponseField name="page" type="number">
          Page number (for PDF documents)
        </ResponseField>
      </Expandable>
    </ResponseField>
  </Expandable>
</ResponseField>

<ResponseField name="total" type="number">
  Total number of chunks
</ResponseField>

<RequestExample>
  ```bash cURL theme={null}
  curl --request GET \
    --url https://zeus-api.agentspro.cn/api/knowledge-base/kb_abc123/documents/doc_xyz789/chunks \
    --header 'Authorization: Bearer <token>'
  ```
</RequestExample>

<ResponseExample>
  ```json 200 theme={null}
  {
    "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
  }
  ```
</ResponseExample>
