Skip to content

Get Own MFA Setting

GET
/api/v1/users/self/mfa
curl --request GET \
--url https://api.spartanauth.com/api/v1/users/self/mfa

Returns whether the signed-in user requires a second factor on their own sign-ins. enforcedByPolicy is true when the platform or the sector already requires MFA, and the account control is hidden. enabled is that user’s opt-in. Passkey and social sign-in are unchanged. Existing sessions stay valid.

A successful response.

Media type application/json

OwnMFASetting is the signed-in user’s MFA opt-in. Platform and sector requirements win. The profile flag can only add a requirement.

object
enforcedByPolicy

True when the platform or the sector already requires a second factor.

boolean
enabled

The user’s own opt-in. A false value does not turn off a platform or sector requirement.

boolean
Example generated
{
"enforcedByPolicy": true,
"enabled": true
}

An unexpected error response.

Media type application/json
object
code
integer format: int32
message
string
details
Array<object>
object
@type
string
key
additional properties
Example generated
{
"code": 1,
"message": "example",
"details": [
{
"@type": "example"
}
]
}