Endpoint
Authentication
Requiresextractions:write scope.
Request
Headers
| Header | Value | Required |
|---|---|---|
X-API-Key | Your API key | Yes |
Body
Form data with file uploads:| Field | Type | Required | Description |
|---|---|---|---|
files | file | Yes | One or more files to upload (can repeat for multiple files) |
Extraction-Compatible File Types
The upload endpoint stores files and returns document IDs. Schema generation and extraction currently process:- PDF:
.pdf - Images:
.jpg,.jpeg,.png,.tiff,.bmp
Request Limits
The backend does not enforce a documented per-file or per-request count limit in application code. Infrastructure may still reject oversized requests. For reliability, keep batches small and retry failed upload requests.Response
Success Response (200)
Returns an array of document IDs:Examples
Error Responses
400 Bad Request
Malformed multipart request:401 Unauthorized
Missing or invalid API key:413 Payload Too Large
Infrastructure may reject oversized requests before they reach the backend:500 Internal Server Error
Server error during upload:Best Practices
Batch Upload for Efficiency
Batch Upload for Efficiency
Upload multiple files in a single request instead of making multiple requests. This is faster and more efficient.
Check File Size Before Upload
Check File Size Before Upload
Validate file sizes client-side to avoid failed uploads and improve user experience.
Handle Upload Errors
Handle Upload Errors
Implement retry logic with exponential backoff for failed uploads, especially for large files.
Store Document IDs
Store Document IDs
Save the returned document IDs; they are required for schema generation and extraction requests.
Rate Limits
Upload endpoint is subject to rate limits based on your subscription tier. Contact support for higher limits.Notes
- Each upload receives a new document ID
- Upload stores the file only; OCR/layout processing runs during schema generation or extraction
Next Steps
Extract Data
Extract structured data from uploaded documents
Generate Schema
Auto-generate extraction schema from document
List Documents
View documents with extraction records
Upload Guide
Detailed upload workflow guide