Upload File
Upload a document file to process and extract data.
What you need:
- Parser ID: Find it in Parser Settings → General Settings
- API Key: Generate it from Team Settings → API Keys
How to use:
- Endpoint:
POST /api/v1/process/{parserId}/files - Send the file as
multipart/form-datawith field namefile - Include your API key in the
Authorizationheader
What you get:
- Response includes
documentIdfor the uploaded document - Document status will be
processinginitially - Use the
documentIdwith the "Get Document Data" endpoint to retrieve extracted data once processing is complete
Authorization
bearerAuth Your API key. Include it directly in the Authorization header as the API key value (e.g., 'authorization: your-api-key-here')
In: header
Path Parameters
The ID of the parser
uuidRequest Body
multipart/form-data
File to upload
The document file to upload
binaryResponse Body
application/json
curl -X POST "https://app.digiparser.com/api/v1/process/d1458cd7-8692-488f-8b3f-0fddade05f9c/files" \ -F file="string"{
"success": true,
"result": [
{
"id": "2b9b1243-3d94-42b0-9515-729c7404e3b7",
"name": "sample-invoice.pdf",
"url": "https://documents.digiparser.com/resources/t/01dd1542-7aac-463c-8eda-a7e042fd5876/p/d1458cd7-8692-488f-8b3f-0fddade05f9c/d/2b9b1243-3d94-42b0-9515-729c7404e3b7/sample-invoice.pdf?sig=70adb475a196e71cd2f82c40623bb9be94647aff0d187120ee39c9fd9c7a10d0",
"isProcessed": false,
"status": "processing",
"message": "Extraction started: EXTRACT (f19c7e5b-efb1-48fd-bcd1-876b7aa211a7) job initiated (markdown parsing disabled)",
"operationName": "f19c7e5b-efb1-48fd-bcd1-876b7aa211a7",
"documentId": "2b9b1243-3d94-42b0-9515-729c7404e3b7",
"pageCount": 1
}
]
}Get Document Data GET
Retrieve the extracted data from a processed document. **What you need:** - **Parser ID**: Find it in Parser Settings → General Settings - **Document ID**: Get this from the upload response (`documentId` field) - **API Key**: Generate it from Team Settings → API Keys **How to use:** - Endpoint: `GET /api/v1/process/{parserId}/files/data?documentId={documentId}` - Include your API key in the `Authorization` header **What you get:** - **data**: Extracted field values and table data matching your parser's schema - **metadata**: Document information including status, timestamps, and file details **Note:** If the document is still processing, the `data` field will be empty and `status` will be `processing`. Poll this endpoint periodically until `status` is `processed` or `failed`.
Upload via URL POST
Upload a document by providing a URL pointing to the document file. **What you need:** - **Parser ID**: Find it in Parser Settings → General Settings - **API Key**: Generate it from Team Settings → API Keys - **Document URL**: A publicly accessible URL to the document file **How to use:** - Endpoint: `POST /api/v1/process/{parserId}/urls` - Send `urls` as `application/x-www-form-urlencoded` (can be a single URL or comma-separated multiple URLs) - Include your API key in the `Authorization` header **Example:** ``` urls=https://example.com/document.pdf ``` **What you get:** - Response includes `documentId` for each uploaded document - Document status will be `processing` initially - Use the `documentId` with the "Get Document Data" endpoint to retrieve extracted data once processing is complete