Skip to content

Start OCR Processing

Initiate OCR processing for a document in your workspace

Note

The OCR API is currently in closed beta.

The start OCR endpoint initiates OCR processing for a document that has been uploaded to a job in your workspace. This is an asynchronous operation that queues the document for processing and returns immediately.

You can either use an existing document in your workspace or create a new document using the Create Documents endpoint, which will return the document_id.

The document must be available for download before OCR processing can start. If file processing or document verification is still in progress, or manual verification is required, this endpoint returns a 409 Conflict response.

After starting OCR processing, use the Get OCR Results endpoint to check the processing status and retrieve the extracted data.

If OCR processing previously failed for a document, calling this endpoint again will automatically retry the process.

Endpoint

MethodUrl
POST/v1.0/ocr/start

Request Parameters

document_id
•
string
required

The unique identifier of the document to process. This ID is returned when you upload a document using the Create Documents endpoint. The document must already be uploaded to a job in your workspace.

Sample Request

bash
Copied
1curl -X POST 'https://api.worklayer.com/v1.0/ocr/start' \
2 -H 'Authorization: Bearer {token}' \
3 -H 'Content-Type: application/json' \
4 -d '{
5 "document_id": "95e6f305-913e-40ad-9c80-ede263670878"
6 }'

Response

The response confirms that OCR processing has been initiated for the specified document.

document_id
•
string

The document ID that was submitted for OCR processing.

Sample Response

json
Copied
1{
2 "document_id": "95e6f305-913e-40ad-9c80-ede263670878"
3}

Errors

Error Responses

The API returns standard HTTP status codes with descriptive error messages:

Status CodeError TypeDescription
400Bad RequestInvalid document ID format or missing required fields
401UnauthorizedMissing or invalid bearer token
403ForbiddenUser lacks permission
404Not FoundDocument not found or workspace not found
409ConflictOCR processing is already in progress or completed for this document
409ConflictDocument is not ready for OCR processing
500Internal Server ErrorError starting OCR processing
Last updated on August 24, 2026