API Documentation > IntelliDocs API > Document Processing.
IntelliDocs provides a single stateless REST API (/api/scan
). The response contains:
- the recognized image type (
model
) - the data in the image (
fields
) - the confidence scores for the model and each field.
In most cases (99%), response time is under 1 second.
Request
To make a request, use a JSON object. Make sure it contains either an image (in Base64 format) or an url attribute (any web address).
Response
The success response is an array of results with each result corresponding to a document. An example result may contain the following objects:
Object | Description | Attributes |
---|---|---|
model | Image Type | name , type , and confidence |
fields | Image Data | key , value , and confidence for each field |
features.faces | Image Faces | image (the encoded image), top , left , width , and height of the image, and confidence for each face |
features.signatures | Image Signatures | image (the encoded signature), top , left , width , and height of the image, and confidence for each signature |
features.tables | Image Tables | An array of tables in the document. Each table is an array of cells |
features.properties | Image Attributes | width , and height of the image, and the calculated rotationAngle in degrees |
Features
Specifying document types
The API accepts an optional modelTypes
request parameter to specify the models on which the data extraction AI must run. It is an array where each element is a Model Type. Limiting modelTypes
can increase performance by reducing the processing time and increasing accuracy. The subtypes of a model are automatically included, e.g. providing ["driver_license/usa"]
adds all US Driver's Licenses. The client may pass multiple modelTypes
such as ["driver_license/usa", "vehicle/registration/usa"]
. See Supported document types
for the full list.
If you pass ["ocr"]
as modelTypes
, the API returns the full-screen OCR of the image in response.
Handwriting
IntelliDocs API has handwriting support by default. No extra configuration is needed.
PDF417 barcodes
PDF417 is a popular 2-dimensional barcode that is used in US Driver's Licenses and DMV documents of some US states, as well as in many international IDs. It contains all the data in the document in a machine-readable format.
MRZ (machine-readable zone)
MRZ is a popular data format used in many IDs, as well as all Passports and Visas worldwide, recognizable by the <<< characters.
The MRZ Model Type is in mrz/{document type}/{issuing country's 3 digit ISO code}
format such as mrz/Visa/usa
for the Visas issued by the United States of America. document_type
can be id
, Visa
or Passport
. Click here for the full list of 3-digit ISO codes.
Data normalization
The API normalizes dates to ISO format so the caller can ignore the format on the document.
Data validation
The API runs validations on the output data as a defense against fraud and reading errors. Some fields may contain an isValid
attribute. true
means the check is passed, false
means the check is failed, and not having an isValid
attribute means no checks were run for the field.
Field | Description |
---|---|
VIN | Matches VIN checksum |
ID Number | Matches the Issuing Authority's specs format |
Expiration Date | Validates future dates |
Birthday | Validates past date |
Issue Date | Validates past |
OFAC check
The OFAC (Office of Foreign Assets Control) is a part of the United States Treasury and the group oversees determining whether a company or individual is authorized to do business in the United States. This check includes economic and trade sanctions based on US foreign policy. The documents in the ID category (ID, Driver's License, Passport, Visa, etc.) and invoices are scanned against the latest OFAC database.
DOM (Document Object Model)
You can augment the API result to include the OCR details, a.k.a. the Document Object Model (DOM).
For each page, block, line, and word, the DOM contains the text, page number, coordinates, and confidence score.
The DOM could be useful if you want to extract more information via your software or RPA solution.
The DOM is turned off by default to reduce the processing time and response size.
You may pass "showDom": true
under settings
object in the request body (see sample request)
or enable it globally on your User Settings Page.