Phone verification proves that a user controls the number they gave you. With the VerifyWay API, the code arrives in WhatsApp from a verified business profile instead of an SMS inbox. This guide shows the flow, what the user sees, and the request you send.
The verification flow in four steps
- Your server creates a code, for example
482916, and stores it with an expiry time. - Your server sends it to VerifyWay with the user's phone number.
- The user receives it in WhatsApp and types it into your app.
- Your server compares what the user typed with the code it stored.
VerifyWay delivers the code. It does not create or check it, so verification stays fully under your control.
What the user sees
- A message from a verified business profile, using Meta's standard authentication template.
- A Copy code button, so users don't mistype the code.
- The message in their language: English, Arabic, Portuguese (Brazil), German, Russian, Azerbaijani, Kazakh or French.
Send the code
curl -X POST 'https://api.verifyway.com/api/v1' \
-H 'Authorization: Bearer YOUR_API_KEY' \
-H 'Content-Type: application/json' \
-H 'Idempotency-Key: signup-otp-001' \
-d '{
"recipient": "+9647701234567",
"type": "otp",
"channel": "whatsapp",
"code": "482916",
"lang": "ar"
}'
Send the code as a string so leading zeros are kept. HTTP 200 means the request was accepted; store the message_id and wait for the delivery status on your webhook. The same request in Node.js, PHP, Python, C#, Java and Go is in the API documentation.
Good practice
- Keep the API key on your server. Never put it in browser or mobile app code.
- Retry safely. After a timeout, repeat the same request with the same
Idempotency-Key, so the user does not get two codes. - One code per number every 30 seconds. Faster requests to the same number are rejected.
- Add a backup channel. With
"fallback": "yes", users without WhatsApp get the code on Telegram. See automatic fallback.
Security in plain terms
The code travels inside WhatsApp, encrypted in transit, and comes from a verified business name rather than a sender ID anyone can imitate. It avoids SMS problems such as carrier filtering and SMS pumping fraud. As with any OTP, keep codes short-lived and never log them in full.
What it costs
You pay Meta's rate for the recipient's country plus a fixed $0.01, only for delivered messages. For example: Iraq $0.0200, United Kingdom $0.0320, India $0.0404. See every country on the pricing page.
Frequently asked questions
Do I need my own WhatsApp Business account?
No. VerifyWay sends from its verified business profile, so you can start the same day.
What if the user has no WhatsApp?
The attempt fails and is refunded. With fallback enabled, the code goes to Telegram instead.
How do I know the code was delivered?
Your webhook receives delivered, read, failed and expired statuses, and the dashboard shows them under Message logs.
Send your first OTP today
Top up from $10, get your API key and send a code in minutes.
Create account