Mexico ID Card OCR
id number + name recognition
Code example:
Response for card front recognition success
Response for card back recognition success
Response for recognition fail
Response for invalid request parameters
Response for invalid image format
Response for image size larger than 2M
Response for server error
HTTP request
POST https://api.ekycpro.com/v1/mx_ocr/general
Request parameters
parameter | description |
---|---|
img | string , base64 encoded image. It is recommended that the image be less than 200KB, so it will be returned within 2 seconds, otherwise the return time will be longer. |
Response format
fields | description |
---|---|
status | status code |
message | idNumber : id number fullName : name fatherLastName : father lastName motherLastName : mother lastName name : name birthday : birthday gender : gender expiryYear : expiry year issueYear : issue year voterId : voter id placeNumber : place number stateNumber : state number municipalNumber : municipal number state : state district : district subDistrict : sub district addressAll : address postalCode : postal code registrationYearAndMonth : registration year and month |
Status code
status | description |
---|---|
OK | charge , success |
FAIL | charge , image recognition error, please check input image |
INVALID_REQUEST | free , invalid request parameters |
IMAGE_INVALID_FORMAT | free , invalid image format, image format should be one of jpeg/jpg/png/bmp |
IMAGE_INVALID_SIZE | free , invalid image size, should be less than 2M |
INNER_ERROR | free , server error |