Create an MFA verification for a user

POST /api/users/{userId}/mfa-verifications

Create a new MFA verification for a given user ID.

Path parameters

  • userId string Required

    The unique identifier of the user.

application/json

Body object Required

One of:

Responses

POST /api/users/{userId}/mfa-verifications
curl \
 -X POST https://[tenant_id].logto.app/api/users/{userId}/mfa-verifications \
 -H "Authorization: Bearer $ACCESS_TOKEN" \
 -H "Content-Type: application/json" \
 -d '{"type":"string","secret":"string"}'
{
  "type": "string",
  "secret": "string"
}
{
  "type": "string",
  "codes": [
    "string"
  ]
}
{
  "type": "string",
  "secret": "string"
}
{
  "type": "string",
  "codes": [
    "string"
  ]
}
Response examples (200)
{
  "type": "string",
  "secret": "string",
  "secretQrCode": "string"
}
{
  "type": "string",
  "codes": [
    "string"
  ]
}