SDK Documentation
  • Welcome!
  • Document Capture
    • Overview
    • Android Native SDK
      • Installation Guide
      • Implementation Guide
      • SDK Response
    • iOS Native SDK
      • Installation Guide
      • Implementation Guide
      • SDK Response
    • React Native Plugin
      • Installation Guide
      • Implementation Guide
      • Plugin Response
    • Flutter Plugin
      • Installation Guide
      • Implementation Guide
      • Plugin Response
    • Cordova Plugin
      • Installation Guide
      • Implementation Guide
      • Plugin Response
    • Release Notes
      • 🟦Latest Patch Release
      • Minor Release - 12/09/2024
      • Major Release - 11/06/24
      • Minor Release - 07/03/24
      • Minor Release - 30/11/23
      • Minor Release - 17/08/23
      • Minor Release - 03/07/23
      • Minor Release - 15/06/23
      • Minor Release - 15/03/23
      • Major Release - 02/04/23
    • 🆕Coming Soon
  • Biometrics
    • Overview
    • Android Native SDK
      • Installation Guide
      • Implementation Guide
      • SDK Response
    • iOS Native SDK
      • Installation Guide
      • Implementation Guide
      • SDK Response
    • React Native Plugin
      • Installation Guide
      • Implementation Guide
      • Plugin Response
    • Flutter Plugin
      • Installation Guide
      • Implementation Guide
      • Plugin Response
    • Cordova Plugin
      • Installation Guide
      • Implementation Guide
      • Plugin Response
    • Release Notes
      • 🟦Latest Patch Release
      • Minor Release - 17/08/23
      • Minor Release - 03/07/23
      • Minor Release - 15/03/23
      • Major Release - 02/04/23
  • SDK Error Codes
  • Support
    • Contact Us
    • Legacy SDKs
Powered by GitBook
On this page
  • SDK Listener
  • Response Instances
  • Primary Response Object
  • Object Body
  • Instance Responses
  1. Biometrics
  2. Android Native SDK

SDK Response

SDK Listener

Use the following code snippet to receive SDK callbacks

 VIDVLivenessListener vidvLivenessListener=new VIDVLivenessListener() {
           @Override
           public void onLivenessResult(VIDVLivenessResponse livenessResponse) {
                if (livenessResponse instanceof Success) {
                
                    
                    
                //an example code to use the response in your app : 
                //this variable will have a base64 captured image during the Liveness proccess.
                String base64Image =  ((Success) livenessResponse).vidvLivenessResult.capturedImage(); 
                // Add your code here
                
                } else if (livenessResponse instanceof BuilderError) {
                
                    // Add your code here
        
                } else if (livenessResponse instanceof ServiceFailure) {
        
                    // Add your code here
            
                } else if (livenessResponse instanceof UserExit) {
            
                    // Add your code here
          
                }else if (livenessResponse instanceof CapturedActions){
            
                    // Add your code here
            
            	}
            }
    	};

Response Instances

Success : Process finished successfully

CapturedActions: Images captured are returned in real-time

Note: ForCapturedImagesinstance, images are not processed yet

UserExit : Process terminated by the user with no errors

ServiceFailure : Process finished with the user's failure to pass the service requirements

BuilderError : Process terminated due to an error in the builder

Note: Check your configurations

Primary Response Object

VIDVLivenessResult

Note: This is the first-level object that contains all the second-level objects

Object Body

  • facematchTransactionID <string>

  • facematchSuccess <boolean>

  • livenessSuccess <boolean>

  • capturedImage <base64-string>

hmacDataList <list>
  • serviceID: face_match

  • hmacDigest <string>

  • rawResponse <string>

Instance Responses

Success

  • vidvLivenessResult <object>

CapturedActions

capturedActions <object>
  • id <int>

  • action <string>

  • faceSample <base64-string>

  • status <boolean>

capturedAction contains the images captured of the user's face during the SDK experience

UserExit

  • vidvLivenessResult <sub-object>

  • step <string>

Note: step <string> identifies the point where the user chose to exit the SDK

ServiceFailure

  • errorCode <int>

  • errorMessage <string>

  • vidvLivenessResult <object>

BuilderError

  • errorCode <int>

  • errorMessage <string>

PreviousImplementation GuideNextiOS Native SDK

Last updated 6 months ago

The raw response in hmacDataList should be mapped to the result object as per the

HMAC Validation Documentation