/extract

Upload Document

Upload a document for structured extraction.

Uploads a PDF document that can be used for structured data extraction. Only PDF files are supported.

Supported File Types: 1. PDF files only (.pdf extension) 2. Maximum file size: 50MB (recommended) 3. Documents are processed and validated upon upload

Document Processing: 1. File size and page count are automatically calculated 2. Document is validated for PDF format and readability 3. Metadata is extracted and stored for future reference 4. Document is stored securely and can be referenced by ID

Usage: After uploading, you'll receive a document_id that can be used with: 1. /jobs endpoint to start extraction jobs 2. /documents/{document_id} to retrieve document information 3. /documents/{document_id} DELETE to remove the document

Example Response:

{
  "document_id": "123e4567-e89b-12d3-a456-426614174000",
  "file_name": "financial_report.pdf",
  "file_size": 2048576,
  "page_count": 45,
  "uploaded_at": "2025-01-11T18:35:00Z",
  "status": "uploaded"
}
post/extract/documents/upload

Response

Successful Response

document_idstring required

Unique ID of the uploaded document

file_namestring required

Original filename of the uploaded document

file_sizeinteger required

File size in bytes

page_countinteger required

Number of pages in the document

uploaded_atstring required

Timestamp when the document was uploaded

statusstring required

Upload status

Changes