2FA Setup Explorer
Generate secret and QR code to enable 2FA.
POST
/auth/account/2fa/setupDescription
Generate 2FA secret and QR code. Returns base32 secret, QR code image (base64), and verification token.
Parameters
Responses
2003 Response
Two-factor authentication generated successfully - Returns secret, QR code, and token.
401 Unauthorized
Unauthorized - Valid JWT token required in Authorization header.
Test Request
https://www.swapbits.site/api
curl -X POST "https://www.swapbits.site/api/auth/account/2fa/setup" \
-H "Content-Type: application/json"