Two-factor authentication and one-time passwords
Secure your applications with multi-channel OTP delivery. SMS, Email, Voice, WhatsApp, and TOTP support for comprehensive two-factor authentication.
Send one-time passwords via SMS. Automatic code generation, expiry, and verification.
POST /api/v1/otp/send
{ "phone": "+15551234567",
"template": "Your code is {code}",
"expires_in": 300 }
// Response
{ "otp_id": "otp_abc123",
"expires_at": "2024-01-19T12:05:00Z" }
Send verification codes via email. Branded templates with your company logo and colors.
POST /api/v1/otp/email
{ "email": "user@example.com",
"subject": "Verify your account",
"brand": "MyApp" }
// Response
{ "otp_id": "otp_def456" }
Verify submitted OTP codes. Automatic expiry checking and attempt limiting.
POST /api/v1/otp/verify
{ "otp_id": "otp_abc123",
"code": "123456" }
// Response
{ "valid": true,
"verified_at": "2024-01-19T12:03:00Z" }
Generate TOTP secrets for Google Authenticator, Authy, and other authenticator apps.
POST /api/v1/totp/generate
{ "user_id": "user_123",
"issuer": "MyApp" }
// Response
{ "secret": "JBSWY3DPEHPK3PXP",
"qr_code": "data:image/png;base64,..." }
Deliver OTP codes via automated phone call. Ideal for users without SMS or as fallback.
POST /api/v1/otp/voice
{ "phone": "+15551234567",
"language": "en-US",
"repeat": 2 }
// Response
{ "call_id": "call_abc123",
"status": "initiated" }
Send OTP via WhatsApp. Higher delivery rates in regions with low SMS reliability.
POST /api/v1/otp/whatsapp
{ "phone": "+15551234567",
"template": "otp_verification" }
// Response
{ "message_id": "wa_abc123",
"status": "sent" }
Get your API key and start securing users in minutes.