Documentation / WhatsApp
BUILD

WhatsApp

Connect your customer-owned Meta setup, import approved templates, and send with recorded permission.

1. Prepare your Meta setup

Your business owns its Meta app, WhatsApp Business Account (WABA), and phone numbers. Have the app ID, app secret, access token with appropriate messaging and management access, WABA ID, and phone number ID ready. Your approved Notifications plan must include WhatsApp and enough connected-number capacity. Meta bills its messaging charges directly to you; platform subscription charges are separate.

2. Connect the account

Open WhatsApp in the dashboard and choose Connect Meta account. Give the connection a recognizable label and enter your Meta credentials and IDs. Access is checked before the connection is saved. Add a separate connection for each customer-owned Meta app. You can rotate credentials, disable or re-enable a connection, and enable or disable individual numbers from its card. Re-enabling a connection does not automatically enable its numbers. Keep the active number count within your plan allowance; after a downgrade, disable extra numbers to resume sending. App secrets and access tokens are never returned to the browser after saving.

3. Configure the Meta callback

The connection result shows a callback URL and a verify token. In your Meta app’s WhatsApp configuration, enter both, verify the callback, and subscribe to message events. The verify token is displayed only once; save it securely. If it is lost, choose Reset verify token on the connection card and repeat the Meta verification handshake; the previous token stops working. Inbound requests are validated with the Meta app secret. Configure your workspace’s signed webhooks to receive replies and status events in your own application. Notifications forwards inbound replies; it does not provide a chat inbox. If an event fails, resolve the connection error and choose Retry failed events to queue it again without skipping it.

4. Sync and map templates

Choose Sync from Meta to import the account’s current numbers and templates. Templates are created and approved in Meta. Open a synced template to inspect its components, parameter schema, and variable aliases, then use example values to preview the message. Only approved templates associated with the selected sending number’s account can be used. Template status and fingerprint are checked again before dispatch.

5. Record channel-specific consent

Open Audience & consent to record an explicit customer preference with the business account, international phone number, purpose, and evidence source. WhatsApp marketing consent is separate from email consent. Record opt-outs as promptly as opt-ins. Marketing sends require active recorded permission; the worker checks eligibility again at dispatch.

6. Send a template

Send a template from the dashboard, or POST /api/v1/whatsapp/notifications from your server. The number_id and template_id are Notifications IDs from the list endpoints. Use parameter_schema keys exactly, such as body.1 or body.customer_name; media parameters such as header.media use a Meta media object. Variable mappings are aliases in the variables JSON (for example body.1 → customer_name); no contact lookup happens automatically. Keep the same idempotency key and payload when retrying a logical send.

curl -X POST "$BASE_URL/api/v1/whatsapp/notifications"   -H "Authorization: Bearer $API_KEY"   -H "Content-Type: application/json"   -d '{
    "number_id": "your-number-id",
    "to": "+919876543210",
    "template_id": "your-template-id",
    "variables": {"body.1": "Alex"},
    "idempotency_key": "welcome-alex-whatsapp-001"
  }'

7. Prepare and launch a campaign

Choose an approved marketing template, then add recipients using one line per phone number followed by a vertical bar and a variables JSON object. The dashboard creates a draft; launch it separately after review. A schedule uses your local time. Campaigns can be paused or cancelled; already dispatched messages cannot be recalled. Sending is bounded by your platform allowance and account eligibility.

Building something interesting?We’d love to help