Upload Document

Upload a document (PDF, plain text, markdown, or HTML) to a knowledge base. The document is extracted, chunked, embedded, and indexed synchronously; expect a few seconds per MB of input. Maximum 10 MB per upload.

Authentication

AuthorizationBearer

Enter the key with the Bearer prefix, e.g. ‘Bearer API_KEY|ACCESS_TOKEN’.

Path parameters

idstringRequired

Request

This endpoint expects a multipart form containing a file.
filefileRequired

Response

The ingested document record.
idstring
kb_idstring
filenamestring
content_typestring
byte_sizelong
char_countinteger
chunk_countinteger
statusenum
Allowed values:
created_atdatetime
updated_atdatetime
errorstring
Populated when status is failed.