Documents
Find the Chunk of a Layout Block
GET
/api/knowledge/documents/hub-documents/{document_id}/chunks/by-sourceOverview
Returns the chunk_index (lowest, if the block spans several chunks) of the active version whose meta.source_ids contains source_id (a layout block id such as p6-b7), plus total chunks, so the FE can jump to the right page of /chunks. Same access as the detail view. Active when KNOWLEDGE_BACKEND=parser.
Parameters
Path
document_idstringrequiredUnique UUID of the knowledge document stored in the vector database.
Query
source_idstringrequiredResponses
200 Chunk position
400 Bad Request - The request parameters or headers are invalid (e.g. unsupported API-Version).
401 Unauthorized - Missing, invalid, or expired JWT Bearer token.
403 Forbidden - Insufficient role permissions or resource access denied by RBAC policy.
404 No such chunk, not visible, no processed version, or hub backend
410 Share link expired
422 `source_id` malformed (`[A-Za-z0-9_.:-]{1,64}`)
detailobject[]detail[].locstring | integer[]requireddetail[].msgstringrequireddetail[].typestringrequireddetail[].inputobjectdetail[].ctxobject{
"detail": [
{
"loc": [
null
],
"msg": "string",
"type": "string",
"input": null,
"ctx": {}
}
]
} 503 Chunk store temporarily unavailable
Example
curl -X GET "$PINTER_URL/api/knowledge/documents/hub-documents/doc_it_guidelines_2026/chunks/by-source?source_id=value" \
-H "Authorization: Bearer $ACCESS_TOKEN"