Verify WhatsApp Overview
Verify WhatsApp helps your business verify users by delivering One-Time Passcodes (OTPs) via WhatsApp messages with your brand, adding to Verify's existing channels for OTP delivery. WhatsApp has more than 2 billion users and works over a Wi-Fi connection. Adding it as an OTP channel can boost your conversion rate and reduce costs. WhatsApp doesn't charge for undelivered messages and isn't exposed to telecom-network fraud, such as toll fraud.
If you're already using Verify SMS for OTP delivery, we can configure your account to first attempt delivery via WhatsApp for specific countries. If WhatsApp delivery fails, Verify will automatically send an SMS. You don't need to change your UI as long as it refers to SMS and WhatsApp collectively as generic messages. This Verify WhatsApp to SMS Optimal Channel Selection feature is currently in a Pilot phase with limited availability. Contact sales to request access.
- Create a new Verify Service or use an existing one.
- Start a verification with WhatsApp, by specifying
Channel=whatsapp(instead ofChannel=sms). See code sample. - Check the verification as you would for any other channel.
1// Download the helper library from https://www.twilio.com/docs/node/install2const twilio = require("twilio"); // Or, for ESM: import twilio from "twilio";34// Find your Account SID and Auth Token at twilio.com/console5// and set the environment variables. See http://twil.io/secure6const accountSid = process.env.TWILIO_ACCOUNT_SID;7const authToken = process.env.TWILIO_AUTH_TOKEN;8const client = twilio(accountSid, authToken);910async function createVerification() {11const verification = await client.verify.v212.services("VAaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa")13.verifications.create({14channel: "whatsapp",15to: "+15017122661",16});1718console.log(verification.accountSid);19}2021createVerification();
Response
1{2"sid": "VEaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",3"service_sid": "VAaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",4"account_sid": "ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",5"to": "+15017122661",6"channel": "whatsapp",7"status": "pending",8"valid": false,9"date_created": "2015-07-30T20:00:00Z",10"date_updated": "2015-07-30T20:00:00Z",11"lookup": {},12"amount": null,13"payee": null,14"send_code_attempts": [15{16"time": "2015-07-30T20:00:00Z",17"channel": "whatsapp",18"attempt_sid": "VLaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa"19}20],21"sna": null,22"url": "https://verify.twilio.com/v2/Services/VAaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Verifications/VEaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa"23}
Watch the following video to learn how we added WhatsApp as another verification option in our Twilio Authy Android mobile app.
Verify WhatsApp works like Verify SMS, except for the following channel-specific differences:
- Bring your own WhatsApp Sender (a WhatsApp phone number associated with a WhatsApp Business Account).
- WhatsApp is not available to use for Verify in China. For a comprehensive list, see WhatsApp Availability by Country.
- No blocking (for example, block from sending a message to X country code).
- No routing (for example, WhatsApp is the only "carrier").
- No support for PSD2, pre-approved, or custom templates.
Over the last few years, WhatsApp has emerged as a major messaging channel. With over 2 billion users across 180 countries, it's fast achieving ubiquity. Every WhatsApp user is identified by a unique phone number that they provided when creating their WhatsApp account. This means that WhatsApp can directly replace SMS for all verification use cases, including sign-up, login, and transaction.
When we added WhatsApp as another channel to send OTPs in our Authy app's sign-up/login flow, we saw strong user adoption. We were sending about 2,000 WhatsApp messages per day globally. Adoption was particularly strong in heavy WhatsApp countries like Brazil, India, Indonesia, and Germany. In these countries, 20-40% of users picked the WhatsApp option. Adding WhatsApp also resulted in a higher overall conversion rate. It works on Wi-Fi when there is no cell connection to receive SMS. WhatsApp also doesn't charge for messages that aren't delivered. Lastly, WhatsApp is a modern, IP-based network that isn't exposed to fraud that exploits the telecom network, such as toll fraud, also known as traffic pumping. We saw this firsthand with Authy: SMS conversion rates dropped sharply in one country for a week because of toll fraud. However, WhatsApp conversion rates remained stable.
To use Verify WhatsApp, you need to first provide us with your WhatsApp Sender. Once this configuration step is done, it's only a one-word change to the API request if you're familiar with the Verify API for sending SMS OTPs. Switch the Channel parameter from sms to whatsapp. The generated OTP code is the same, so a user can use the code they receive from either WhatsApp or SMS if they requested both.
Effective March 1, 2024, you must bring your own brand and phone number (Sender) to send WhatsApp OTP messages. Customers previously using Verify WhatsApp's "generic sender" need to bring their own WhatsApp Sender to comply with Meta's WhatsApp business messaging policy.
If your use case is OTP delivery, then we strongly recommend Verify. It can intelligently orchestrate OTP delivery between WhatsApp, SMS, RCS and other channels to maximize conversion and reduce cost. In a single phone number verification session, the same OTP code that's generated by Verify is sent across all channels, simplifying code validation.
Additionally, we auto-create authentication message templates in multiple languages that you can use with your own brand. These templates provide end users with a copy code button to enhance their experience. Contact sales to discuss how these benefits apply to you.
Based on our experience with our Authy app, we found that the following best practices improved the likelihood that a user completes the verification after choosing to receive an OTP message via WhatsApp (aka Conversion Rate):
-
If the user is using your mobile app, you can check that the user also has WhatsApp installed on the same device before displaying the "send message via WhatsApp" option. For more information, see the What we learned from adding WhatsApp verification to the Authy App blog post.
Checking if WhatsApp is installed avoids scenarios where you might have set up a WhatsApp phone number at some point but can't immediately receive messages on the device. However, you might have WhatsApp installed on a different device, so this check might exclude some users unnecessarily. In our experience, this affects a small percentage of users.
-
Have the user confirm that they entered their phone number correctly, to avoid sending the OTP message to the wrong person.
-
We've observed that "stock Android" phones are able to retrieve OTP codes directly from English-language WhatsApp messages and push it to your user while they are still in your app. Take advantage of this by making it easy to copy/paste the code into your UI.
Verify orchestrates OTP delivery across WhatsApp, SMS, RCS, and other channels to maximize conversion and reduce cost. Verify also saves you setup time by auto-creating templates for you in multiple languages using the new Copy Code authentication templates.
Customers using Verify WhatsApp with their own Sender are subject to Meta's Messaging limits.
Use a single sender for OTP messages to provide a consistent user experience and maximize your sender messaging limits. However, if your business uses a single sender for marketing purposes, you need to take into account that users may block a marketing message. This could result in them not receiving OTP messages sent by you.