Skip to main content

POST Services

GET TOKEN

This service should only be consumed when OAuth is active in the application. It generates a token to consume the other services.

PARAMETERS
PARAMETER TYPE MEDIUM DESCRIPTION
grant_type String FormData Type of Authorization
username String FormData Username assigned by Ado for the token query.
password String FormData Password corresponding to the assigned user for the token query, must be in SHA-1 hash format.

Example consumption:

1
curl -X POST "http://localhost:62859/api/token" -H "accept: application/json" -H "Content-Type: application/x-www-form-urlencoded" -d "grant_type=password&username=username&password=sha1password"

RESPONSES
Code Description
200 JSON object containing the token and other fields described in the RESPONSE FIELDS table
400 unsupported_grant_type
The user name or password is incorrect.

RESPONSE FIELDS:
Field Name TYPE DESCRIPTION
access_token String El token emitido.
token_type String Tipo de token generado.
expires_in Int Tiempo de vigencia del token en minutos.
issued String Fecha y hora de emisión de emisión del token.
expires String Fecha y hora de vencimiento del token.

Example response:

1
2
3
4
5
6
7
{
    "access_token": "laK8SdjrKUAN7ja4SicUS-mL8eNWW74OTU2ZmSzjABLCGUgZknEifQkNtd5F20pBQiWvDpVwda9Bf31hB-mnzJLWmuKYY1sygHT37RQGI3Ym1HkLHwduutHwze2m9ZSBWCSV9NgOjO5Zd0Rcl9eexjFOS7cR6lOIZxxu31rLI_mHMbgtdSMAG-gToiHkgeXw6zbYjVaO1IzKMDjczyLZuvlYOfKNiJeh-3XbfjRxUy0",
    "token_type": "bearer",
    "expires_in": 59,
    ".issued": "Mon, 27 Jul 2020 20:38:24 GMT",
    ".expires": "Mon, 27 Jul 2020 20:39:24 GMT"
}

NEW

Sending a selfie to the server

Name New
Url {URL_Base}/api/integration/{projectName}/Validation/New
TYPE POST


PARAMETERS
Name Data Type Parameter Type Required Description
ProjectName String Query Yes The name of the associated project.
Apikey String Header Yes The key assigned to the project.
Authorization String Header No Access token.
transactionInfo Json Body Yes The data of the new transaction.


Specification of the transactionInfo field

Name Type Required Description
ProductId Int Yes Product number for the verified customer transaction.
CustomerPhoto String Yes Base64-encoded selfie image
DocumentType String No Document type ID, obtained by consuming the IDENTIFICATIONTYPES service. If it is not provided in the request, the default value assigned is Cédula de ciudadanía (ID 1).
Longitude String No Longitude of the location where the process takes place.
Latitude String No Latitude of the location where the process takes place.
IdAssociated String No Co-signer’s identification number
ClientRole String No Assigned role number for the platform
KeyProcessLiveness String No Liveness process key received during the selfie capture process
UIdDevice String No Character string that defines and identifies the device from which the request is made
IdUser String No ID registered on the ADO platform for the user making the service request
SourceDevice Integer No Number that identifies the type of device: 1 for Web, 2 for Android, and 3 for iOS.
SdkVersion string No Build or SDK version number being used, which can be found in the repository's ChangeLog.
OS string No Type of operating system from which the service is being consumed
BrowserVersion string No If the OS field is set to Web, the browser version used is sent.
IMEI string No IMEI of the mobile device consuming the service
RiskId string No Risk classification ID
Uid String No Transaction identification number. If this is the first service call, the service will return a UID that must be sent in all subsequent service requests until the Close service is executed. If a UID already exists, it must be included to associate the uploaded images with the same transaction.


RESPONSES
Code Description
200 The transaction has been successfully initiated. An object is returned containing information associated with it.
201 The face being validated is already enrolled. An object is returned containing information about the created transaction, including the unique transaction number.
400 The type of document not is valid

The risk ID is not valid

The risk ID is not valid 

The risk ID must be an integer

Document type is not active
401 The api key value is required
Api Key not valid
Can't found User with specified credentials
Can't found specified Source Device
404 The specified project was not found
406 The facial photograph does not meet the expected criteria. This may be due to the face in the image having glasses, an open mouth, or a blink..
Base64 not valid.
Image not valid.
500 An error has occurred. Please check the error and try again.

DOCUMENTBACKSIDE

Allows uploading the back side of an identity document.

Name DocumentBackSide
Url {URL_Base}api/integration/{projectName}/
Validation/Images/DocumentBackSide
TYPE POST


PARAMETERS
Name Data Type Parameter Type Required Description
ProjectName String Query Yes The name of the associated project
Apikey String Header Yes The key assigned to the project
Authorization String Header No Access token
sideTwoInfo Json Body Yes The data of the new transaction


Specification of the sideTwoInfo field

