Capture Live Selfie

Start User Live Selfie Capture

In the backend, call the Create New Operation Endpoint with the following request body (example):

{  
  "AccountNumber": "AccountV2",  
  "Codeword": "",  
  "Name": "GetForeignBiometry",  
  "Timeout": 3600,  
  "TransportType": 0,  
  "Tag": ""  
} 

The AccountNumber must match the value the user specified during Account Creation

A transport type of 0 returns an OperationId and OneTimeSecret.

Example Response Body:

{  
   "OperationId": "113e838b-be34-53e9-c52f-3cc45b2d10ce",
   "OneTimeSecret": "TbAeETwpOxbvKy7rWCeOcQ=="  
}

Display the User Interface

Save these values from the response and use it to display the capture experience to the user.

The other options for TransportType parameter usage are described in the Out-of-band Transactions section.

Wait for the Completion of the Capture

When the user completes the selfie capture, the status changes from 0 - Pending to 1 - Accepted. Refer to the Transaction Statuses section for more details.

📘

Common Transaction Status

The Transaction Statuses are common between Enrollment, Capture and Authentication workflows.

The application has several ways to detect when the status changes.

  • Periodic poll of backend for Enrollment operation status change using Operation Status Endpoint
  • Embedded Integration can listen to Web Component Events for web integration or to JavaScript bridge events for WebView integration. The UI emits the signal that the user has reached the "final page" of the experience.

Please refer to the Web Component Events section for more details.

The best strategy from both a UX transition reaction time and system load perspective is to:

  • Listen to events from the Web Component / WebView.
  • When the user reaches the final page, pass the signal from your application frontend to your application's backend.
  • Confirm the status change via the backend Operation Status Endpoint.
  • As a backup, poll status changes periodically using Operation Status Endpoint, for example, once every 5 seconds.

Both Out-of-band and Embedded integrations can use Webhook to receive notifications when the status changes. Note that webhooks are not queued and do not have guaranteed delivery, so the periodic polling backup strategy still applies.


What’s Next