Uploading Documents
NetraOCR accepts documents in three ways. All of them are available both in the console and over the API.
Supported formats & limits
| Property | Value |
|---|---|
| File types | PDF, PNG, JPG/JPEG, TIFF, BMP, WebP |
| Max single file | 50 MB |
| Max bulk total | 600 MB |
| PDF pages | Multi-page PDFs are fully supported |
Per-file page caps may apply depending on your plan (and, on Business plans, on the specific template). The console shows the effective limit before you upload.
1. Single upload (synchronous)
The simplest flow — upload one file and get the result back in the same response.
In the console: Dashboard → Upload → choose a file → select a template → optionally toggle integrity → Submit. The result appears in seconds.
Over the API: POST /ocr/upload with multipart/form-data. See
OCR endpoints.
Good for: interactive use, one-off documents, low-latency integrations.
2. Base64 upload (synchronous)
Identical to single upload, but the file is sent as a Base64 string inside a JSON body instead of multipart form data. Ideal when multipart is inconvenient — for example calling from a serverless function or a system that only speaks JSON.
Over the API: POST /ocr/upload-base64. See
OCR endpoints.
3. Bulk upload (asynchronous)
Submit many files at once — a whole folder of invoices, for example. Bulk uploads are processed in the background and grouped into a batch.
The recommended flow is two steps:
- Analyze (
POST /ocr/bulk-analyze) — a pre-flight check that validates every file (type, size, page count) and returns an accurate cost estimate. It does not create jobs. - Upload (
POST /ocr/bulk-upload) — submits the batch for processing and returns abatch_id. Watch the batch, or poll individual jobs, to collect results.
In the console: Dashboard → Upload → select multiple files / a folder. The UI runs the analysis automatically and shows you the cost before you confirm.
See OCR endpoints, Batches, and Jobs & Results for the API details.
Choosing a template at upload time
Every OCR upload requires a selected template. Over the API, pass its template_id
so the result is returned as structured data keyed to your fields:
- Pass a global template ID (e.g.
gl1) → structured data using a built-in schema. - Pass a user template ID → structured data using your custom schema.
Learn how to create templates in Templates.
Enabling document integrity
Set the integrity option on upload to additionally screen the document for tampering. The check runs in the background and is retrieved separately — see Document Integrity.
What you get back
| Field | Description |
|---|---|
job_id | Unique ID for this processing job |
structured_data | Typed fields from the selected template |
page_count | Number of pages processed |
document_type | Detected document type (e.g. invoice) |
processing_time_ms | How long processing took |
coins_consumed | Usage charged for this job |
Next: review and export results in Results & Exports.