Herald
OpenapiUser

Verify TOTP setup and enable two-factor authentication

Completes the TOTP setup process by verifying the TOTP code generated from the secret. On successful verification, TOTP is enabled for the user account.

POST
/api/user/totp/verify

Completes the TOTP setup process by verifying the TOTP code generated from the secret. On successful verification, TOTP is enabled for the user account.

Authorization

bearer_auth
AuthorizationBearer <token>

In: header

Request Body

application/json

TypeScript Definitions

Use the request body type in TypeScript.

code*string
tempToken*string

Response Body

application/json

application/json

application/json

curl -X POST "https://example.com/api/user/totp/verify" \  -H "Content-Type: application/json" \  -d '{    "code": "string",    "tempToken": "string"  }'
{  "enabledAt": "string",  "message": "string"}
{  "code": "string",  "details": null,  "message": "string",  "requestId": "string",  "status": 0}
{  "code": "string",  "details": null,  "message": "string",  "requestId": "string",  "status": 0}