Documentation Index
Fetch the complete documentation index at: https://docs.kaanha.ai/llms.txt
Use this file to discover all available pages before exploring further.
Contacts & Conversations
Contacts are the people your business communicates with on WhatsApp, SMS, and Slack.
Manually:
- Go to Contacts → Add Contact
- Enter phone number (E.164 format, e.g.,
+919876543210)
- Add name, email, tags
- Set Opted In status
CSV Import:
- Go to Contacts → Import
- Download the sample CSV for the required format
- Upload your CSV file
- Map columns and confirm
CSV format:
phone,name,email,tags,optedIn
+919876543210,John Doe,john@example.com,"vip,retail",true
+12125551234,Jane Smith,,lead,false
Via API:
POST /api/whatsapp-api/contacts
Authorization: Bearer YOUR_API_KEY
{
"phone": "+919876543210",
"name": "John Doe",
"optedIn": true,
"tags": ["customer"]
}
Opt-In Management
WhatsApp requires explicit opt-in before you can message contacts. Kaanha AI enforces this on every send.
| Source | Opt-In Status |
|---|
| Contact messages you first | Auto opt-in |
| Manual toggle by agent | Manual opt-in |
CSV import with optedIn: true | Bulk opt-in |
| Contact replies STOP | Auto opt-out |
Opt-in details stored:
optedIn: boolean
optInSource: how they opted in
optInProof: timestamp or message reference
Tags help you segment contacts for targeted broadcasts and automation.
Add tags:
- On the contact profile
- Via CSV import
- Automatically via Auto-Tagging rules
Auto-Tagging:
Configure keyword-based rules at Settings → Auto-Tagging:
| Rule Type | Example |
|---|
contains | Message contains “order” → add tag “buyer” |
exact | Message is exactly “PROMO” → add tag “promo” |
startsWith | Message starts with “REF” → add tag “referral” |
Auto-tags are applied to incoming messages automatically.
View a unified history of all interactions with a contact:
- Go to Contacts → click a contact → Timeline icon
- See: messages sent/received, conversations opened/resolved, audit events
CTWA (Click-to-WhatsApp Ad) Tracking
If a contact came from a WhatsApp ad, their ad metadata is captured automatically:
- Ad source, headline, body
ctwaClid (Click-to-WhatsApp Click ID)
- Stored in
contact.attributes.ctwa
View CTWA attribution at Analytics → CTWA.
Conversations
A conversation is a thread of messages with a specific contact.
Conversation Status
| Status | Meaning |
|---|
OPEN | Active, awaiting agent response |
ASSIGNED | Assigned to a specific agent |
RESOLVED | Closed by an agent |
BOT_ACTIVE | Flow bot is handling it |
AI_ACTIVE | AI agent is handling it |
Chat Inbox
The Chat page shows all conversations sorted by last activity:
- Filter by status, assigned agent, or channel
- Search contacts by name or phone
- Bulk actions: mark read, star, archive, delete
24-Hour Window
WhatsApp allows free-form messages only within 24 hours of the last customer message. After 24 hours, you must use an approved template.
The chat header shows a countdown timer when the window is approaching expiration.
Sending Messages
| Message Type | Available When |
|---|
| Text | Always (within 24h window) |
| Image, Video, Document | Always (within 24h window) |
| Template | Any time |
| Interactive (buttons/list) | Within 24h window |
Quick Replies
Save frequently used messages as shortcuts:
- Go to Quick Replies → Create
- Set a shortcut (e.g.,
/greeting)
- Set the message content (supports
{{contact.name}}, {{org.name}}, etc.)
In the chat input, type / to trigger the quick reply picker.
Supported variables:
{{contact.name}} — Full contact name
{{contact.firstName}} — First name only
{{org.name}} — Your business name
{{agent.name}} — Current agent’s name
{{date}} — Today’s date
{{time}} — Current time
Channel Switcher
If your organization has SMS enabled, use the channel switcher in the chat header to toggle between:
- Cloud API — WhatsApp via Meta
- SMS — Twilio SMS channel
The selected channel applies to the next message you send.
CSAT (Customer Satisfaction)
After a conversation is resolved, Kaanha AI automatically sends a CSAT survey:
- Asks the contact to rate 1-5
- Stores the rating and optional comment
- Contributes to your CSAT score on the Analytics page