Skip to content

Totp Verify

POST
/api/v1/auth/totp/verify
curl --request POST \
--url https://example.com/api/v1/auth/totp/verify \
--header 'Content-Type: application/json' \
--data '{ "code": "example" }'

Confirm a pending TOTP secret with a current code — enables 2FA.

Answers with the first set of recovery codes, shown only this once.

Media typeapplication/json
TOTPVerifyRequest
object
code
required
Code
string
>= 6 characters <= 10 characters

Example generated

{
"code": "example"
}

Successful Response

Media typeapplication/json
RecoveryCodesOut

A freshly generated set of one-time recovery codes, shown once.

object
recovery_codes
required
Recovery Codes
Array<string>

Example generated

{
"recovery_codes": [
"example"
]
}

Validation Error

Media typeapplication/json
HTTPValidationError
object
detail
Detail
Array<object>
ValidationError
object
loc
required
Location
Array
msg
required
Message
string
type
required
Error Type
string
input
Input
ctx
Context
object

Example generated

{
"detail": [
{
"loc": [
"example"
],
"msg": "example",
"type": "example",
"input": "example",
"ctx": {}
}
]
}