Back to Documentation

WhatsApp Business Integration

Connect a WhatsApp Business (Cloud API) number so your AgentPro chatbot answers customers on WhatsApp, with hand-off to human agents in the Inbox.

Prerequisites

Before you begin, make sure you have the following:

  • Meta Business Account

    A Meta Business account (business verification is needed before you can message real customers at scale)

  • WhatsApp Business Phone Number

    A phone number not linked to a personal WhatsApp account. The free Meta test number works for trials.

  • Meta Developer App

    A Meta Developer App of type "Business" with the WhatsApp product added

  • An AgentPro chatbot

    The chatbot that will answer WhatsApp messages. A chatbot is required to create the channel.

Step-by-Step Setup

1Create a Meta Developer App

  1. 1Go to Meta for Developers
  2. 2Click My Apps → Create App
  3. 3Select Business as the app type
  4. 4Fill in your app details and click Create App

2Add WhatsApp Product

  1. 1In your app dashboard, click Add Product
  2. 2Find WhatsApp and click Set Up
  3. 3Select your Meta Business Account or create a new one

3Get API Credentials

  1. 1Navigate to WhatsApp → API Setup and copy the Phone Number ID and WhatsApp Business Account ID (numeric IDs, not the phone number)
  2. 2Create a permanent token: Business Settings → Users → System Users → Add, assign your app, then Generate token with the whatsapp_business_messaging and whatsapp_business_management permissions
  3. 3Copy the App Secret from App Dashboard → App settings → Basic. AgentPro uses it to verify webhook signatures, so it is required.

Important: The temporary token shown on the API Setup page expires after 24 hours. Use a System User token in production; AgentPro warns you if the token you enter has an expiry date.

4Configure in AgentPro

  1. 1Go to Dashboard → Channels → WhatsApp and click I Have My Credentials
  2. 2Enter the Access Token, Phone Number ID, Business Account ID and App Secret, and pick the chatbot that should answer
  3. 3Click Connect WhatsApp. AgentPro verifies the credentials with Meta and shows the Callback URL and a Verify Token it generated for you

5Configure Webhook in Meta

  1. 1In Meta Developer Console, go to WhatsApp → Configuration
  2. 2Under Webhook, click Edit
  3. 3
    Enter the Callback URL from your AgentPro channel page (it contains your channel id):
    https://agentpro.chat/api/v1/webhooks/whatsapp/<your-channel-id>
  4. 4Paste the Verify Token shown on the AgentPro channel page (it is generated by AgentPro; you do not choose it) and click Verify and save
  5. 5Click Manage and subscribe to the messages field. Back in AgentPro, the channel shows Webhook verified; use Test Connection to confirm

Features

AI Auto-Response

Text, button and list replies, captions and shared locations are answered by your chatbot using its knowledge base. Replies are formatted for WhatsApp and split when long.

Human Takeover

Voice notes, stickers, media without a caption and AI failures are flagged in the Inbox. When an agent replies, the AI pauses for that conversation.

Template Broadcasts

Send Meta-approved templates to opted-in contacts with rate limiting, delivery/read tracking and STOP handling.

Contacts & Interactive Messages

Every sender becomes a contact with tags and consent. Send reply-button, list and link-button messages inside the 24-hour window.

Troubleshooting

Webhook verification failing?

  • •Copy the Verify Token from the AgentPro channel page exactly; it is generated by AgentPro
  • •The Callback URL must be publicly reachable over HTTPS and contain your channel id
  • •Meta must receive a 200 response: check the API logs for "Webhook verification failed"

Messages not being received?

  • •Subscribe to the "messages" webhook field under Manage
  • •If the App Secret is wrong Meta webhooks are rejected with 403: re-enter it on the channel page
  • •Temporary tokens expire after 24 hours; the channel status turns to ERROR when Meta rejects the token
  • •With the test number only pre-registered recipients can message you

Bot not responding?

  • •A chatbot must be linked to the channel; check the "AI Bot & Template" card
  • •If an agent replied from the Inbox, the AI is paused for that conversation until re-enabled
  • •Voice notes, stickers and media without a caption are routed to the Inbox instead of the AI
  • •A contact who replied STOP or who is blocked gets no AI replies

Cannot send a message?

  • •Free-form messages are only allowed within 24 hours of the customer's last message; otherwise send an approved template
  • •Broadcasts only reach contacts marked as opted in to marketing
  • •Templates must be approved in Meta Business Manager before they appear in the broadcast picker

Need Help?

Our support team is here to help you set up your WhatsApp integration.

Contact Support