Files API (NEW)
Upload Files
Upload files for processing with automatic document type detection
POST
Upload Files
POST /files/upload
Upload files for processing with automatic document type detection. This endpoint supports multiple file formats and maintains backward compatibility with the existing upload endpoint.
Features
- Supports PDF, JPG, JPEG, PNG formats
- Maximum 50 files per request, 10MB per file
- Automatic document type detection
- Maintains backward compatibility with existing upload endpoint
Request
Response
Response Fields
Field | Type | Description |
---|---|---|
doc_id | string | Unique identifier for the uploaded document |
type | string | Automatically detected document type (invoice, bank_statement, etc.) |
validation.page_count | integer | Number of pages in the document |
validation.file_size | integer | File size in bytes |
validation.format | string | File format (PDF, JPG, JPEG, PNG) |
status | string | Upload status (“done” when successful) |
Try It Out
Use the interactive playground above to test the upload endpoint. You can:
- Add your API key in the Authorization header
- Select files to upload (PDF, JPG, JPEG, or PNG)
- Execute the request to see the response
The playground will show you the exact curl command and response format.
Authorizations
Bearer authentication header of the form Bearer <token>
, where <token>
is your auth token.
Body
multipart/form-data
Response
200 - application/json
Files uploaded successfully
The response is of type object
.