Name Type Required Description
Image String Yes Image of the back side of the document in Base64 format
DocumentType String No Document type ID, obtained by consuming the IDENTIFICATIONTYPES service. If this field is not provided, the system will default to assigning “Cédula de ciudadanía” (ID 1) as the document type.
UIdDevice String No String that defines and identifies the device from which the request is made.
SourceDevice Integer No Number that identifies the device type, with values of 1 for Web, 2 for Android, and 3 for iOS.
SdkVersion string No Build or SDK version number being used, which can be found in the repository's ChangeLog.
OS string No Type of operating system from which the service is being consumed
BrowserVersion string No If the OS field is set to Web, the browser version used is sent.
TransactionType string No Transaction type ID
ProductId string No Product number for the transaction
Uid String No Transaction identification number. If this is the first time the service is consumed, it will return a UID that must be sent in all subsequent service calls until the Close service is executed. If a UID already exists, it must be included to associate the uploaded images with the same transaction.
RiskId String No Risk classification ID


RESPONSES
Code Description
200 The transaction has been successfully initiated. An object containing information associated with it is returned. RESPONSE OBJECT DESCRIPTION
201 The client was previously registered. An object is returned containing information about the created transaction, including the unique transaction number.
400 The type of document not is valid
The specified transaction type was not found
Transaction type Id must be a valid integer
Document type is not active
Sdk Versión is not valid
401 The api key value is required
Api Key not valid
Can't found User with specified credentials
Can't found specified Source Device
404 The specified project was not found
406 Base64 not valid.
Image not valid.
500 An error has occurred. Please validate the error and try again.

FINGERPRINT

Allows uploading the fingerprint image

Name Fingerprint
Url {URL_Base}api/integration/{projectName}/
Validation/Images/Fingerprint
TYPE POST


PARAMETERS
Name Data Type Parameter Type Required Description
ProjectName String Query Yes The name of the associated project
Apikey String Header Yes The key assigned to the project
Authorization String Header No Access token
fingerInfo Json Body Yes The image encoded in Base64


Specification of the fingerInfo field

Name Type Required Description
Image String Yes Image of the front of the document in Base64 format
DocumentType String Yes

Document Type Number:

  1. Citizenship ID (Cédula de Ciudadanía)

  2. PEP with passport only

  3. Foreigner ID (Cédula de Extranjería)

  4. Identity Card (Tarjeta de Identidad)

FingerType int Yes Fingerprint enumerator, possible values: (1, 2)
Uid String Yes Transaction identification number. If this is the first time the service is consumed, it will return a UID that must be sent in all subsequent service calls until the Close service is executed. If a UID already exists, it must be included to link the uploaded images to the same transaction.
RiskId String No Risk identifier


RESPONSES
Code Description
200 The fingerprint has been successfully uploaded and the transaction information has been updated.
400 The provided data does not match the expected criteria
401 The authorization process was not successful. Please validate the project code and/or the API Key.
403 The fingerprint photograph is not valid for biometric extraction.
404 The project code and/or the specified UID does not exist.
500 An error has occurred. Please validate the provided ID number to obtain more details.

 

CLOSE

Allows finalizing the current transaction. Assigns a unique transaction number

Name Close
Url {URL_Base}/api/Integration/{projectName}/Validation/Close
TYPE POST


PARAMETERS
Name Data Type Parameter Type Required Description
ProjectName String Query Yes The name of the associated project
Apikey String Header Yes The key assigned to the project
Authorization String Header No Access token
info Json Body Yes The information required to close the transaction


Specification of the info field

Name Type Required Description
Uid String Yes Transaction UID
RiskId String No Risk classification ID


RESPONSES
Code Description
200 The transaction has been successfully created. An object containing information associated with it is returned — RESPONSE OBJECT DESCRIPTION
400 The risk ID is not valid
The risk ID must be an integer.
401 The api key value is required
Api Key not valid
404 The specified project was not found<404>
500 An error has occurred. Please check the error and try again.

 

CHECKHEALTH

POST web service that returns the overall status of the platform. If everything is functioning correctly, the Messagefield in the response will have the value “Alive.”

NameCheckHealt
URL{URL_Base}/api/Integration/CheckHealt
TYPEPOST


PARAMETERS
NameData TypeParameter TypeRequiredDescription
ProjectNameStringqueryYesThe name of the associated project
apiKeyStringheaderYesThe key assigned to the project
authorizationStringheaderYesAccess token


RESPONSES
CodeResponseDescription
200{
"Code": "String",
"Message": "String"
}
JSON-formatted object containing information related to the platform status

 

DESCRIPTION OF THE RESPONSE OBJECT


