Upload Documents
Upload multiple documents.
Request Body (multipart/form-data):
files: List of files to upload (required)categories(optional): List of category names to organize documents
Returns:
documents: One unique document id per uploaded file, for status polling and later use
Supported File Types:
- Text-based files only
Editions:
The developer edition accepts plain text files only. PDF and other formats are available on the enterprise edition, which also accepts cloud storage URIs (s3://, gs://, oci://, abfss://) as the data source.
File Size Limit:
Maximum 100 MB per file
Example Request:
POST /api/v3/documents
Headers: {"Authorization": "Bearer <api_key>"}
Content-Type: multipart/form-data
Form Data:
files: [report.txt, analysis.md]
categories: ["financial", "2024-q1"]
Example Response:
{"documents": ["01KKBB7NPTMXM12", "01KKBB7NPTJDK43"]}
Processing:
Uploads are processed asynchronously. Poll GET /api/v3/documents/{id}/status until READY before using a document id elsewhere. Requires organisation membership.
Authorizations
Bearer authentication header of the form Bearer <token>, where <token> is your auth token.
Body
Response
Returns a list of document IDs.
List of unique document IDs for the uploaded documents. Use these IDs to track processing status, update categories, or download the documents.