WhatsApp Connection
Kaanha AI connects to WhatsApp using the official Meta Cloud API — the same infrastructure WhatsApp uses for enterprise messaging. This means full compliance, template support, and access to all WhatsApp Business features.Prerequisites
Before you start, you’ll need:- A Meta Business Account — business.facebook.com
- A WhatsApp Business Account (WABA) — approved by Meta
- A verified phone number registered in your WABA
- A Meta App with WhatsApp product added
Configuration Steps
- Navigate to Settings → Cloud API in your Kaanha AI dashboard
- Fill in the following credentials:
| Field | Where to Find |
|---|---|
| Phone Number ID | Meta Business Manager → WhatsApp → Phone Numbers |
| Business Account ID | Meta Business Manager → WhatsApp → Settings |
| Access Token | Meta App Dashboard → System Users → Generate Token |
| App Secret | Meta App Dashboard → Settings → Basic |
| Webhook Verify Token | Create any random string (e.g., kaanha_verify_abc123) |
- Click Test Connection — you’ll see a green ✓ if credentials are valid
-
Configure the Webhook in Meta Business Manager:
- URL:
https://app.kaanha.ai/api/webhooks/whatsapp - Verify Token: (the token you set in step 2)
- Subscribe to events:
messages,message_deliveries,message_reads,message_echoes
- URL:
Meta App Permissions Required
Your Meta App must have the following permissions approved:whatsapp_business_messagingwhatsapp_business_management
WhatsApp Compliance
Kaanha AI enforces Meta’s messaging policies automatically on every message:- Opt-in enforcement — All outbound messages check
Contact.optedInbefore sending - 24-hour window — Template messages required for new conversations or after 24h inactivity
- Rate limiting — 20 messages/hour per recipient (Meta policy)
- STOP keyword — Contacts replying STOP / UNSUBSCRIBE are automatically opted out
- Broadcast safeguards — Frequency cap prevents marketing spam
Instagram DM (Optional)
You can also receive and reply to Instagram Direct Messages from the same chat inbox.- Go to Settings → Instagram
- Enter your Instagram credentials:
- Access Token (from Meta Business Manager)
- Business Account ID
- Page ID (connected Facebook Page)
- Webhook Verify Token
- Configure webhook in Meta:
https://app.kaanha.ai/api/webhooks/instagram - Toggle Instagram Enabled
Instagram DM credentials are encrypted at rest using AES-256-GCM.