NameTypeDescription
{
UidStringTransaction identification number
StartingDateStringDate and time when the first required image for the validation process began transmitting to the server.
CreationDateStringDate and time when the full set of images required for the validation process finished transmitting to the server.
CreationIPStringIP address from which the identity validation process was performed
DocumentTypeInt

Document Type Number:

  1. Citizenship ID

  2. PEP with passport only

  3. Foreigner ID

  4. Identity Card

IdNumberintIdentification number of the validated client
FirstNameStringFirst name of the verified client
SecondNameStringSecond name of the verified client
FirstSurnameStringFirst surname of the verified client
SecondSurnameStringSecond surname of the verified client
GenderStringGender of the verified client
BirthDateStringDate of birth of the verified client in YYYY-MM-DD format, ignoring the time
StreetStringAddress of the verified client
CedulateConditionString 
SpouseString 
HomeString 
MaritalStatusStringMarital status of the verified client
DateOfIdentificationStringFecha de expiración de cedula en rutinas que hacen consulta del registro civil de ecuador, unicamente cuando el servicio esta activo para traer esta información. Este campo es en formato AAAA-MM-DD, ignorar la hora.
DateOfDeathStringDateOfDeath.
MarriageDateStringMarriageDate.
InstructionString 
PlaceBirthStringLugar de nacimiento del cliente verificado.
NationalityStringNacionalidad del cliente verificado.
MotherNameStringNombre de la madre del cliente verificado.
FatherNameStringNombre del padre del cliente verificado.
HouseNumberString 
ProfessionStringProfesión del cliente verificado.
ExpeditionCityStringExpeditionCity.
ExpeditionDepartmentStringExpeditionDepartment.
BirthCityStringBirthCity.
BirthDepartmentStringBirthDepartment.
TransactionTypeintTipo de transacción realizada.
TransactionTypeNameStringNombre del tipo de transacción realizada.
IssueDateStringFecha de expedición del documento presentado por el cliente verificado en formato AAAA-MM-DD, ignorar la hora.
BarcodeTextString 
OcrTextSideOneStringTexto extraído de la toma de documentos por OCR (cara delantera del documento).
OcrTextSideTwoStringTexto extraído de la toma de documentos por OCR (cara posterior del documento).
SideOneWrongAttemptsintNumero de intentos fallidos tomando la cara delantera del documento.
SideTwoWrongAttemptsintNumero de intentos fallidos tomando la cara psoterior del documento.
FoundOnAdoAlertStringRetorna un booleano indicando si hubo alertas en la plataforma de ADO.
AdoProjectIdStringNúmero del proyecto en la plataforma de ADO.
TransactionIdStringNumero de la transacción para la certificación del cliente.
ProductIdStringNumero de producto para la transacción del cliente verificado.
ComparationFacesSuccesfulbooleanRetorna un booleano indicando si la comparación de rostros fue satisfactoria.
FaceFoundbooleanRetorna un booleano indicando si se encontró un rostro durante la transacción.
FaceDocumentFrontFoundbooleanRetorna un booleano indicando si se encontró un rostro en el documento de la transacción.
BarcodeFoundbooleanRetorna un booleano indicando si se encontró un código de barras durante la transacción.
ResultComparationFacesintResultado de la comparación de rostros.
ResultCompareDocumentFacesintResultado de la comparación de rostros en los documentos.
ComparationFacesAprovedbooleanRetorna un booleano indicando si la comparación de rostros fue aprobada.
ThresholdCompareDocumentFacesintRetorna un entero con el umbral de comparación configurado .
CompareFacesDocumentResultstringCompareFacesDocumentResult.
"extras”: { 
IdStateStringNumero de calificación para la transacción.
StateNameStringCalificación de la transacción.
} 
NumberPhoneStringNúmero de teléfono del cliente verificado.
CodFingerprintString 
ResultQRCodeString 
DactilarCodeString 
ResponseControlListString 
LatitudeStringLatitude
LongitudeStringLongitude
"Images" : [{ 
IdStringNúmero de identificación de la imagen.
ImageTypeIdStringId del tipo de imagen.
ImageTypeNameStringNombre del tipo de imagen.
ImageStringImagen en base64.
DownloadCodeStringCódigo de descarga de la imagen.
}], 
SignedDocumentsString ArrayArreglo con la lista de documentos firmados digitalmente, estos documentos se retornan en base 64, para su visualización se debe convertir a PDF.
"Scores" : [{ 
IdintId de la calificación.
UserNameString 
StateNameStringNombre de la calificación.
StartingDateStringFecha y hora en que se empezó a transmitir al servidor, la primera imagen requerida para realizar el proceso de validación.
ObservationStringObservaciones sobre la transacción.
}] 
"Response_ANI": { 
NiupStringNúmero de identificación del cliente consultado en ANI.
FirstSurnameStringPrimer apellido del cliente consultado en ANI.
ParticulaString 
SecondSurnameStringSegundo apellido del documento consultado en ANI.
FirstNameStringPrimer nombre del documento consultado en ANI.
SecondNameStringSegundo nombre del documento consultado en ANI.
ExpeditionMunicipalityStringMunicipio de expedición del documento consultado en ANI.
ExpeditionDepartmentStringDepartamento de expedición del documento consultado en ANI.
ExpeditionDateStringFecha de expedición del documento consultado en ANI.
CedulaStateString 
} 
ParametersStringParámetros enviados por el cliente asociados a la transacción (Formato Json).
StateSignatureDocumentStringIndicar si se han firmado digitalmente los documentos asociados a la transacción.
}