Skip to main content
The ResetPasswordMfaSmsChallenge class implements the reset-password-mfa-sms-challenge screen functionality. This screen prompts the user to enter the verification code sent to their phone via SMS as part of the MFA step during a password reset flow.

Constructors

Create an instance of ResetPasswordMfaSmsChallenge screen manager
Example
import ResetPasswordMfaSmsChallenge from '@auth0/auth0-acul-js/reset-password-mfa-sms-challenge';

const resetPasswordMfaSmsChallenge = new ResetPasswordMfaSmsChallenge();
await resetPasswordMfaSmsChallenge.continueMfaSmsChallenge({
  code: '123456',
});

Properties

Provides branding-related configurations, such as branding theme and settings.
Provides client-related configurations, such as id, name, and logoUrl, for the reset-password-mfa-sms-challenge screen.
Provides information about the user’s organization, such as organization id and name.
Contains data about the current prompt in the authentication flow.
Contains details specific to the reset-password-mfa-sms-challenge screen, including its configuration and context.
Contains data related to the tenant, such as id and associated metadata.
Provides transaction-specific data for the reset-password-mfa-sms-challenge screen, such as active identifiers and flow states.
Handles untrusted data passed to the SDK, such as user input during the MFA challenge flow.
Details of the active user, including username, email, and roles.

Methods

continueMfaSmsChallenge
(options ?)
This method submits the SMS verification code to continue the MFA challenge during the password reset flow.
Example
import ResetPasswordMfaSmsChallenge from '@auth0/auth0-acul-js/reset-password-mfa-sms-challenge';

const resetPasswordMfaSmsChallenge = new ResetPasswordMfaSmsChallenge();
await resetPasswordMfaSmsChallenge.continueMfaSmsChallenge({
  code: '123456',
});
options
OPTIONAL
Optional payload.
getACall
(options ?)
This method switches the user to voice call verification instead of SMS.
Example
import ResetPasswordMfaSmsChallenge from '@auth0/auth0-acul-js/reset-password-mfa-sms-challenge';

const resetPasswordMfaSmsChallenge = new ResetPasswordMfaSmsChallenge();
await resetPasswordMfaSmsChallenge.getACall();
options
OPTIONAL
Optional payload.
resendCode
(options ?)
This method resends the SMS verification code to the user’s phone.
Example
import ResetPasswordMfaSmsChallenge from '@auth0/auth0-acul-js/reset-password-mfa-sms-challenge';

const resetPasswordMfaSmsChallenge = new ResetPasswordMfaSmsChallenge();
await resetPasswordMfaSmsChallenge.resendCode();
options
OPTIONAL
Optional payload.
resendManager
This method provides resend functionality with timeout management. It returns a ResendControl object with a startResend() method that triggers the resend and enforces a cooldown period before the user can resend again.
Example
import ResetPasswordMfaSmsChallenge from '@auth0/auth0-acul-js/reset-password-mfa-sms-challenge';

const resetPasswordMfaSmsChallenge = new ResetPasswordMfaSmsChallenge();
const { startResend } = resetPasswordMfaSmsChallenge.resendManager({
  timeoutSeconds: 15,
  onStatusChange: (remainingSeconds, isDisabled) => {
    console.log(`Resend available in ${remainingSeconds}s, disabled: ${isDisabled}`);
  },
  onTimeout: () => {
    console.log('Resend is now available');
  }
});

// Call startResend when user clicks resend button
startResend();
options
OPTIONAL
Optional payload.
tryAnotherMethod
(options ?)
This method allows the user to select a different MFA method to complete the challenge.
Example
import ResetPasswordMfaSmsChallenge from '@auth0/auth0-acul-js/reset-password-mfa-sms-challenge';

const resetPasswordMfaSmsChallenge = new ResetPasswordMfaSmsChallenge();
await resetPasswordMfaSmsChallenge.tryAnotherMethod();
options
OPTIONAL
Optional payload.
getErrors
This method retrieves the array of transaction errors from the context, or an empty array if none exist.