Android SDK Guide

This guide provides detailed instructions for integrating the Scanovate Colombia SDK into your Android application, enabling robust identity validation processes through facial biometric verification.

Requirements and Compatibility

Before starting the integration process, ensure your development environment meets the following requirements:

Installation

1. Add the library

Download the "scanovate_colombia_@latest.aar" library and add it to your project's libs folder. Ensure you configure your project's build.gradle file to include the library as a dependency:

dependencies {
    implementation(name: 'scanovate_colombia_@latest', ext: 'aar')
}

2. Import Required Libraries

Add the following imports in your activity or fragment where you intend to use the Scanovate SDK:

Java

import mabel_tech.com.scanovate_demo.ScanovateHandler;
import mabel_tech.com.scanovate_demo.ScanovateSdk;
import mabel_tech.com.scanovate_demo.model.CloseResponse;
import mabel_tech.com.scanovate_demo.network.ApiHelper;
import mabel_tech.com.scanovate_demo.network.RetrofitClient;

The CloseResponse object will contain the results of the transaction, providing detailed feedback on the validation process.


Example Implementation

For a practical example of how to implement the Scanovate SDK in your Android application, refer to the following steps:

Example

// Example capture method implementation

     ScanovateSdk.start(
                this,         // Contex
                "1",         // documentType
                1,          //productId
                "1",        //RiskId
                "https://api-qa.ado-tech.com/api/EventTracer/",   //Url_TracerBackendServices 
                customerID,       //CustomerID (CID) 
                sessionID,          //SessionID (SID)
                "LuloBankQA",       //projectName
                "F99264E00A2FEA7",     //apiKey
                "https://adocolumbia.ado-tech.com/LuloBankQA/api/", //UrlBase
                numberIdentification,    //numberIdentification
                ImmersiveMode,           // Inmersive Modo
                verification,           //verification 
                "admin",                 //userName
                "0f2ebb2d8b575d53251ba6704f762cd789bb592b", //password
                object : ScanovateHandler {
                    override fun onSuccess(response: CloseResponse?, code: Int, uuidDevice: String?) {
                         // Respuesta las salidas del SDK
                    }

                    override fun onFailure(response: CloseResponse?) {
                        // Respuesta las salidas del SDK
                    }
                }
            )

Parameters Explained
Process Transaction Results

After capturing the necessary data, use the RetrofitClient to send the data for validation and display the final state of the transaction to the user.

The SDK will complete the transaction when it is part of an enrollment process. It will return a stateName with a pending status code, which can be accessed using the following in Java:

java 
response.getExtras().getStateName(); 

Or using Kotlin properties:

kotlin
val stateName = response?.extras?.stateName 
val idState = response?.extras?.idState 
val idTransaction = response?.transactionId 
val additionalInfo = response?.extras?.additionalProp1
With these values,This transactionId should be used to verify the final information by invoking the ValidationId service to query the final transaction result.

In the case of a verification process, the system will respond with a stateName indicating that the person is already registered, assigning state 14.

Overview

To retrieve the results of an identity verification transaction, you will need the transactionIdthat was provided in the callback after the verification process. This transactionIdserves as a unique identifier for the transaction.

CURL Command Structure

The curl command to retrieve the transaction results is structured as follows:

curl -X GET "{URL_Base}/api/{ProjectName}/Validation/{id}?returnImages=false" \
-H "accept: application/json" \
-H "apiKey: your_api_key" \
-H "returnDocuments: true" \
-H "returnVideoLiveness: false"

Parameters Explained

Headers

Json Example Response

{
    "Uid": "4a5528fe-4dbe-4864-993e-b4ed50e7622c",
    "StartingDate": "2024-07-17T09:39:56.07",
    "CreationDate": "2024-07-17T09:40:44.527",
    "CreationIP": "54.86.50.139",
    "DocumentType": 1,
    "IdNumber": "IdNumberNumber",
    "FirstName": "FirstNameuUser",
    "SecondName": "SecondNameUser",
    "FirstSurname": "FirstSurnameUser",
    "SecondSurname": "SecondSurnameUser",
    "Gender": "M",
    "BirthDate": "2001-10-24T00:00:00",
    "Street": null,
    "CedulateCondition": null,
    "Spouse": null,
    "Home": null,
    "MaritalStatus": null,
    "DateOfIdentification": null,
    "DateOfDeath": null,
    "MarriageDate": null,
    "Instruction": null,
    "PlaceBirth": "PlaceBirthUser",
    "Nationality": null,
    "MotherName": null,
    "FatherName": null,
    "HouseNumber": null,
    "Profession": null,
    "ExpeditionCity": null,
    "ExpeditionDepartment": null,
    "BirthCity": null,
    "BirthDepartment": null,
    "TransactionType": 1,
    "TransactionTypeName": "Enroll",
    "IssueDate": "2019-11-06T00:00:00",
    "BarcodeText": null,
    "OcrTextSideOne": null,
    "OcrTextSideTwo": null,
    "SideOneWrongAttempts": 0,
    "SideTwoWrongAttempts": 0,
    "FoundOnAdoAlert": false,
    "AdoProjectId": "2",
    "TransactionId": "2299",
    "ProductId": "1",
    "ComparationFacesSuccesful": false,
    "FaceFound": false,
    "FaceDocumentFrontFound": false,
    "BarcodeFound": false,
    "ResultComparationFaces": 0.0,
    "ResultCompareDocumentFaces": 0.0,
    "ComparationFacesAproved": false,
    "ThresholdCompareDocumentFaces": 0.0,
    "CompareFacesDocumentResult": null,
    "Extras": {
        "IdState": "2",
        "StateName": "Proceso satisfactorio"
    },
    "NumberPhone": null,
    "CodFingerprint": null,
    "ResultQRCode": null,
    "DactilarCode": null,
    "ReponseControlList": null,
    "Latitude": "4.710988599999999",
    "Longitude": "-74.072092",
    "Images": [],
    "SignedDocuments": [],
    "Scores": [
        {
            "Id": 2,
            "UserName": null,
            "StateName": "Proceso satisfactorio",
            "CausalRejectionName": null,
            "StartingDate": "0001-01-01T00:00:00",
            "Observation": null
        }
    ],
    "Response_ANI": null,
    "Parameters": null,
    "StateSignatureDocument": null,
    "SessionId": null,
    "CustomerIdFromClient": null,
    "ProcessId": null,
    "DocumentTypeFromClient": 0,
    "IdNumberFromClient": null,
    "NotEnrolledForComparisonWithClientData": false
}

Usage Tips

By following these guidelines and using the corrected URL structure and parameters, you can effectively retrieve detailed information about identity verification transactions, enhancing your application's security and user management processes.

   

  


Revision #7
Created 27 December 2024 16:01:34 by roger de avila
Updated 27 December 2024 16:44:36 by roger de avila