Server Configuration
Describes the environment variables required to run the server.
| Name | Required | Description | Default |
|---|---|---|---|
| WHATSAPP_TOKEN | Yes | Your WhatsApp Cloud API access token | |
| WHATSAPP_PHONE_ID | Yes | Your WhatsApp Business phone number ID |
Capabilities
Features and capabilities supported by this server
| Capability | Details |
|---|---|
| tools | {
"listChanged": true
} |
| prompts | {
"listChanged": false
} |
| resources | {
"subscribe": false,
"listChanged": false
} |
| experimental | {} |
Tools
Functions exposed to the LLM to take actions
| Name | Description |
|---|---|
| send_message | Send a text message to a WhatsApp user. Args: to: Phone number (with country code) or WhatsApp ID text: The text message content header: Optional header text (for interactive messages) footer: Optional footer text (for interactive messages) preview_url: Whether to show URL previews (default False) reply_to_message_id: Message ID to reply to Returns: Dictionary with success status and message ID |
| send_image | Send an image message. Args: to: Phone number or WhatsApp ID image: Image URL or media ID caption: Optional image caption footer: Optional footer text reply_to_message_id: Message ID to reply to Returns: Dictionary with success status and message ID |
| send_video | Send a video message. Args: to: Phone number or WhatsApp ID video: Video URL or media ID caption: Optional video caption footer: Optional footer text reply_to_message_id: Message ID to reply to Returns: Dictionary with success status and message ID |
| send_document | Send a document message. Args: to: Phone number or WhatsApp ID document: Document URL or media ID filename: Optional filename for the document caption: Optional document caption footer: Optional footer text reply_to_message_id: Message ID to reply to Returns: Dictionary with success status and message ID |
| send_audio | Send an audio message. Args: to: Phone number or WhatsApp ID audio: Audio URL or media ID reply_to_message_id: Message ID to reply to Returns: Dictionary with success status and message ID |
| send_sticker | Send a sticker message. Args: to: Phone number or WhatsApp ID sticker: Sticker URL or media ID (must be webp format) reply_to_message_id: Message ID to reply to Returns: Dictionary with success status and message ID |
| send_location | Send a location message. Args: to: Phone number or WhatsApp ID latitude: Latitude of the location longitude: Longitude of the location name: Optional location name address: Optional location address reply_to_message_id: Message ID to reply to Returns: Dictionary with success status and message ID |
| request_location | Request user's location. Args: to: Phone number or WhatsApp ID text: Message text asking for location reply_to_message_id: Message ID to reply to Returns: Dictionary with success status and message ID |
| send_contact | Send a contact card. Args: to: Phone number or WhatsApp ID contact_name: Name of the contact contact_phone: Phone number of the contact reply_to_message_id: Message ID to reply to Returns: Dictionary with success status and message ID |
| send_reaction | Send a reaction to a message. Args: to: Phone number or WhatsApp ID emoji: Reaction emoji message_id: ID of message to react to sender: Optional sender phone ID Returns: Dictionary with success status |
| remove_reaction | Remove a reaction from a message. Args: to: Phone number or WhatsApp ID message_id: ID of message to remove reaction from sender: Optional sender phone ID Returns: Dictionary with success status |
| mark_message_as_read | Mark a message as read. Args: message_id: The WhatsApp message ID to mark as read sender: Optional phone ID Returns: Dictionary with success status |
| indicate_typing | Show typing indicator to WhatsApp user. This marks a message as read and displays a typing indicator to show the user that you are preparing a response. Best practice when it will take a few seconds to respond. IMPORTANT NOTES:
EXAMPLE: { "message_id": "wamid.HBgNMjc2NTY4NjY5MDUVAgARGBI5QTNDMEM3RjVBMzY2Q0Y4AA==" } Args: message_id: The WhatsApp message ID to respond to (from incoming message) sender: Optional phone ID (defaults to client's phone ID) Returns: Dictionary with success status |
| upload_media | Upload media file to WhatsApp servers. Args: media_path: Path to media file mime_type: Optional MIME type Returns: Dictionary with media ID |
| send_message_with_buttons | Send a message with reply buttons (up to 3). CONSTRAINTS:
EXAMPLE: { "to": "+1234567890", "text": "Choose an option:", "buttons": [ {"id": "option_1", "title": "Yes"}, {"id": "option_2", "title": "No"}, {"id": "option_3", "title": "Maybe"} ], "header": "Quick Question", "footer": "Select one option" } Args: to: Phone number (with country code) or WhatsApp ID text: Message body text (main message content) buttons: List of buttons with 'id' and 'title' keys (max 3) header: Optional header text (appears above main text) footer: Optional footer text (appears below buttons) reply_to_message_id: Message ID to reply to Returns: Dictionary with success status and message ID |
| send_message_with_list | Send a message with a selection list. CONSTRAINTS:
EXAMPLE: { "to": "+1234567890", "text": "Choose from our menu:", "button_text": "View Menu", "sections": [ { "title": "Main Courses", "rows": [ {"id": "burger", "title": "Burger", "description": "Beef burger with fries"}, {"id": "pizza", "title": "Pizza", "description": "Margherita pizza"} ] }, { "title": "Beverages", "rows": [ {"id": "coke", "title": "Coca Cola", "description": "Cold refreshing drink"}, {"id": "water", "title": "Water", "description": "Still or sparkling"} ] } ], "header": "Restaurant Menu", "footer": "All items available today" } Args:
to: Phone number (with country code) or WhatsApp ID Returns: Dictionary with success status and message ID |
| send_template | Send a WhatsApp template message. Args: to: Phone number or WhatsApp ID name: Template name/ID language: Template language code (default: en) params: Optional template parameters (header, body, button components) reply_to_message_id: Message ID to reply to Returns: Dictionary with success status and message ID |
| get_templates | Get list of available WhatsApp templates. Args: limit: Maximum number of templates to return (default: 100) name: Optional template name filter Returns: Dictionary with templates list |
Prompts
Interactive templates invoked by user choice
| Name | Description |
|---|---|
No prompts | |
Resources
Contextual data attached and managed by the client
| Name | Description |
|---|---|
No resources | |