Photo-based authenticity check
API technical documentation for reading and verifying an identity document from a photo
This API is designed to verify the authenticity of an identity document based on images of the document. It also allows you to extract the textual information related the user.
Send a request
The service is accessible through an https api.
You must sent a POST request to {API}/flow/authenticity/photo
with a form
Content-Type: multipart/form-data
containing those fields:
data a json encoded object with those properties:
photos a repeatable field which contains an image or a pdf document:
You can send a maximum of two documents.
The mime-type used (it must be one of image/* or application/pdf for a pdf document).
The accepted extensions are png, jpeg, webp and pdf.
The limit of the upload per photo is set to 10MB
Provide an extension to your filename: it must correspond to the mime/type used.
If you have only one image containing both, front and back side of the document,
business_hash*
yes
string
This is a string provided by your contact @ShareID
api_key*
yes
string
This is a string provided by your contact @ShareID
doc_type
no
string
One of id_card, passport, driver_permit, residency_permit
country_code
no
string
a lowercase ISO 3166-1 alpha-2 country code, eg: "fr"
first_name
no
string
User First name
last_name
no
string
User Last name
* Your credentials are your responsibility. You must never enter them in hard copy in your application.
if there's a timeout in the request the http code will be 408
Get the result
As soon as the request processing is finished, you will receive an http code 200 with a document described below:
doc_type
string
one of "id_card" "passport" "driver_permit" "residency_permit"
country_code
string
country code ISO 3166-1.alpha-2
doc_model
string
internal model reference detected
ocr
object / {}
data extracted from the document
security
object / {}
detailed security checks
Reasons
doc_expired
document expired
doc_expired_5y
Document expired since less than 5 years
no_doc_found
Missing document in the images
side_missing
Missing side (front or back)
missing_mrz
MRZ couldn't be extracted
wrong_mrz
MRZ is wrong
date_not extracted
Expiration or birth date couldn't be extracted
low_quality
Image quality not sufficient (example: low light)
blur_img
Blurry images
low_resolution
Image resolution not sufficient
first_name_mismatch
Mismatch in first name
last_name_mismatch
Mismatch in last name
inversed_name
Name and surname are inversed
doc_spoof
Document shown on a screen
doc_print
Document printed
doc_not_auth
Document not authentic (forgery or counterfeit document)
doc_auth
Document authentic
Document field
Last updated