Skip to main content
Class implementing the Mfa Recovery Code Enrollment screen functionality. This screen is displayed when the user needs to enroll with a recovery code for MFA.
Example
import MfaRecoveryCodeEnrollment from '@auth0/auth0-acul-js/mfa-recovery-code-enrollment';
const mfaRecoveryCodeEnrollmentManager = new MfaRecoveryCodeEnrollment();
const continueEnrollment = async (payload) => {
 try {
   await mfaRecoveryCodeEnrollmentManager.continue(payload);
   console.log('Enrollment continued successfully.');
 } catch (error) {
   console.error('Error continuing enrollment:', error);
 }
};

Constructors

MfaRecoveryCodeEnrollment
Constructor
Creates an instance of the MfaRecoveryCodeEnrollment screen.

Properties

branding
client
organization
prompt
screen
tenant
transaction
untrustedData
user
screenIdentifier
string

Methods

continue
Promise<void>
Declares that the user saved the recovery code. This action is triggered when the user declares that they have saved the recovery code. It redirects to the next screen in the authentication flow.A promise that resolves when the action is successfully submitted.
Example
import MfaRecoveryCodeEnrollment from '@auth0/auth0-acul-js/mfa-recovery-code-enrollment';
const mfaRecoveryCodeEnrollmentManager = new MfaRecoveryCodeEnrollment();
const continueEnrollment = async (payload) => {
 try {
   await mfaRecoveryCodeEnrollmentManager.continue(payload);
   console.log('Enrollment continued successfully.');
 } catch (error) {
   console.error('Error continuing enrollment:', error);
 }
};
Rejects with an error if the submission fails.
getErrors
Retrieves the array of transaction errors from the context, or an empty array if none exist.An array of error objects from the transaction context.