Skip to content

Confirm 2FA enrollment

POST
/api/2fa/confirm

Verifies a code from the authenticator app, enables 2FA, and returns single-use recovery codes (shown once).

Authorizations

ApiToken

Long-lived API token created via POST /api/api-tokens (returned once in plaintext).

Type
API Key (header: X-API-TOKEN)
or
JWT

JWT access token obtained via POST /api/auth/login. Send as: Authorization: Bearer .

Type
HTTP (bearer)

Request Body

application/json
JSON
{
  
"code": "123456"
}

Responses

Recovery codes (shown once)

application/json
JSON
{
  
"recoveryCodes": [
  
  
[
  
  
  
"abcde-12345",
  
  
  
"f6g7h-89012"
  
  
]
  
]
}

Playground

Authorization
Body

Samples

Powered by VitePress OpenAPI