performVerifyAuth

performVerifyAuth

🧭 Overview

The performVerifyAuth API is used when the user is trying to log in from a new device. This typically happens when the server detects the user is active on another device, but this current device isn't activated yet.

The SDK emits the addNewDeviceOptions event, which presents device activation options like a REL-ID Verify notification. If the user chooses this option, the app must invoke performVerifyAuth(true).


🎯 Purpose

  • 🔐 To activate a new device via REL-ID verify notification.
  • ✅ Enables seamless onboarding to a second device.
  • 🧭 Proceeds with activation if user approves notification on primary device.

📲 UI Screen Requirements

The app must display a verification info screen, summarizing the challenge received in addNewDeviceOptions.

Recommended layout includes:

  • Title: “Activate New Device”
  • Message from challengeInfo (e.g., “Approve the REL-ID notification on your registered device”)
  • ✅ Button: “Proceed with Notification”
  • ❌ Button: “Cancel” (calls performVerifyAuth(false) or fallback flow)

🔁 API: performVerifyAuth(status)

📥 Parameters

NameTypeRequiredDescription
verifyAuthStatusBooleantrue to proceed, false to cancel

💻 Code Snippets

React Native
RdnaClient.performVerifyAuth(true, (syncResponse) => {
  console.log("VerifyAuth status:", syncResponse);
});
Flutter
rdnaClient.performVerifyAuth(true);
Cordova
com.uniken.rdnaplugin.RdnaClient.performVerifyAuth(
  () => console.log("Performed Verify Auth"),
  (err) => console.error("Error:", err),
  [true]
);
Native Android
RDNAError error = rdna.performVerifyAuth(true);
Native iOS
[client performVerifyAuth:YES];

📩 Event: addNewDeviceOptions

Sample Payload:

{
  "userID": "testuser",
  "newDeviceOptions": ["REL-ID Verify Authentication"],
  "challengeInfo": [
    { "key": "Response label", "value": "Approve notification on your other device" },
    { "key": "description", "value": "You must verify using a registered device." },
    { "key": "SDK_CHLNG", "value": "NO" },
    { "key": "SDK_CHLNG_MODE", "value": "NA" },
    { "key": "AUTO_ANSWER", "value": "true" }
  ]
}

🔑 Relevant Fields

FieldDescription
userIDThe current user trying to activate this device
newDeviceOptionsOptions such as "REL-ID Verify Authentication"
challengeInfoContains UI content for display and challenge config

❗ Error Handling


✅ On Success

  • App proceeds to LDA consent (getUserConsentForLDA) or password (getPassword) based on device capability.

❌ On Failure

  • App may fall back to fallbackNewDeviceActivationFlow()
  • Show error toast and guide user to retry or contact support.