Passkey Challenge
Overview
The Passkey User Consent Challenge is presented by the application when the REL-ID SDK requires user consent to perform a passkey operation. The SDK initiates the challenge and hands control to the app via a callback; the app is responsible for showing a consent UI and relaying the user's decision back to the SDK.
🧩 What is the Passkey Challenge?
The Passkey Challenge is a Ditto SDK's authentication step that leverages the platform's native FIDO2/WebAuthn passkey capability (Face ID, Touch ID, fingerprint, or device PIN) instead of a traditional password or OTP.
It is not a challenge where the user types something it is a consent gate followed by a platform biometric/credential operation managed by the OS (Apple's ASAuthorization framework on iOS, FIDO2 credential manager on Android).
It is triggered via the getUserConsentForPasskey event.
🔄 When Is It Triggered?
The SDK fires this challenge in two scenarios, indicated by the passkeyOp parameter:
| RDNAPasskeyOperation | Value | Scenario |
|---|---|---|
| RDNA_PASSKEY_OP_REGISTER | 0 | During device activation the SDK wants to register a passkey credential for the user |
| RDNA_PASSKEY_OP_AUTHENTICATE | 1 | During login / authentication — the SDK wants to use a previously registered passkey to authenticate |
🧠 What the App Must Do
When the getUserConsentForPasskey method is triggered by the SDK, the app must:
- App must implement this delegate/callback method.
- Show consent UI to the user based on passkeyOp. For the passkeyOp for
RDNA_PASSKEY_OP_AUTHENTICATEyou can silently callsetUserConsentForPasskey()with value true. - Submit it using
setUserConsentForPasskey()
getUserConsentForPasskey Event
getUserConsentForPasskey Event📥 Sample Payload – getUserConsentForPasskey
getUserConsentForPasskey
{
"userID" : "sktest",
"challengeMode" : 1,
"passkeyOp" : 0,
"error" : {
"longErrorCode" : 0,
"shortErrorCode" : 0,
"errorString" : "Success"
}
}🧾 Top-Level Fields
| Field | Description |
|---|---|
userID | Unique identifier for the user being challenged |
challengeMode | Challenge handling mode |
| passkeyOp | Passkey Operation mode for either register or authenticate |
| error | Error object |
Updated 6 days ago
