Skip to main content

Register TOTP

This API generates a QR code and secret key that allows the user to register their authenticator app (e.g., Google Authenticator, Authy) for TOTP-based second-factor authentication.

🔑Header Parameters

HeaderTypeDescriptionExample
x-api-keystringAPI key for authorization{{x-api-key}}

📦Request Body Schema

FieldTypeRequiredDescriptionExample/ENUM
user_idstringYesUnique Client Code (UCC) assigned to the user"UCC123456"
otpstringYesThe Temporary token from Verify OTP API"{{forgot_password_token}}"
api_keystringYesThe API key provided by SynapseWave for authentication.x-api-key
app_namestringNoThe name of the app to be set in the Authenticator apps (Default: "Registered in system")."Wave 3.0"
sourcestringYesThe source of the user request: WEBAPI (for web applications), MOBILEAPI (for mobile applications)."MobileAPI"

🟢Success Response - 200 OK

FieldTypeDescriptionExample
statusstringIndicates the status of the API call"success"
codestringInternal Response code"s-101"
messagestringA message confirming successful TOTP registration."QR Code Generated"
dataobjectContains the TOTP details necessary for registration.See below Data object info

📘 Data Object Field Info

FieldTypeDescriptionExample
qrImgstringBase64 or URL string of the TOTP QR image to be scanned."data:image/png;base64,... or <a class="external-link" href="https://example.com/totp.png" rel="nofollow">https://example.com/totp.png</a>"
authSecretstringTOTP setup key (secret) to be manually entered if needed."JBSWY3DPEHPK3PXP"
userIDstringThe User ID (UCC) for whom the TOTP was registered."UCC123456"
👉 Next Step : Verify TOTP

📱 Scan the QR code and add the account to your authenticator app.

✅ Then call Verify TOTP to:

  • Confirm that TOTP codes are being generated correctly.