Skip to main content

Biometric token

This article explains how to verify the authenticity of a user who has previously passed the Authentication Score (CreateProcess), now providing a new photo to be compared with the photo from the authentication score process, using the Unico Check REST API.

The Biometric Token is a feature of Unico Check for situations in which a user who has previously passed the Authentication Score (CreateProcess) wishes to authenticate by providing a new photo.

How to use it?

Make a POST request to the /biometry/token endpoint

With a valid Access token, make a request to the endpoint (POST/biometry/token) enviando os seguintes parâmetros:

{
"processId": "ID_PROCESSO_SCORE",
"selfie": "FOTO_PESSOA"
}

Parameters:

  • HEADER PARAMETERS
NameTypeMandatory/OptionalDescription
APIKEYStringMandatoryAPI key
AuthorizationStringMandatoryAccess token
X-TenantStringMandatoryIdentificador exclusivo da empresa
  • REQUEST BODY SCHEMA
NameTypeMandatory/OptionalDescription
processIdStringMandatoryIdentificador do processo de score de autenticação (1:N) que será usado como base para comparação com a selfie fornecida
selfieStringMandatoryPhoto of the person. The image must be in base64 (png, jpg, jpeg). If the photo is captured using the Unico SDK with Liveness, the image sent must be the Json Web Token (.jwt). The .jwt must be sent within 10 minutes to prevent the image from expiring. And this .jwt can only be used once.

Exemplo de requisição:

Arquivo JSON
{
"processId": "D7A8B471-E69C-42B7-AF14-05E83365A944",
"selfie": "iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAYAAAAf8/9hAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAAJcEhZcwAADsQAAA7EAZUrDhsAAAAgSURBVDhPY/wPBAwUACYoTTYYNWDUABAYNWDgDWBgAABrygQclUTopgAAAABJRU5ErkJggg=="
}

Successful request

If the request was executed successfully, the return response is a JSON containing the status of the check as follows:

{
"authenticated": true
}

O authenticated é um boolean indicando se a foto enviada na requsição é da mesma pessoa que passou pelo score de atenticação.

Request error

If an error occurs, the return response is a JSON containing the error code and description:

{
"Error": {
"code": "40004",
"description": "Error description"
}
}

For more information on the errors returned, see the list available in the article Response Errors.

Any concerns?

Missing something or still need help? If you are already a customer or partner, you can contact us through the Help Center.