Before you begin this process, read and complete the pre-requisites in the WhatsApp Tech Provider Program overview.
The Twilio WhatsApp onboarding team is here to guide you through the process. Reach out for help using the same support ticket created after you submitted the WhatsApp Tech Provider Program request form.
In November 2024, Meta introduced several improvements to the Tech Provider Program and the onboarding process for Twilio ISVs. As a result, this guide has been updated to support these changes.
Due to Meta's changes with the App Review process for Tech Providers, Parts 1 and 2 below no longer require engineering to build a prototype of your Embedded Signup integration. Code changes are only required for the technical integration outlined in Part 3.
You will need to register as a Meta Developer if you haven't created a Meta app before. See Meta's Register as a Meta Developer documentation for more information.
It's recommended to start with a new Meta app (even if you already have another Meta app). If you already have another Meta app, there is little benefit to reusing it unless you already have completed the WhatsApp Tech Provider process for another BSP or with Meta directly.
The name of your Meta app, in addition to the name of your business portfolio, will be shown to your clients when onboarding using Embedded Signup. Don't include Meta's trademarks, such as WhatsApp, in the app name.
Under the Scale your Business section, there is a Become a Tech Provider card. Click Start Onboarding. Please note that by doing so, you will be accepting Meta's Tech Provider Terms and any other associated terms from Meta.
Even though you are working with Twilio, on the next screen, please select Independent Tech Provider, as Twilio doesn't publish our Meta app ID externally.
Navigate to App settings > Basic page using the navigation on the left-side of the page.
Here, you should add the following information:
Your App Icon, which can be the same as your company's logo. This will be visible to your customers when onboarding to WhatsApp.
A URL to your company's privacy policy. These will also be available to your customers when onboarding to WhatsApp.
A category that best represents your app or business.
whatsapp_business_management
permission.If you're having trouble finding the whatsapp_business_management
permission, try using your browser's 'Find' feature (Ctrl+F or Cmd+F) rather than Meta's search bar.
The page has two different tables of permissions with very little to distinguish them apart.
Click on either Request advanced access or Edit App Review request depending on what is displayed.
In the modal that is displayed, answer Yes to "Are you creating an integration to enable multiple business clients to manage their own Facebook data? (e.g., a Saas platform or a chatbot for multiple business clients)"
You will then be taken to the App Review > Requests page. Scroll down to the bottom of the Request for App Review page, there you will find the Data Handing questions section. Click on the arrow to answer the data handling questions.
Meta will require you to:
Neither Twilio nor Meta can provide guidance on completing this section for your organization. Please consult legal, policy and data handling experts within your organization for guidance on how to answer these questions.
Next, review your app settings, and fill in any missing information.
If you need to change your app icon, privacy policy, or category after submission, additional Meta approvals may be required.
The final step prior to submitting for app approval is providing your "app verfication details".
You should have already added a platform in the Configure app details section above.
We are applying to become a WhatsApp Tech Provider. We will be submitting videos for the whatsapp_business_management permission. We will be working with Twilio who already has whatsapp_business_messaging permission and won't be sending messages with the Meta API.
Meta has two different permissions for WhatsApp Tech Provider which should have automatically been added to your app:
whatsapp_business_messaging
- Since you will be using Twilio's APIs to send and receive WhatsApp messages—rather than Meta's—you do not need this permission
whatsapp_business_management
- This allows your app and business to manage the WhatsApp Business Accounts (WABAs) created and owned by your customers within Meta's WhatsApp Manager UI
whatsapp_business_messaging
permission?, click on the trash can icon to remove the whatsapp_business_messaging
permission from your app review request.If you don't remove the whatsapp_business_messaging
permission, you will need to create an additional video showing how your app sends and receives WhatsApp messages. Since it's not required to use Twilio's APIs and there is no added benefit to have this permission, Twilio can't assist if you get rejected for the whatsapp_business_messaging
permission.
Click the card asking How will your app use the advanced access whatsapp_business_management
permission? to fill in details about your application.
In the first box, explain how your business utilizes the WhatsApp Business Platform.
Next, you will need to create a screen recording creating a WhatsApp template with either the Twilio Console using the Content Template Builder or within Meta's WhatsApp Manager. If you use the Twilio Console, you can use the account where you onboarded your own company's brand using WhatsApp Self Sign-up. Omit audio as Meta's reviewers won't listen to it.
Return to your browser window with app review and upload the screen recording.
Check the box, and click Save.
Finally, click Submit for Review.
Let Twilio know that you have submitted your App to Meta. Twilio is here to help you along the way and we want to know how it's going!
Once Meta has reviewed your App, you will receive an email and Alert in your Meta App Dashboard. Go to Alerts > Inbox and review the submission results.
Once your Meta app is approved, you will need to complete Meta's Access Verification to verify that your business is a Tech Provider. You can do this in your App Dashboard by navigating to App Settings > Basic. There you should see an option to complete Access Verification. Fill out the steps below and submit. Meta typically takes 5 business days to review this, but if it's taking longer than expected, please inform Twilio to escalate it on your behalf.
Congratulations on getting all of the Meta approvals completed!
In order to continue, Meta requires a Partner Solution which lets Meta know that you are working with Twilio, and gives Twilio permission to access your customers WABAs when they onboard within your website or app.
If you haven't already, you will need to copy your Meta app ID shown in the top of your App Dashboard and send this to Twilio's channels onboarding team using the support ticket created when you requested access to the Tech Provider Program.
Wait 1-2 business days for the channels onboarding team to send you the Partner Solution request. Once sent, you will be notified via the support ticket. You will also receive an email from Meta directly.
If you are a new customer to Twilio and haven't previously onboarded customers to WhatsApp, you can skip the section and move to Part 3.
If you had previously used either the Guided Onboarding process or WhatsApp Self Sign-up to onboard your customers to WhatsApp, Twilio will need to add those WABAs to the new Partner Solution that was just created.
The channel operations team should notify you that they need to update your existing customers' WABAs at this time. If they don't, please indicate that you need to add your Partner Solution to your existing customers' WABAs.
When Twilio initiates the request, Meta will send an email to the admins of your customers business portfolio that is connected to the WABA.
If you need to notify your customers first, so that they're expecting an email, please indicate this to the channels onboarding team. Twilio will give you 7 days before initiating the request. If you need more time, please talk to your account manager.
Once your customers accept this request from Twilio in their Meta business portfolio, they will be able to see the WABA and have full access to it within the Meta UI — even if it was onboarded via the Guided Onboarding where they have never had access to it.
It's important to set the expectation with your customers that they should not make any changes to their WABA — including templates, or phone numbers within the WABA — unless explicitly requested by you and/or Twilio. This is to prevent with syncing changes to Twilio's platform.
Finally, when you complete Step 3 below, your customers will be able to use your application to onboard additional WhatsApp Senders if desired.
Once Twilio initiates the WABA request, your customers will have 90 days to accept the request before Meta will accept it automatically.
Until you complete Part 3, you can still onboard new WhatsApp Senders using the existing process. However, you will only be able to onboard new customers until you complete Part 3.
It's almost time to code, but first we need to do additional technical setup within your Meta app.
First, familiarize yourself with the onboarding flow that your customers will follow:
Your customers will choose the phone number that they wish to use on WhatsApp (unless you assign numbers automatically). The WhatsApp Tech Provider Program supports both Twilio phone numbers and non-Twilio phone numbers (i.e. bringing your own phone number, or BYON) on WhatsApp, but it's up to you on what you expose to your customers. Note: this needs to happen before the Embedded Signup popup window, so that you can get the full phone number required by the Senders API, as Meta doesn't return the full phone number.
Your customers will click the "Login with Facebook" button within your UI and the Embedded Signup popup window will launch.
In the popup window, they will follow Meta's Embedded Signup flow and complete the following:
As the Embedded Signup popup window is entirely controlled by Meta, know that Meta may make changes to this flow without Twilio's involvement. Please see Meta's Embedded Signup documentation for the most up-to-date screenshots.
We will start with completing the integration with Meta's Embedded Signup feature by adding a "Login to Facebook" button into your front-end. Then, we'll move to the backend where we will need to take the information returned when your customers complete the front-end flow, and call the Senders API to register the phone number by creating a WhatsApp Sender in your Twilio subaccount that's assigned to your customer.
In order to set up your Embedded Signup integration, Meta requires you to first create what they call a "login configuration". This is where you will use the whatsapp_business_management
permission that you requested during Meta app review. This allows your customers to login to their Facebook account and select or create their Meta business portfolio and WABA and then share it with your app and business.
Don't switch to "Facebook Login". Only "Facebook Login for Business" is accepted.
In this section, assign a name to your configuration—for example, you can call this "Embedded Signup Integration". This name will not be visible to your customers. After you've entered a name, select Next.
In the login variation section, select the WhatsApp Embedded Signup option and click Next.
Choose Access Token: This section refers to your Meta Graph API access token. Since you are working with Twilio and using Twilio's APIs and won't be calling Meta's Graph API directly, you don't need to worry about this page and can use the recommended option. Select the recommended 60 days option and click Next.
Under the Assets section, make sure the WhatsApp accounts option is selected.
Twilio has not tested selecting additional asset types here, so if you do, proceed with caution.
Verify the whatsapp_business_management
permission has been added before you finalize the configuration. Since you are working with Twilio's APIs, you don't need to add other permissions, so don't add other permissions to reduce potential for errors later on during the integration.
Click Create and save the Configuration ID that Meta provides. You will need this when adding the JavaScript code for Embedded Signup to your website.
In order for Embedded Signup to function correctly, we will need to make some updates to your Facebook Login for Businesses settings.
For security purposes, Meta doesn't allow the Facebook SDK to be loaded on any website not using HTTPS. As a result, we recommend using ngrok or a similar tool to expose your localhost externally where it can be served using HTTPS. Alternatively, if your company has a developer environment that uses HTTPS, that would also work.
Add your website's domain(s) into both Valid OAuth Redirect URIs and Allowed Domains for the JavaScript SDK. These URIs need to be served using HTTPS, and can only be static, and not dynamic URLs that use a wildcard.
Make sure to click Save changes.
One final step before you begin coding. When your Meta app's App Mode is set to Development as it's by default, then only users that have been added to your Meta app can access it. Otherwise, an error will be shown. Before moving into Production, you will need to update your App Mode to be set to Live (at the top of the App Dashboard)
To add additional developers and testers to your Meta app:
Alright, now it's finally time to code, so get your coding gloves ready!!
Meta's Embedded Signup feature requires the Facebook SDK to be loaded on the page where it is surfaced. it's not required to surface it on every page within your website.
<body>
tag on the page you intend to add the "Login with Facebook" button. Make sure you replace the value with your App ID.1<script>2window.fbAsyncInit = function() {3FB.init({4appId: 'APP_ID', // Replace with your Meta app ID5autoLogAppEvents: true,6xfbml: true,7version: 'v21.0' // Latest version when this doc was published8})9};10</script>11<script async defer crossorigin="anonymous" src="https://connect.facebook.net/en_US/sdk.js"></script>
1<button onclick="launchEmbeddedSignup()" style="background-color: #1877f2; border: 0; border-radius: 4px; color: #fff; cursor: pointer; font-family: Helvetica, Arial, sans-serif; font-size: 16px; font-weight: bold; height: 40px; padding: 0 24px;">2Login with Facebook3</button>
launchEmbeddedSignup
function as defined below which will open the Embedded Signup popup window.Make sure to replace the placeholder values with your Configuration ID and Partner Solution ID.
1// Handle WhatsApp Embedded Signup2function launchEmbeddedSignup() {3// Launch Facebook login4FB.login(5function (response) {6// Since you are using Twilio's APIs, you do not need to do anything with the response here.7},8{9config_id: "KEEP_IN_QUOTES_BUT_REPLACE_WITH_YOUR_CONFIG_ID",10auth_type: "rerequest", // Avoids 'user is already logged' in errors if users click the button again before refreshing the page11response_type: "code",12override_default_response_type: true,13extras: {14sessionInfoVersion: 3, // Required to get WABA ID15setup: {16solutionID: "KEEP_IN_QUOTES_BUT_REPLACE_WITH_YOUR_SOLUTION_ID" // This is the Partner Solution ID17}18}19}20);21}
As the Embedded Signup popup window is entirely controlled by Meta, know that Meta may make changes to this flow without Twilio's involvement. Please see Meta's Embedded Signup documentation for the most up-to-date screenshots.
1// Define session handler2const embeddedSignupInfoListener = (event) => {3if (!event.origin.endsWith("facebook.com")) return;4try {5const data = JSON.parse(event.data);6if (data.type === 'WA_EMBEDDED_SIGNUP') {78// if user finishes the Embedded Signup flow9if (data.event === 'FINISH' || data.event === "FINISH_ONLY_WABA") {10const {phone_number_id, waba_id} = data.data;11console.log("Phone number ID ", phone_number_id, " WhatsApp business account ID ", waba_id);1213// if user cancels the Embedded Signup flow14} else if (data.event === 'CANCEL') {15const {current_step} = data.data;16console.warn("Cancel at ", current_step);1718// if user reports an error during the Embedded Signup flow19} else if (data.event === 'ERROR') {20const {error_message} = data.data;21console.error("error ", error_message);22}23}24} catch {25console.log('Non JSON Responses', event.data);26}27};282930// Listen for Embedded Signup events31window.addEventListener("message", embeddedSignupInfoListener);3233// When the user navigates away from the page, remove the event listener34window.addEventListener ("beforeunload" , () =>35window.removeEventListener ("message", embeddedSignupInfoListener);36);
console.log
statement for now, we'll come back to it.It's a good time now to test the Embedded Signup flow.
To make sure your Partner Solution (solutionID
) is working correctly, you should notice that when you go through Embedded Signup, it displays that your company is working with Twilio to enable your customers on WhatsApp during the pop-up window flow. This is required by Meta's legal team, and can't be removed.
When testing the Embedded Signup flow, Meta restricts that the Meta business portfolio that you used to create your Meta app can't be selected within the Embedded Signup flow.
As a result, we recommend creating an additional Meta business portfolio using your company name (e.g. "Twilio Test") and providing legitmate business details. To avoid dealing with Meta's phone number and WABA limit restrictions when testing, Twilio also recommends submitting it for business verification.
Using the default Embedded Signup configuration, when the Embedded Signup window opens, your customers will do the following:
However, if you've purchased Twilio SMS-capable phone numbers for your customers to use with WhatsApp, it's against Twilio policy to display OTPs within your account. As a result, Twilio's Senders API will handle steps 3 and 4 automatically when you make the API call to create the WhatsApp Sender and you need to turn off those steps within Embedded Signup.
If you are using a combination of Twilio SMS-capable phone numbers, as well as Twilio voice-only numbers or non-Twilio numbers (i.e. BYON), then you will need to configure Embedded Signup conditionally based on the type of phone number the client business choose.
To configure Embedded Signup to not prompt your customers to provide a phone number and skip those steps, update where you make your FB.login call to include featureType: 'only_waba_sharing'
like so:
1// Handle WhatsApp Embedded Signup2function launchEmbeddedSignup() {3// Launch Facebook login4FB.login(5function (response) {6// Since you are using Twilio's APIs, you do not need to do anything with the response here.7},8{9config_id: "KEEP_IN_QUOTES_BUT_REPLACE_WITH_YOUR_CONFIG_ID",10auth_type: "rerequest", // Avoids "user is already logged" in errors if users click the button again before refreshing the page11response_type: "code",12override_default_response_type: true,13extras: {14sessionInfoVersion: 3, // Required to get WABA ID15// set the following "featureType" to 'only_waba_sharing'16// if and only if using a Twilio SMS-capable number, otherwise17// do not include it or set it to null18featureType: 'only_waba_sharing',19setup: {20solutionID: "KEEP_IN_QUOTES_BUT_REPLACE_WITH_YOUR_SOLUTION_ID", // This is the Partner Solution ID21}22}23}24);25}
Meta has a feature that allows you to add in details about the customer's business if you have already collected that information. This can speed up the onboarding process for your customers.
Customers can still edit the data that you prefill, if necessary.
Review Meta's documentation and make sure you thoroughly test any changes. Also, remember that the Embedded Signup feature is provided by Meta and not Twilio, and our support teams may not always be able to assist when troubleshooting the Embedded Signup integration.
Finally, note how Meta only returns the phone_number_id
when the user completes the Embedded Signup flow:
1const embeddedSignupInfoListener = (event) => {2if (!event.origin.endsWith("facebook.com")) return;3try {4const data = JSON.parse(event.data);5if (data.type === 'WA_EMBEDDED_SIGNUP') {67// if user finishes the Embedded Signup flow8if (data.event === 'FINISH' || data.event === "FINISH_ONLY_WABA") {9const {phone_number_id, waba_id} = data.data;10console.log("Phone number ID ", phone_number_id, " WhatsApp business account ID ", waba_id);1112// if user cancels the Embedded Signup flow13} else if (data.event === 'CANCEL') {14const {current_step} = data.data;15console.warn("Cancel at ", current_step);1617// if user reports an error during the Embedded Signup flow18} else if (data.event === 'ERROR') {19const {error_message} = data.data;20console.error("error ", error_message);21}22}23} catch {24console.log('Non JSON Responses', event.data);25}26};
The Twilio Senders API requires a phone number in E.164 format. As a result, if you are allowing your customers to choose the phone number—no matter the type—they wish to register on WhatsApp, you will need to collect it from your customers outside of the Embedded Signup flow. This can be done prior to launching the Embedded Signup flow or after, as long as it is collected before making the call to the Twilio Senders API.
Once you have the WABA ID from the embeddedSignupInfoListener
function and the phone number in E.164 format, pass these parameters to your backend to register the WhatsApp Sender.
Don't make any of the following or other Twilio API calls involving a Twilio AuthToken
on the front end of your application, where you implemented the Embedded Signup feature.
When your customer onboards to WhatsApp for the first time, they will create a new WABA as Part of the Embedded Signup flow. Each WABA needs to be connected to seperate Twilio subaccounts.
Once your customer already has a WABA using your Embedded Signup integration, they should reuse the same WABA when onboarding additonal WhatsApp Senders (e.g. phone numbers).
Each WABA can only be mapped to a single account or subaccount. You must keep track of each business or brand and have each onboarded onto a dedicated subaccount. WhatsApp doesn't allow senders from different businesses to be registered in the same WABA.
If you're not already familiar with Twilio subaccounts, you can learn more in the Accounts API docs.
FriendlyName
with your customer's company name. Use your main Twilio account (e.g. parent account) credentials to make this request.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 createAccount() {11const account = await client.api.v2010.accounts.create({12friendlyName: "Owl, Inc.",13});1415console.log(account.authToken);16}1718createAccount();
1{2"auth_token": "auth_token",3"date_created": "Thu, 30 Jul 2015 20:00:00 +0000",4"date_updated": "Thu, 30 Jul 2015 20:00:00 +0000",5"friendly_name": "Owl, Inc.",6"owner_account_sid": "ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",7"sid": "ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",8"status": "active",9"subresource_uris": {10"available_phone_numbers": "/2010-04-01/Accounts/ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/AvailablePhoneNumbers.json",11"calls": "/2010-04-01/Accounts/ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Calls.json",12"conferences": "/2010-04-01/Accounts/ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Conferences.json",13"incoming_phone_numbers": "/2010-04-01/Accounts/ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/IncomingPhoneNumbers.json",14"notifications": "/2010-04-01/Accounts/ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Notifications.json",15"outgoing_caller_ids": "/2010-04-01/Accounts/ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/OutgoingCallerIds.json",16"recordings": "/2010-04-01/Accounts/ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Recordings.json",17"transcriptions": "/2010-04-01/Accounts/ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Transcriptions.json",18"addresses": "/2010-04-01/Accounts/ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Addresses.json",19"signing_keys": "/2010-04-01/Accounts/ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/SigningKeys.json",20"connect_apps": "/2010-04-01/Accounts/ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/ConnectApps.json",21"sip": "/2010-04-01/Accounts/ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/SIP.json",22"authorized_connect_apps": "/2010-04-01/Accounts/ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/AuthorizedConnectApps.json",23"usage": "/2010-04-01/Accounts/ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Usage.json",24"keys": "/2010-04-01/Accounts/ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Keys.json",25"applications": "/2010-04-01/Accounts/ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Applications.json",26"short_codes": "/2010-04-01/Accounts/ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/SMS/ShortCodes.json",27"queues": "/2010-04-01/Accounts/ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Queues.json",28"messages": "/2010-04-01/Accounts/ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Messages.json",29"balance": "/2010-04-01/Accounts/ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Balance.json"30},31"type": "Full",32"uri": "/2010-04-01/Accounts/ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa.json"33}
AccountSid
and AuthToken
will be returned in the response. Save this in your database to use for this customer. You will also use these credentials in the next step when calling the Twilio Senders API to register your customer's phone numbers on WhatsApp.sender_id
: provide the phone number that you are registering in E.164 format.waba_id
: provide the WABA ID if this is the first number for the customer. This will connect it to the subaccount. Note that once a WABA ID has been mapped to a subaccount, it will stay connected unless all WhatsApp Senders have been deleted from the account. You don't need to provide it when registering additional Senders in the same subaccount.callback_url
, callback_method
, fallback_url
, fallback_method
, and status_callback_url
: these webhooks are used for inbound messages and message statuses (not for the Sender's status). Note that status callbacks only support HTTP POST
.profile.name
is only required when using a Twilio SMS-capable number, otherwise Twilio will use the one provided by your customer during the Embedded Signup flow and ignore this field. Even when testing, this must comply with Meta's WhatsApp display name guidelines.1## Create Sender2curl -X "POST" "https://messaging.twilio.com/v2/Channels/Senders" \3-H "Content-Type: application/json; charset=utf-8" \4-u "$TWILIO_ACCOUNT_SID:$TWILIO_AUTH_TOKEN" \5-d $'{6"sender_id": "whatsapp:+15017122661",7"configuration": {8"waba_id": "12345678912345"9},10"profile": {11"address": "101 Spear Street, San Francisco, CA",12"emails": [13"support@twilio.com"14],15"vertical": "Other",16"logo_url": "https://www.twilio.com/logo.png",17"description": "We\'re excited to see what you build!",18"about": "Hello! We are Twilio.",19"name": "Twilio",20"websites": [21"https://twilio.com",22"https://help.twilio.com"23]24},25"webhook": {26"callback_method": "POST",27"callback_url": "https://demo.twilio.com/welcome/sms/reply/"28}29}'
1{2"status": "CREATING",3"sender_id": "whatsapp:+15017122661",4"sid": "XEXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX",5"configuration": {6"waba_id": "12345678912345"7},8"profile": {9"about": "Hello! This is Twilio's official account.",10"name": "Twilio",11"vertical": "Other",12"websites": [13{14"website": "https://twilio.com",15"label": "Website"16},17{18"website": "https://help.twilio.com",19"label": "Website"20}21],22"address": "101 Spear Street, San Francisco, CA",23"logo_url": "https://www.twilio.com/logo.png",24"emails": [25{26"email": "support@twilio.com",27"label": "Email"28}29],30"description": "We're excited to see what you build!"31},32"webhook": {33"callback_method": "POST",34"callback_url": "https://demo.twilio.com/welcome/sms/reply/"35},36"url": "https://messaging.twilio.com/v2/Channels/Senders/XEXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX",37"properties": null38}
The Senders API registers WhatsApp Senders asynchronously. When you make the POST
call above to create the WhatsApp Sender, the Sender's SID will be returned. WhatsApp Sender SIDs will start with XE
.
To check if the WhatsApp Sender has been successfully registered and is online, make a request to fetch the WhatsApp Sender's current status:
1## Fetch Sender2curl -X "GET" "https://messaging.twilio.com/v2/Channels/Senders/XEXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX" \3-H "Content-Type: application/json; charset=utf-8" \4-u "$TWILIO_ACCOUNT_SID:$TWILIO_AUTH_TOKEN"
1{2"status": "ONLINE",3"sender_id": "whatsapp:+15017122661",4"sid": "XEXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX",5"configuration": {6"waba_id": "12345678912345"7},8"profile": {9"about": "Hello! This is Twilio's official account.",10"name": "Twilio",11"vertical": "Other",12"websites": [13{14"website": "https://twilio.com",15"label": "Website"16},17{18"website": "https://help.twilio.com",19"label": "Website"20}21],22"address": "101 Spear Street, San Francisco, CA",23"logo_url": "https://www.twilio.com/logo.png",24"emails": [25{26"email": "support@twilio.com",27"label": "Email"28}29],30"description": "We're excited to see what you build!"31},32"webhook": {33"callback_method": "POST",34"callback_url": "https://demo.twilio.com/welcome/sms/reply/"35},36"url": "https://messaging.twilio.com/v2/Channels/Senders/XEXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX",37"properties": {38"messaging_limit": "1K Customers/24hr",39"quality_rating": "HIGH"40}41}
ONLINE
, you can then use Twilio's APIs to send and receive messages.It's time to move into production and onboard your first customer! Make sure that you set your App Mode to Live in your Meta App Dashboard and that your production URLs have been added to your Meta app in your app's Facebook Login for Business settings section.
Congrats! Don't forget to let the Twilio WhatsApp onboarding team know you successfully completed the flow, so they can close out your ticket.
Now that you have completed the integration, here are some other must reads when building your WhatsApp integration using Twilio.