ID Card OCR
Last updated
Last updated
Extract ID CARD information from an image or photo Currently only Thai ID Card is supported. Confidence score is scored from the OCR result.
http status | error code | error message | description |
---|---|---|---|
Confidence score is -1.0 when the value of each validation field is False.
option key | description | what change |
---|---|---|
POST
https://apis.aigen.online/aiscript/idcard/v2
Name | Type | Description |
---|---|---|
200
-
-
OCR successful
206
partial_content
partial_content
Some page of request is invalid
400
no_id_card
no idcard on image
Can't detect ID CARD on image
censor_field
censor source image depend on given input fields the list of censor fields like ["id_number","title_name_surname_th"]
response data each page has key "option" in "option" has "processed_image" that contain censored_image in base64 format
return_face
Set true to enable return of facial image in UTF-8 Base64 format
response data each page has key "option" in "option" has "face" that contain face_image in base64 format
return_gender
Set true to return of the gender information
esponse data each page has key "option" in "option" has "gender" that contain "M"/"F"/"N/A"
return_signed
Set true to enable detection of overlaying signed on top of the document's photos or images
response data each page has key "option" in "option" has "signed" that contain true/false
do_field_validation
Set true to enable field validation
response data "id_number" has 2 new key valid(bool), error_message(List[str])
return_datetime_iso
Set true to enable add date time iso format to field date time
response data "dob_th","dob_en","doi_th","doi_en","doe_th","doe_en", has 3 new key valid(bool), datetime_iso(str)
image*
String
Base64 image encoded string
option
Object
Specify optional features like
{
censor_field:[field_array]
return_face: true,
...
}