Creates an instance of the MfaRecoveryCodeChallenge screen.
Static
screenContinues with the provided recovery code.
The recovery code entered by the user.
Optional
payload: Classes.CustomOptionsOptional payload.
import MfaRecoveryCodeChallenge from '@auth0/auth0-acul-js/mfa-recovery-code-challenge';
const mfaRecoveryCodeChallengeManager = new MfaRecoveryCodeChallenge();
const handleContinueEnrollment = async () => {
try {
await mfaRecoveryCodeChallengeManager.continue('YOUR_RECOVERY_CODE');
} catch (error) {
console.error('Error continuing with recovery code:', error);
}
}
Navigates to the screen where the user can pick another MFA method.
Optional
payload: Classes.CustomOptionsOptional payload.
import MfaRecoveryCodeChallenge from '@auth0/auth0-acul-js/mfa-recovery-code-challenge';
const mfaRecoveryCodeChallengeManager = new MfaRecoveryCodeChallenge();
const switchAuthenticator = async () => {
try {
await mfaRecoveryCodeChallengeManager.tryAnotherMethod();
console.log('Switched to another authentication method.');
} catch (error) {
console.error('Error switching authenticator:', error);
}
};
Class implementing the MFA Recovery Code Challenge screen functionality.