zoxaAI
Homepage
API ReferenceKnowledge Base

Knowledge Base overview

How documents are ingested, chunked, embedded, and retrieved.

The Knowledge Base API lets you upload documents, chunk + embed them in the background, and retrieve relevant chunks during a call via the query tool type.

Lifecycle

[upload]  →  [process]  →  [chunks indexed]  →  [retrievable in calls]
   ↓             ↓                                       ↑
upload-url   process-document                        query tool
+ PUT file   (or create-from-text)                   (during a call)

Endpoints

MethodPathPurpose
POST/knowledge-base/upload-urlGet a presigned S3 URL to PUT a file.
POST/knowledge-base/create-from-textCreate a doc directly from pasted text.
POST/knowledge-base/process-documentRegister an uploaded file for processing.
GET/knowledge-base/documentsList documents.
GET/knowledge-base/documents/{uuid}Document detail (status, total chunks, error).
DELETE/knowledge-base/documents/{uuid}Soft-delete a document + its chunks.
POST/knowledge-base/searchVector search across your documents.

Embedding model

Embeddings are computed with OpenAI text-embedding-3-small (1536 dims). The platform's OpenAI key is used — you don't supply one.

Retrieval modes

Documents are ingested with one of two retrieval modes:

ModeWhen to use
chunked (default)Long documents — chunked at ~128 tokens and individually embedded. Best for fact lookup.
full_documentShort documents (FAQs, single-topic notes) where the LLM benefits from the full text every time.

Processing states

StateMeaning
pendingDocument record exists; processing job not yet picked up.
processingBackground worker is parsing + embedding.
completedChunks indexed; document is queryable in calls.
failedParsing or embedding errored — see processing_error field.

Calls work without waiting

You can reference a documentId in an agent or query tool before processing completes — the retrieval simply returns no chunks until status is completed. Don't block on processing in real-time provisioning flows.

File size + format

LimitValue
Max file size100 MB
Presigned URL expiration30 minutes
Supported formatsPDF, DOCX, DOC, TXT, MD, JSON, and CSV via the Files API, plus additional formats handled by the document-parsing engine

On this page