Tools & integrations / WhatsApp
Ready

WhatsApp integration

Connect a WhatsApp Business number with Meta Embedded Signup. Messages to that number are routed to the connected bot, and the bot replies on WhatsApp.

What's included

- Embedded Signup to link a WhatsApp Business number to a bot.

- Capture phone_number_id, WABA ID, display phone, access token, and two-step verification PIN.

- Auto-subscribe the webhook, register the phone, and store the PIN for future deregistration.

- Incoming WhatsApp messages reach the bot; the bot's text response is sent back to WhatsApp.

- Recent conversations (last 30 minutes) with the same sender reuse the same thread for context.

- All conversations stay in the free support window and no templates are used, so the channel is fully free.

Prerequisites & config

Bring these to the signup flow (no billing setup required):

  • A Facebook account.
  • A Facebook Business Account (you can create one during the Embedded Signup flow).
  • A WhatsApp phone number to connect.
Connect your number (Embedded Signup)
  1. Open the bot dashboard and go to the WhatsApp tab.
  2. Click Launch Embedded Signup to open Meta's popup.
  3. Select a Business Account and choose an existing number or create a new one.
  4. Finish Meta's setup guide so it returns the verification code and phone_number_id.
  5. Raian exchanges the code for a business token, subscribes the webhook to your WABA, registers the phone, and stores the PIN for later deregistration.
  6. The status card shows phone_number_id, WABA ID, display number, webhook subscription time, registration time, and connection time.
How messaging works

- Webhook: Meta posts to our webhook; we verify with a verify token and the app secret signature when present.

- Routing: Your phone number ID maps to the bot that connected it. If the sender has an active conversation in the last 30 minutes, that thread is reused for context.

- Bot call: the incoming text is sent to the bot via the non-stream endpoint; text replies up to 4096 characters are sent back to WhatsApp with link previews off.

- Delivery: responses are sent as WhatsApp text messages. Unsupported inbound message types are skipped with a log entry.

Test the flow
  1. From a personal WhatsApp account, send a message to the connected number.
  2. Confirm you receive a bot reply on WhatsApp; recent conversations reuse context within 30 minutes.
  3. Check Dashboard → Logs for the inbound message and reply details.
  4. If no reply arrives, confirm the WhatsApp tab shows the number registered and the token not expired; retry registration if Meta was rate limited.
Disconnect or rotate credentials

- Use Disconnect WhatsApp to deregister the phone and unsubscribe the webhook; the stored PIN is sent to Meta.

- If Meta cannot deregister automatically, finish removal in WhatsApp Manager with the same PIN.

- To refresh an expired token, rerun Embedded Signup; the existing number is reused.

- You can also remove the app from Meta directly at connected apps.

Troubleshooting

- Popup blocked: allow popups for the dashboard domain and retry.

- Token expired or revoked: reconnect through Embedded Signup to issue a fresh access token.

- No replies: verify webhook token and ensure the phone shows as registered; retries may be needed if Meta rate limited registration.

- If the number already had a PIN, disable two-step authentication at WhatsApp Manager → Phone numbers, then reconnect.

- Need a full reset: disconnect in Raian, then remove the app or unshare the WABA in WhatsApp Manager, or remove it from connected apps.

Next up

Monitor logs and jobs to debug messages and imports.

Continue to Conversation logs →