Skip to main content
POST
/
api
/
v2
/
images
/
ocr
/
price
cURL
curl --request POST \
  --url https://api.deapi.ai/api/v2/images/ocr/price \
  --header 'Accept: <accept>' \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: multipart/form-data' \
  --form 'image=<string>' \
  --form model=Nanonets_Ocr_S_F16 \
  --form language=en \
  --form format=text \
  --form 0.image='@example-file'
{
  "data": {
    "price": 0.15
  }
}

Documentation Index

Fetch the complete documentation index at: https://docs.deapi.ai/llms.txt

Use this file to discover all available pages before exploring further.

Estimate the cost of an OCR job before submitting it.

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Headers

Accept
enum<string>
default:application/json
required
Available options:
application/json

Body

multipart/form-data

Image to text conversion parameters

image
file
required

Image file to extract text from. Supported formats: JPG, JPEG, PNG, GIF, BMP, WebP. Maximum file size: 10 MB.

model
string
required

The OCR model to use for text extraction. Available models can be retrieved via the GET /api/v1/client/models endpoint.

Example:

"Nanonets_Ocr_S_F16"

language
string | null

Language code for OCR processing (optional)

Example:

"en"

format
enum<string> | null

Output format for extracted text

Available options:
text,
json
Example:

"text"

Response

Calculated price for img2txt inference.

data
object