SwiftGoma.SwiftGoma

Search endpoints

Jump to any API endpoint by name, method, or path

Two-Factor (TOTP)

Start 2FA setup

POST/api/v1/auth/totp/setup

Generates a new TOTP secret and QR code to scan into an authenticator app. Not yet enabled until confirmed with POST /totp/confirm.

Requires Authorization
Authenticated action
Request
curl --request POST \
  --url https://api.swiftgoma.com/api/v1/auth/totp/setup \
  --header 'Authorization: Bearer <access_token>'
200Example response
{
  "success": true,
  "data": {
    "secret": "JBSWY3DPEHPK3PXP",
    "otpauthUrl": "otpauth://totp/SwiftGoma:aline@example.com?secret=JBSWY3DPEHPK3PXP&issuer=SwiftGoma",
    "qrCodeDataUrl": "data:image/png;base64,iVBORw0KGgoAAAANS..."
  }
}