Skip to main content

Using Webview Client

WebView SDK Client is crafted specially for you if you choose the easy integration and implementation. As stated on previous documentation, you still need to implement webSocket client to receive the face recognitation status update.

Take a minute to read about our WebSocket Registration doc before continue.

Webview Base URL

There are two webview URLs, one for enrolling and the other for verify :

Webview Parameter

Our webview client need to know who is accesing our service. So you need to inform following variable as url parameter query :

  • liveness_app_key
    • Pass your liveness_app_key on every request
  • subject_id
    • This value is unique for each user of your client. Sample : if you want to enroll face for a person or user with the name "safira", pass "safira" as subject_id value.

Final URL

Lets take a look of the following sample, you have the following variable like this :

  • liveness_app_key = abcopopnomi-jklois-77sera
  • subject_id = safiradwi

The final URL will be looks like this

enrolling new user or client face
https://beoty.beoverflow.com/saas/liveness/face/enroll?liveness_app_key=abcopopnomi-jklois-77sera&subject_id=safiradwi
verifying user or client face
https://beoty.beoverflow.com/saas/liveness/face/verify?liveness_app_key=abcopopnomi-jklois-77sera&subject_id=safiradwi

WebSocket Connection

Please make sure you use the same subject_id as event name you listened / bind, with the one used by webview client query parameter.

caution

Failed to subscribe or listening to websocket will causing you to not receiving any face recognization status update from beoty.

To help you with debugging websocket client connection, we has dedicated websocket client check, click here to open the websocket client helper.

On the helper page, you just need to inform your liveness_app_key and your subject_id. If you entered liveness_app_key correctly, you can use enroll function and verify function. Please don't close the websocket client helper. As soon as you complete the face recognitation you will receive response on the websocket client helper page.

Make sure you are received websocket event response with the same structure as described at : Event Response