INE validation service
INE service
INE service makes the process of checking the quality, patterns, and information of mexican IDs. To ensure the authenticity and avoid fake documents.
Rest Web service description
Response time.
The service is responding in 5-10s per request in production. Next, we expose the web services given by INE service.
With this method we can validate documents from INE and verify the CURP directly in RENAPO database.
~/api/Business/ine
Parameters
Tag | Type | Required | Description |
---|---|---|---|
checkInfo | boolean | yes | Data verification. Default value true. |
checkQuality | boolean | yes | Quality verification on front and back documents. Default value true. |
checkPatterns | boolean | yes | Patters verification to validate authenticity of documents. Default value true. |
checkCurp | boolean | yes | CURP verification in RENAPO database. Default value true. |
checkFace | boolean | yes | Face of the person in the mexican ID. Default value true. |
FrontFile | file | yes | Image File of the front side of INE. |
BackFile | file | yes | Image File of the back side of INE. |
Headers
Tag | Type | Required | Description |
---|---|---|---|
apikey | string | yes | Customer key. |
FormData
{
"checkInfo": boolean,
"checkQuality": boolean,
"checkPatterns": boolean,
"checkCurp": boolean,
"checkFace": boolean,
"FrontFile": file,
"BackFile": file
}
Response:
Correct:
Name | Type | Description |
---|---|---|
Valid | boolean | The result of verifications. |
type | string | Result of the type identified for the different documents like TypeC, TypeDEF. |
Validations | ||
info | boolean | Result of INE validations process. |
quality | boolean | Quality check for INE Image. Cannot have glare and it must be on focus. |
curp | boolean | Result of CURP verification in RENAPO database. |
patternCheck | boolean | Result of INE pattern check. |
face | boolean | Result of face check |
Front | ||
focus | boolean | Checks if the front image it is in focus. |
glare | boolean | Checks if the front image does not have glare. |
Back | ||
focus | boolean | Checks if the back image it is in focus. |
glare | boolean | Checks if the back image does not have glare. |
Data | ||
name | string | Name. |
firstlastname | string | First Surname. |
secondlastname | string | Second Surname. |
addressline | string | Address Line one. |
addressline2 | string | Address Line two. |
addressline3 | string | Address Line tree. |
electoralId | string | Voter ID. |
curp | string | Clave Única de Registro de Población. |
dateOfbirth | string | Date of birth. |
sex | string | Gender. |
folio | string | Identifier for the IDs type C located on the front. |
idNumber | string | Id number for the IDs type C located on the back. |
idmex | string | Id number for the IDs type DEF located on the back. |
mz1 | string | First line of values in the back of the id |
mz2 | string | Second line of values in the back of the id. Does not apply to type C. |
mz3 | string | Third line of values in the back of the id. Does not apply to type C. |
expirationDate | string | Expiration Date of the document. |
warnings | string | Error messages. |
JSON file
{
"valid": boolean,
"type": "string",
"validations": {
"info": boolean,
"quality": boolean,
"curp": boolean,
"patterns": boolean,
"face": boolean
},
"front": {
"focus": boolean,
"glare": boolean
},
"back": {
"focus": boolean,
"glare": boolean
},
"data": {
"name": "string",
"firstLastName": "string",
"secondLastName": "string",
"addressLine1": "string",
"addressLine2": "string",
"addressLine3": "string",
"electoralId": "string",
"curp": "string",
"dateOfBirth": "string",
"sex": "string",
"folio": "string",
"idNumber": "string",
"idMex": "string",
"mz1": "string",
"mz2": "string",
"mz3": "string",
"expirationDate": "string"
},
"warnings": "string"
}
Error:
Code | Message |
---|---|
Error code | "Error message". |
{
"code": string,
"message": string
}
Service messages
Code | Message | Description |
---|---|---|
00 | Success | Indicates whether the request was successful or unsuccessful. If everything goes well, the structure of the data will be displayed. |
INE001 | Incorrect params. There is no backFile or frontFile | Message that is displayed when the request has |
been completed successfully but its response has no content, (Example: when the front and back image is not sent). | ||
INE002 | Incorrect information. There is not frontFile | Message that is displayed when the front image is not sent. |
INE003 | Incorrect information. There is not backFile | Message that is displayed when the back image is not sent. |
INE005 | “The document is not a mexican ID like INE or IFE”. | Message displayed when the image does not correspond to a correct INE or IFE. |
INE008 | Something was wrong, we are working on the failure. | Message displayed when there is an error on the server. |
INE009 | Access Denied. ApiKey not present. | Message displayed when a request is received with an unauthorized ApiKey. |
INE011 | We detect two images of the same side. | Message displayed when the two images received are the same side of the document. This could be two front or two back. |
INE012 | Front image type: {Type} not supported | Message displayed when the front side of the document corresponds to a document type that is not supported because is expired. Example: Document type B. |
INE013 | Back image type: {Type} not supported. | Message displayed when the back side of the document corresponds to a type of document that is not supported because is expired. Example: Document type B. |
INE014 | Access Denied. ApiKey header not found. | Message displayed when the ApiKey does not exist. |
IDval service
Rest Web service description
With this method the technology validates get all the data from an INE with the front and back images and validate such information.
~/api/Business/idVal
Parameters
Tag | Type | Required | Description |
---|---|---|---|
FrontUrl | string | yes | URL address of the front side of INE image. |
BackUrl | string | yes | URL address of the back side of INE image. |
FrontFile | file | yes | Image file of the front side of the document type INE or IFE. |
BackFile | file | yes | Image file of the back side of the document type INE or IFE. |
Headers
Tag | Type | Required | Description |
---|---|---|---|
apikey | string | yes | Customer key. |
FormData
{
"ApiKey": string,
"FrontFile": file,
"BackFile": file
}
Response:
Correct:
Name | Type | Description |
---|---|---|
infoCheck | string | Result of INE validations process. |
qualityCheck | string | Quality check for INE Image. Cannot have glare and it must be on focus. |
patternCheck | string | Result of INE pattern check. |
focusFront | string | Checks if the front image it is in focus. |
glareFront | string | Checks if the front image does not have glare. |
focusBack | string | Checks if the back image it is in focus. |
glareBack | string | Checks if the back image does not have glare. |
isIne | ||
ineType | string | Document type. |
tipoC | string | Result if a document is type C. |
tipoDE | string | Result if a document is type D,E. |
name | string | Name. |
firstlastname | string | First Surname. |
secondlastname | string | Second surname. |
addressline1 | string | Address line one. |
addressline2 | string | Address line two. |
addressline3 | string | Address line tree. |
claveElector | string | Voter ID. |
curp | string | Clave Única de Registro de Población. |
dob | string | Date of birth. |
sex | string | Gender. |
idNumber | string | ID number, it just for document ID type C. |
idmex | string | Id number for the IDs type DEF located on the back. |
mz1 | string | First line of values in the back of the id. Does not apply to type C. |
mz2 | string | Second line of values in the back of the id. Does not apply to type C. |
mz3 | string | Third line of values in the back of the id. Does not apply to type C. |
expDate | string | Expiration Date of the document. |
error | string | Error messages. |
JSON file
{
"infoCheck": string,
"qualityCheck": string,
"patternCheck": string,
"focusFront": string,
"glareFront": string,
"focusBack": string,
"glareBack": string,
"isIne": string,
"ineType": string,
"tipoC": string,
"tipoDE": string,
"name": string,
"firstlastname": string,
"secondlastname": string,
"addressline1": string,
"addressline2": string,
"addressline3": string,
"claveElector": string,
"curp": string,
"dob": string,
"sex": string,
"idNumber": string,
"idmex": string,
"mz1": string,
"mz2": string,
"mz3": string,
"expDate": string,
"error": string,
}
onlyOCR service
Rest Web service description
With this method the technology validates get all the data from an INE with the Front and Back Images and validate such information.
~/api/Business/onlyOCR
Parameters
Tag | Type | Required | Description |
---|---|---|---|
FrontFile | file | yes | Image file of the front side of INE. |
BackFile | file | yes | Image file of the back side of INE. |
Headers
Tag | Type | Required | Description |
---|---|---|---|
apikey | string | yes | Customer key |
FormData
{
"ApiKey": string,
"FrontFile": file,
"BackFile": file
}
Response:
Correct:
Tag | Type | Description |
---|---|---|
infoCheck | string | Result of INE validations process. |
qualityCheck | string | Quality check for INE Image. Cannot have glare and it must be on focus. |
patternCheck | string | Result of INE pattern check. |
focusFront | string | Checks if the front image it is in focus. |
glareFront | string | Checks if the front image does not have glare. |
focusBack | string | Checks if the back image it is in focus. |
glareBack | string | Checks if the back image does not have glare. |
isIne | ||
ineType | string | Document type. |
tipoC | string | Result if a document is type C. |
tipoDE | string | Result if a document is type D,E. |
name | string | Name. |
firstlastname | string | First surname. |
secondlastname | string | Second surname. |
addressline1 | string | Address line one. |
addressline2 | string | Address line two. |
addressline3 | string | Address line tree. |
claveElector | string | Voter ID. |
curp | string | Clave Única de Registro de Población. |
dob | string | Date of birth. |
sex | string | Gender. |
idNumber | string | ID number, it just for document type C. |
idmex | string | Id number for the IDs type DEF located on the back. |
mz1 | string | First line of values in the back of the id. Does not apply to type C. |
mz2 | string | Second line of values in the back of the id. Does not apply to type C. |
mz3 | string | Third line of values in the back of the id. Does not apply to type C. |
expDate | string | Expiration Date of the document. |
error | string | Error messages. |
JSON file
{
"infoCheck": string,
"qualityCheck": string,
"patternCheck": string,
"focusFront": string,
"glareFront": string,
"focusBack": string,
"glareBack": string,
"isIne": string,
"ineType": string,
"tipoC": string,
"tipoDE": string,
"name": string,
"firstlastname": string,
"secondlastname": string,
"addressline1": string,
"addressline2": string,
"addressline3": string,
"claveElector": string,
"curp": string,
"dob": string,
"sex": string,
"idNumber": string,
"idmex": string,
"mz1": string,
"mz2": string,
"mz3": string,
"expDate": string,
"error": string,
}