Skip to content

STEPS

Normalized journey step ids on JourneyEvent response.journeyStepId. Read them from cordova.tsido.STEPS.

A custom or unrecognized journey action is passed through as its raw identifier.

Members

MemberValue
SUCCESS"success"
REJECTION"rejection"
INFORMATION"information"
DEBUG_BREAK"debugBreak"
WAIT_FOR_ANOTHER_DEVICE"waitForAnotherDevice"
DRS_TRIGGER_ACTION"drsTriggerAction"
IDENTITY_VERIFICATION"identityVerification"
REGISTER_DEVICE_ACTION"registerDeviceAction"
VALIDATE_DEVICE_ACTION"validateDeviceAction"
WEB_AUTHN_REGISTRATION"webAuthnRegistration"
WEB_AUTHN_TRANSACTION_SIGNING"webAuthnTransactionSigning"
NATIVE_BIOMETRICS_REGISTRATION"nativeBiometricsRegistration"
NATIVE_BIOMETRICS_AUTHENTICATION"nativeBiometricsAuthentication"
NATIVE_BIOMETRICS_TRANSACTION_SIGNING"nativeBiometricsTransactionSigning"
DELETE_MOBILE_BIOMETRICS"deleteMobileBiometrics"
SELFIE_ACQUISITION"selfieAcquisition"
EMAIL_OTP_AUTHENTICATION"emailOTPAuthentication"
SMS_OTP_AUTHENTICATION"smsOTPAuthentication"
GENERIC_OTP_AUTHENTICATION"genericOTPAuthentication"
OTP_VALIDATION"otpValidation"
EMAIL_VALIDATION"emailValidation"
SMS_VALIDATION"smsValidation"
TOTP_REGISTRATION"totpRegistration"
TOTP_SIGNING_TRANSACTION"totpSigningTransaction"
PIN_CODE_REGISTRATION"pinCodeRegistration"
PIN_CODE_AUTHENTICATION"pinCodeAuthentication"
PIN_CODE_TRANSACTION_SIGNING"pinCodeTransactionSigning"
PIN_CODE_DELETION"pinCodeDeletion"
AUTHENTICATION"authentication"

Steps that need another SDK

This plugin carries the challenge and accepts the result. It does not produce passkey, biometric, or TOTP credentials. Reaching one of these steps without the matching SDK leaves the journey on that step. Answer with fail so the journey can take its failure branch.

StepSDK
webAuthnRegistration, webAuthnTransactionSigningAuthentication
nativeBiometricsRegistration, nativeBiometricsAuthentication, nativeBiometricsTransactionSigning, deleteMobileBiometricsAuthentication
totpRegistration, totpSigningTransactionAuthentication
selfieAcquisition, identityVerificationIdentity Verification SDK
drsTriggerActionFraud Prevention

OTP, PIN code, device registration and validation, information, rejection, debug break, and cross-device wait need only this plugin.

Usage

async function onStep(response) {
  switch (response.journeyStepId) {
    case cordova.tsido.STEPS.SUCCESS:
      console.log(response.token, response.code);
      break;
    case cordova.tsido.STEPS.REJECTION:
      console.log(response.data);
      break;
    case cordova.tsido.STEPS.INFORMATION:
      cordova.tsido.submitClientResponse(cordova.tsido.RESPONSE_OPTIONS.CLIENT_INPUT, {});
      break;
    case cordova.tsido.STEPS.WEB_AUTHN_REGISTRATION: {
      const { result } = await cordova.tsauth.registerWebAuthn(response.data.username);
      await cordova.tsido.submitClientResponse('clientInput', { webauthn_encoded_result: result });
      break;
    }
    default:
      break;
  }
}