Skip to main content

MFAStatus

Package: @nauth-toolkit/client Type: Response

User's multi-factor authentication status including enabled methods, preferred method, and exemption status.

import { MFAStatus } from '@nauth-toolkit/client';

Properties

PropertyTypeDescription
enabledbooleanWhether MFA is enabled for the user
requiredbooleanWhether MFA is required (enabled and has configured devices)
methodsMFADeviceMethod[]Configured MFA device methods (excludes 'backup')
availableMethodsMFAMethod[]Available MFA methods including 'backup' if enabled
hasBackupCodesbooleanWhether user has backup codes available
preferredMethodMFADeviceMethod?Preferred MFA method (device methods only, excludes 'backup')
mfaExemptbooleanWhether user is exempt from MFA requirements
mfaExemptReasonstring | nullReason for MFA exemption (if exempt)
mfaExemptGrantedAtDate | string | nullTimestamp when exemption was granted (if exempt)

Example

{
"enabled": true,
"required": true,
"methods": ["totp", "sms"],
"availableMethods": ["totp", "sms", "backup"],
"hasBackupCodes": true,
"preferredMethod": "totp",
"mfaExempt": false,
"mfaExemptReason": null,
"mfaExemptGrantedAt": null
}

Used By