WhatsApp Integration — Test Console

📋 Required Credentials & Setup Guide

Where to get your WhatsApp Cloud API credentials

  1. Go to Meta for DevelopersMy Apps → Create or select your app (type: Business)
  2. Add the WhatsApp product to your app
  3. In WhatsApp → API Setup, copy your Phone Number ID and WhatsApp Business Account ID
  4. Generate a temporary access token on that page, or create a System User in Business Settings for a permanent token
  5. For webhooks: in WhatsApp → Configuration set the callback URL to
    https://your-api-host/api/webhooks/whatsapp/{integrationSetupId}
    and set Verify token to the value you'll pass as WebhookVerifyToken
Key NameRequired?Secret?Description
PhoneNumberId Required Numeric ID of the WhatsApp Business phone number. Found in Meta Developer Console → WhatsApp → API Setup.
AccessToken Required Secret Bearer token sent with every Graph API call. Use a System User token for production — temporary tokens expire in ~24h.
BusinessAccountId Optional WhatsApp Business Account (WABA) ID. Needed for account-level operations and template management.
WebhookVerifyToken Optional Secret A token you invent and store here. Meta sends it back during webhook verification — must match exactly.
ApiVersion Optional Meta Graph API version, e.g. v20.0. Defaults to v20.0 when omitted.

Secret storage behaviour

Development — credentials are Base64-encoded JSON stored in the SecretStorageRef DB column (easy local testing, NOT safe for prod).

Production — credentials are stored as a single JSON secret in Azure Key Vault. The DB column holds only the KV secret name. Ensure your App Service has a Managed Identity with Key Vault Secrets Officer role.

API 1 — GET /api/integrations/active

GET

Returns all active integration types with their required keys — call this first to see what credentials are needed.

API 2 — POST /api/integrations/setup

POST

Stores your credentials and returns an IntegrationSetupId used in all subsequent calls.

✅ IntegrationSetupId saved:
This value has been auto-filled in API 3 & 4 below.

API 3 — POST /api/messages/whatsapp

POST
Text
Template
Image

API 4 — GET /api/conversations/{id}

GET

API 5 — GET /api/conversations?integrationSetupId=…

GET

Webhook Endpoints (register in Meta Developer Console)

INFO

Verification (GET) — Meta calls this once when you save the webhook URL

GET /api/webhooks/whatsapp/{integrationSetupId}?hub.mode=subscribe&hub.verify_token=YOUR_TOKEN&hub.challenge=CHALLENGE

Inbound messages & status updates (POST) — Meta calls this on every event

POST /api/webhooks/whatsapp/{integrationSetupId}

In Meta Developer Console → WhatsApp → Configuration:
• Callback URL: https://your-api-host/api/webhooks/whatsapp/{integrationSetupId}
• Verify token: the WebhookVerifyToken you supplied when setting up the integration
• Subscribe to: messages