Skip to main content
MFA uses two Access Manager APIs:
  • Identity enrolls methods and manages the user’s MFA settings.
  • Auth completes the second verification step during sign-in.
Read Multi-factor authentication before you integrate these operations.

Account enrollment operations


The Identity API exposes these self-service operations: The standard operations are self-service. The bearer-token subject must match {id}.

Start setup

Send the method in the request body:
Request
This feature supports app and email. Authenticator-app setup returns a secret, a QR-code URL, and recovery codes. Email setup returns recovery codes and sends a passcode to the user’s saved email address.

Verify setup

Submit the 6–8-character setup passcode and the method. Authenticator-app verification also needs the secret returned by setup.
Request

Enable the method

After verification, enable the method with one recovery code from the setup response. Authenticator-app enablement also needs the setup secret.
Request
Treat setup secrets and recovery codes as credentials. Do not log them or store them in source control.

Login operations


The first factor uses Request Access Token. When MFA is required, the operation returns an MFA challenge response instead of access tokens. The response includes:
  • mfaRequired: true.
  • a short-lived mfaToken.
  • the enabled methods.
  • the preferred method.

Request email delivery

Use Initiate MFA Challenge for email.
Request
Do not request delivery for app. The authenticator app generates the passcode locally.

Verify the second factor

Use Verify MFA Login. Send either passcode or recoveryCode, not both.
Passcode
Recovery code
A successful verification returns the standard access-token response. A recovery code is consumed after one successful use.

Error handling


Important login errors include: Identity can also reject an unsupported method, missing setup secret, missing email destination, or unverified setup. See the Access Manager error list for the full error envelope and current codes.

Complete MFA in the Console

The user workflow for verification during sign-in.

Identity APIs

The generated reference for account-management operations.