Verify API - Register a new device with Push Verify
NOTE:
To add this product to your account, contact a Telesign expert. This product is available for full-service accounts only.
This page explains step-by-step how to register a user's new device with Push Verify, so they can use it to approve pushes later when logging in on your website.
This procedure assumes that each step in the flow is successful and that the device has not already been registered for Push Verify.
These instructions also assume the use of a verification policy with:
- Push Verify set as the primary verification method.
- SMS one-time passcode (OTP) set as the fallback verification method.
Before you begin
- Review Verify API - Get started and its key terms for Verify API.
- Install the Telesign Verify Android SDK or Telesign Verify iOS SDK, depending on your specific needs. Contact Telesign Customer Support or your Telesign contact to get access.
- Implement Verify API and Verify Mobile SDK to your website as well as to your mobile app. This is required in order for Push Verify to work successfully.
Steps
Telesign Verify Android SDK
- The USER downloads, installs, and opens your mobile app (APP) with Telesign SDK.
- APP uses TSVerify.init(context = this) to initialize the SDK.
- APP subscribes to SDK Events: TSVerify.getEventsFlow().
- APP uses isDeviceRegisteredStamp() to check with the SDK if the device is registered yet for Stamp (Push and QR) Verify. Here, we assume it is not registered yet:
TSVerify.isDeviceRegisteredStamp() - APP requests a push_app_token from the FirebaseSDK using FirebaseSDK.getToken().
- APP initiates the registration process through your CUSTOMER BACKEND server by sending the phone number of the user who wants to register a new device, along with the device's push_app_token.
- Your CUSTOMER BACKEND receives a MOBILE_APP_TOKEN for registration from VERIFY API and returns it to APP.
- APP uses the activate method with the MOBILE_APP_TOKEN to begin the registration process:
TSVerify.activate(mobileAppToken: String) - Verify API sends verification code through one of the preconfigured channels (usually is SMS but can be WhatsApp, email, or others).
- SDK emits the ExpectsOTP event so APP can prompt USER to enter the OTP.
- USER enters OTP into the APP.
- APP generates an app ID, using this format: com.{app name}:{app version number}. For example: 
com.your.app:1.2.0
- APP calls the finalizeRegistrationStamp method of the SDK with phone number, app ID, and the entered OTP to finalize registration.
- Verify API checks the asserted OTP against the original OTP. If they match, TELESIGN sends a response to the SDK indicating that the validation was successfully completed.
- If everything is correct, SDK emits the registrationCompleted event.
- The IsDeviceRegisteredStamp method should return true now:
TSVerify.isDeviceRegisteredStamp() - APP is ready to be used for Push and QR Verification.
Telesign Verify iOS SDK
- USER downloads, installs, and opens your mobile app (APP) with Telesign SDK.
- APP uses:  TSVerify() to initialize the SDK.
- APP subscribes to SDK Events: let events = TSVerify.shared.getEventsStream()
- APP uses isDeviceRegisteredStamp() to check with the SDK if the device is registered for Stamp (Push and QR) Verify yet. Here, we assume it is not registered yet:
TSVerify.shared.isDeviceRegisteredStamp() - APP requests a push_app_token from the FirebaseSDK using FirebaseSDK.getToken().
- APP initiates the registration process through your CUSTOMER BACKEND server by sending the phone number of the user who wants to register a new device, along with the device's push_app_token.
- Your CUSTOMER BACKEND receives a MOBILE_APP_TOKEN for registration from VERIFY API and returns it to APP.
- APP uses the activate method with the MOBILE_APP_TOKEN to begin the registration process:
TSVerify.shared.activate(mobileAppToken: String) - Verify API sends verification code through one of the preconfigured channels (usually is SMS but can be WhatsApp, email, or others).
- SDK emits the ExpectsOTP event so APP can prompt USER to enter the OTP.
- USER enters OTP into the APP.
- APP generates an app ID, using this format: com.{app name}:{app version number}. For example: 
com.your.app:1.2.0
- APP calls the finalizeRegistrationStamp method of the SDK with phone number, app ID, and the entered OTP to finalize registration.
- Verify API checks the asserted OTP against the original OTP. If they match, TELESIGN sends a response to the SDK indicating that the validation was successfully completed.
- If everything is correct, SDK emits the registrationCompleted event.
- The IsDeviceRegisteredStamp method should return true now:
TSVerify.shared.isDeviceRegisteredStamp() - APP is ready to be used for Push and QR Verification.
Updated 3 days ago