Skip to content

Confirm an MFA enrolment

POST
/v1/mfa/enrollment/{enrollment_id}/confirm/

Confirms the enrolment with a code from the app or the SMS, and ends the trusted devices of the user.

Authorization

apiKey
headerAuthorizationBasic <token>

HTTP Basic authentication with your API key or the id of a token as the username and an empty password.

Path Parameters

enrollment_id*string

The id from the start of the enrolment.

Request Body

application/json
  1. body
otp*string

The one-time password from the app or the SMS.

Response Body

The method is active. Each recovery code works once, instead of an MFA code.

application/json
  1. response
recovery_codes?array<string>
curl -X POST 'https://api.example.com/v1/mfa/enrollment/string/confirm/' \  --user "$API_KEY:" \  -H 'Content-Type: application/json' \  -d '{  "otp": "654321"}'
{  "recovery_codes": [    "8ddad24b6d82608d",    "4b44f3c53ef34f2b",    "feab6f7f031dfeb0"  ]}