Document Extraction

API Endpoints

🚧

Please export Postman Collection to test this API

Note: This API cannot be tested here as file upload is not supported in this interface. Please export the Postman Collection and try the API there.

This API helps you extract the relevant text from inside the ID uploaded by your customer using OCR, and then fetches the details linked to that ID number automatically, via the Validate API.

Note: Currently, we support the following states for Driving License OCR:

  • Delhi
  • Karnataka
  • Madhya Pradesh
  • Rajasthan
  • Punjab
  • Bihar

Document Formats Supported for OCR

  • JPEG
  • PNG
  • JPG
  • PDF (1 Pager)

📘

OCR Response Keys

Here are the Response Keys and the scenarios under which Decentro will propagate the same to the platform - Response Keys

Body Params
string
required

Any unique ID assigned by you for this API request.

string
required

Can be PAN / DRIVING_LICENSE / VOTERID / AADHAAR / PASSPORT - Only capital letters allowed

string
required
string
required
int32
required

1/0 depending on whether you want us to run KYC check on the extracted ID number or not. 1 by default, if key is not present. Not applicable when document_type is aadhaar, as we need to do an offline verification of aadhaar.

file

The ID photo or file (can be in .pdf, .jpeg, .png). Please check for layout and clarity for higher success rates. Max. allowed file size: 6 MB. Mandatory if document_url is not present.

string

The URL to the image of the document. Mandatory if document is not present.

file

The ID photo (back image) or file (can be in .pdf, .jpeg, .png). Please check for layout and clarity for higher success rates. Max. allowed file size: 6 MB. Optional - to extract both side of ID in single request.

string

The URL to the back image of the document. Optional - to extract both side of a ID in single request.

Headers
string
required

ID/identifier that is provided by Decentro to a specific client and environment. Please note, this may change based on the environment you are on.

string
required

The confidential credential provided by Decentro that is associated with the client_id

string
required
Defaults to multipart/form-data
Responses

Language
LoadingLoading…
Response
Click Try It! to start a request and see the response here! Or choose an example:
application/json