User/2 F A
User two-factor authentication (TOTP) endpoints.
Authorization
user-access-token User access token. In Apidog use token value {{user_access_token}}.
In: header
Header Parameters
Environment override (use "test" to bypass payload encryption)
"test"Client timezone
"UTC"Client device type/details
"ios"Client language/locale preference
"en"Response Body
application/json
curl -X GET "https://example.com/api/user/2fa/v1/status" \ -H "env: test" \ -H "timezone: UTC" \ -H "device: ios" \ -H "Accept-Language: en" \ -H "Authorization: Bearer {{user_access_token}}"{ "code": "string", "response": { "enabled": true, "method": "string", "recoveryCodesRemaining": 0 }}Authorization
user-access-token User access token. In Apidog use token value {{user_access_token}}.
In: header
Header Parameters
Environment override (use "test" to bypass payload encryption)
"test"Client timezone
"UTC"Client device type/details
"ios"Client language/locale preference
"en"Response Body
application/json
curl -X POST "https://example.com/api/user/2fa/v1/totp/setup" \ -H "env: test" \ -H "timezone: UTC" \ -H "device: ios" \ -H "Accept-Language: en" \ -H "Authorization: Bearer {{user_access_token}}"{ "code": "string", "response": { "setupId": "string", "issuer": "string", "accountName": "string", "otpauthUri": "http://example.com", "manualKey": "string", "expiresAt": "string" }}Authorization
user-access-token User access token. In Apidog use token value {{user_access_token}}.
In: header
Header Parameters
Environment override (use "test" to bypass payload encryption)
"test"Client timezone
"UTC"Client device type/details
"ios"Client language/locale preference
"en"Request Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
Response Body
application/json
curl -X POST "https://example.com/api/user/2fa/v1/totp/enable" \ -H "env: test" \ -H "timezone: UTC" \ -H "device: ios" \ -H "Accept-Language: en" \ -H "Authorization: Bearer {{user_access_token}}" \ -H "Content-Type: application/json" \ -d '{ "setupId": "f4709ab9-abc4-47f4-b2d4-4bb2be280931", "code": "string" }'{ "code": "string", "response": { "enabled": true, "recoveryCodes": [ "string" ] }}Authorization
user-access-token User access token. In Apidog use token value {{user_access_token}}.
In: header
Header Parameters
Environment override (use "test" to bypass payload encryption)
"test"Client timezone
"UTC"Client device type/details
"ios"Client language/locale preference
"en"Request Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
Response Body
application/json
application/json
curl -X POST "https://example.com/api/user/2fa/v1/disable" \ -H "env: test" \ -H "timezone: UTC" \ -H "device: ios" \ -H "Accept-Language: en" \ -H "Authorization: Bearer {{user_access_token}}" \ -H "Content-Type: application/json" \ -d '{ "code": "string" }'{ "code": "string", "message": "string"}Authorization
user-access-token User access token. In Apidog use token value {{user_access_token}}.
In: header
Header Parameters
Environment override (use "test" to bypass payload encryption)
"test"Client timezone
"UTC"Client device type/details
"ios"Client language/locale preference
"en"Request Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
Response Body
application/json
curl -X POST "https://example.com/api/user/2fa/v1/recovery_codes/regenerate" \ -H "env: test" \ -H "timezone: UTC" \ -H "device: ios" \ -H "Accept-Language: en" \ -H "Authorization: Bearer {{user_access_token}}" \ -H "Content-Type: application/json" \ -d '{ "code": "string" }'{ "code": "string", "response": { "enabled": true, "recoveryCodes": [ "string" ] }}Header Parameters
Environment override (use "test" to bypass payload encryption)
"test"Client timezone
"UTC"Client device type/details
"ios"Client language/locale preference
"en"Request Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
Response Body
application/json
curl -X POST "https://example.com/api/user/2fa/v1/login/verify" \ -H "env: test" \ -H "timezone: UTC" \ -H "device: ios" \ -H "Accept-Language: en" \ -H "Content-Type: application/json" \ -d '{ "code": "string" }'{ "code": "string", "response": { "accessToken": "string", "refreshToken": "string", "sessionId": "string", "user": { "_id": "string", "loginType": "email", "email": "string", "profile": { "name": "string", "locale": "en", "timezone": "utc", "currency": "usd" }, "twoFactor": {}, "onboardingCompleted": true } }}