Send and verify one-time passwords by SMS. Use for login, 2FA, and transaction confirmation with one API.
Authenticate users securely using Dojahโs OTP service.
This API enables you to send time-bound one-time passwords to usersโ phone numbers,
then validate the code when they submit it. Itโs ideal for login, signup,
transaction confirmation, and two-factor authentication (2FA).
Send OTP
Make a POST request to the send-otpendpoint with the userโs phone number. A 6-digit code is generated and sent via SMS using your registered Sender ID.
User Inputs OTP
The user enters the code they received.
Validate OTP
Make a POST request to the validate-otpendpoint with the phone number and the code. If valid and not expired, youโll receive a success response.
Each OTP is valid for a limited time and can only be used once. You can also set your preferred OTP expiration time and resend behavior.