OpenWA MCP Server
Provides comprehensive tools for managing WhatsApp sessions, sending multi-format messages (text, image, file, audio, video, emoji reactions), conducting bulk campaigns, orchestrating groups (create, add/remove members, promote/demote, update subject), managing contacts (get, check, block/unblock), and configuring webhooks for real-time events.
Click on "Deploy Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@OpenWA MCP Server send a message to +1234567890"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
š¢ OpenWA MCP Server
An enterprise-grade Model Context Protocol (MCP) server that seamlessly wraps the powerful OpenWA WhatsApp REST API. It exposes 44 robust tools over standard I/O (stdio) transport, enabling any MCP-compatible AI assistant (such as Cursor, Claude Desktop, Cline, and Antigravity) to securely manage WhatsApp sessions, dispatch multi-format messages, control group participants, search contacts, manage tag labels, and setup callbacks in real-time.
š§± System Architecture
āāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāā
ā 1. AI CLIENT (Cursor, Claude, Cline, etc.) ā
ā User: "Send a promotional flyer to my active VIP groups..." ā
āāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāā
ā
ā¼ [JSON-RPC over stdio]
āāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāā
ā 2. OPENWA MCP SERVER (TypeScript) ā
ā ⢠Matches user request to the `send_image` tool schema ā
ā ⢠Validates payload boundaries using declarative Zod schemas ā
ā ⢠Authenticates securely via local dotenv environment configs ā
āāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāā
ā
ā¼ [REST API Request with X-API-Key]
āāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāā
ā 3. OPENWA WHATSAPP REST DAEMON ā
ā ⢠Translates API payloads into native WhatsApp Web calls ā
ā ⢠Manages multi-session state machines & SQLite indexes ā
āāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāā
ā
ā¼ [WhatsApp Network Protocol]
āāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāā
ā 4. TARGET WHATSAPP DEVICES ā
ā ⢠Bulk promotional flyers delivered safely and instantly ā
āāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāRelated MCP server: WAHA MCP Server
⨠Features
44 Built-in Tools: Comprehensive control over the entire WhatsApp ecosystem.
Robust Zod Validation: Pure, declarative parameter validation on every request.
Zero-Poll Webhooks: Simple callbacks to receive instant WhatsApp events directly.
Multi-Session Native Engine: Manage multiple phone accounts under a single server wrapper.
Strict Separation of Concerns: Highly modular, human-written TypeScript architecture.
š ļø Installation & Setup
Prerequisites
Node.js:
v22.0.0or higherTypeScript:
v5.0.0or higherA running and accessible OpenWA REST API instance
A secure API Key generated from your OpenWA server configuration
1. Clone & Build
# Clone the repository
git clone https://github.com/ExoCubeYT/openwa-mcp.git
cd openwa-mcp
# Install dependencies
npm install
# Configure environment variables
cp .env.example .env2. Configure Environment
Edit your local .env file to match your active OpenWA REST API backend:
OPENWA_BASE_URL=http://localhost:2785/api
OPENWA_API_KEY=your_secure_api_key_here3. Build Production Targets
npm run buildThe production output will compile cleanly into the dist/index.js bundle directory.
š AI Agent Integrations
To load the OpenWA MCP server into your favorite developer environment, reference the standard JSON-RPC launch config.
Note: Replace
C:/path/to/openwa-mcpwith the absolute local filesystem path of your cloned workspace directory.
Claude Desktop
Edit your global configuration file:
Windows:
%APPDATA%\Claude\claude_desktop_config.jsonmacOS:
~/Library/Application Support/Claude/claude_desktop_config.json
{
"mcpServers": {
"openwa": {
"command": "node",
"args": ["C:/path/to/openwa-mcp/dist/index.js"],
"env": {
"OPENWA_BASE_URL": "http://localhost:2785/api",
"OPENWA_API_KEY": "your_secure_api_key_here"
}
}
}
}Cursor
Add to .cursor/mcp.json in your project root (or set globally via Settings > Features > MCP):
{
"mcpServers": {
"openwa": {
"command": "node",
"args": ["C:/path/to/openwa-mcp/dist/index.js"],
"env": {
"OPENWA_BASE_URL": "http://localhost:2785/api",
"OPENWA_API_KEY": "your_secure_api_key_here"
}
}
}
}Cline (VS Code Extension)
Edit your global extension state configurations in cline_mcp_settings.json:
{
"mcpServers": {
"openwa": {
"command": "node",
"args": ["C:/path/to/openwa-mcp/dist/index.js"],
"env": {
"OPENWA_BASE_URL": "http://localhost:2785/api",
"OPENWA_API_KEY": "your_secure_api_key_here"
},
"disabled": false
}
}
}Claude Code
Add .mcp.json to your project workspace root:
{
"mcpServers": {
"openwa": {
"command": "node",
"args": ["C:/path/to/openwa-mcp/dist/index.js"],
"env": {
"OPENWA_BASE_URL": "http://localhost:2785/api",
"OPENWA_API_KEY": "your_secure_api_key_here"
}
}
}
}VS Code (Copilot / Continue / Open Code)
Create .vscode/mcp.json inside your local workspace:
{
"servers": {
"openwa": {
"command": "node",
"args": ["C:/path/to/openwa-mcp/dist/index.js"],
"env": {
"OPENWA_BASE_URL": "http://localhost:2785/api",
"OPENWA_API_KEY": "your_secure_api_key_here"
}
}
}
}š§° WhatsApp Tool Catalog (44 Total)
All tool schemas are structured logically using modular TypeScript domains under src/tools/.
š± Sessions & Authentication (7)
Tool | Params | Description |
| None | Lists all active WhatsApp web browser sessions |
|
| Launches a new browser instance for authentication |
|
| Resumes a stopped session container |
|
| Safely shuts down a running browser instance |
|
| Wipes the credentials and directory of a session |
|
| Generates a base64 pairing QR code for WhatsApp link |
|
| Returns |
š¬ Messaging Services (8)
Tool | Params | Description |
|
| Dispatches a plaintext message to a contact/group |
|
| Fetches and sends an image from a URL |
|
| Sends document files (PDFs, docs) from a URL |
|
| Sends audio file streams directly to a target chat |
|
| Sends high-definition videos from web URLs |
|
| Attaches a quick emoji reaction to a message |
|
| Retrieves historical context and message logs |
|
| Deletes/revokes a message for everyone |
š Bulk Campaigns (2)
Tool | Params | Description |
|
| Delivers text announcements to target chats |
|
| Broadcasts promotional flyers to multiple contacts |
š„ Group Orchestration (10)
Tool | Params | Description |
| None | Returns a list of all groups the session is in |
|
| Provisions a new group with custom contacts |
|
| Resolves admins, descriptions, and metadata |
|
| Adds a contact to an existing group |
|
| Removes/kicks a participant from the group |
|
| Grants admin permissions to a participant |
|
| Strips admin privileges from a group manager |
|
| Targeted message relay for group channels |
|
| Exits the specified group safely |
|
| Renames the group conversation title |
š Contact Management (6)
Tool | Params | Description |
| None | Lists all saved contacts and known numbers |
|
| Returns metadata, status, and profile information |
|
| Verifies if a raw phone number is on WhatsApp |
|
| Resolves high-resolution avatar display URLs |
|
| Instantly blocks incoming chats from a number |
|
| Restores normal chat capabilities to a number |
š Webhook Configs (4)
Tool | Params | Description |
| None | Lists active callback URLs configured for events |
|
| Subscribes a server URL to WhatsApp events |
|
| Removes an active event callback listener |
|
| Mutates subscribed events on an active webhook |
š·ļø Chat Labels (5)
Tool | Params | Description |
| None | Fetches all custom label classifications |
|
| Creates a new colored tag label |
|
| Removes a custom label classification |
|
| Adds a label classification to a chat thread |
|
| Removes a label classification from a chat thread |
š¦ Media Assets (2)
Tool | Params | Description |
|
| Downloads media files stored inside a message |
|
| Caches media on the server to prevent redelivery |
š ļø Local Development
To run the codebase in live-refresh watch mode during extensions, run:
# Spawns tsx to track active source code files directly
npm run devTo run standard test transport handshakes, build the module and execute the diagnostic listener:
npm run build
node dist/index.jsš¤ Contributing
We welcome contributions of all shapes and sizes! To keep codebases pristine and secure, please adhere to our strict project design conventions.
Step-by-Step Contribution Flow
Fork the Repository: Set up your workspace branch on GitHub.
Implement Your Logic: Maintain strict separation of concerns. Keep your tools and clients isolated.
No AI Comments: Adhere to our zero AI-style commenting standard. Use short, human-like annotations where needed, and document details in
.explanationfiles only.Build & Test: Ensure
npm run buildgenerates zero TypeScript errors.Create a Pull Request: Submit your pull request for review against our development branch.
See CONTRIBUTING.md for deeper details on our design paradigms.
š License
Distributed under the MIT License. See the LICENSE file for details.
Available Tools
44 toolsadd_group_memberB
Add a participant to a WhatsApp group
Inputs: sessionId (required), groupId (required), participantId (required).
add_label_to_chatB
Apply a label to a specific WhatsApp chat
Inputs: sessionId (required), labelId (required), chatId (required).
block_contactC
Block a WhatsApp contact
Inputs: sessionId (required), contactId (required).
check_numberB
Check if a phone number is registered on WhatsApp
Inputs: sessionId (required), phone (required).
create_groupB
Create a new WhatsApp group with specified participants
Inputs: sessionId (required), name (required), participants (required).
create_labelB
Create a new label/tag for organizing WhatsApp chats
Inputs: sessionId (required), name (required), color.
create_sessionC
Create a new WhatsApp session with the given name
Inputs: name (required).
create_webhookB
Create a new webhook to receive WhatsApp events at a URL
Inputs: sessionId (required), url (required), events (required), secret.
delete_labelB
Delete a label from the WhatsApp session
Inputs: sessionId (required), labelId (required).
delete_messageB
Delete a specific message from a WhatsApp chat
Inputs: sessionId (required), messageId (required).
delete_sessionA
Permanently delete a WhatsApp session and its data
Inputs: sessionId (required).
delete_webhookB
Delete a webhook from a WhatsApp session
Inputs: sessionId (required), webhookId (required).
demote_memberB
Demote a group admin back to regular participant
Inputs: sessionId (required), groupId (required), participantId (required).
get_contactB
Get detailed info for a specific WhatsApp contact
Inputs: sessionId (required), contactId (required).
get_contactsA
List all contacts stored in the WhatsApp session
Inputs: sessionId (required).
get_group_infoA
Get detailed information about a specific WhatsApp group including members, admins, and settings
Inputs: sessionId (required), groupId (required).
get_groupsB
List all WhatsApp groups visible to the given session
Inputs: sessionId (required).
get_labelsB
List all labels/tags in the WhatsApp session
Inputs: sessionId (required).
get_mediaB
Download media (image, video, audio, document) from a received WhatsApp message by its message ID
Inputs: sessionId (required), messageId (required).
get_messagesB
Retrieve message history from a specific WhatsApp chat
Inputs: sessionId (required), chatId (required).
get_profile_pictureA
Get the profile picture URL for a WhatsApp contact
Inputs: sessionId (required), contactId (required).
get_session_qrA
Get the QR code data for authenticating a WhatsApp session. Use this when a session needs to be scanned with WhatsApp mobile.
Inputs: sessionId (required).
get_sessionsA
List all WhatsApp sessions currently managed by OpenWA
Inputs: no named parameters.
get_session_statusB
Check the current connection status of a WhatsApp session (connected, disconnected, etc.)
Inputs: sessionId (required).
leave_groupB
Leave a WhatsApp group
Inputs: sessionId (required), groupId (required).
list_webhooksA
List all webhooks configured for a WhatsApp session
Inputs: sessionId (required).
promote_memberB
Promote a group participant to admin role
Inputs: sessionId (required), groupId (required), participantId (required).
react_to_messageA
React to a specific WhatsApp message with an emoji
Inputs: sessionId (required), chatId (required), messageId (required), reaction (required).
remove_group_memberB
Remove a participant from a WhatsApp group
Inputs: sessionId (required), groupId (required), participantId (required).
remove_label_from_chatB
Remove a label from a specific WhatsApp chat
Inputs: sessionId (required), labelId (required), chatId (required).
send_audioB
Send an audio file to a WhatsApp chat by providing a publicly accessible URL
Inputs: sessionId (required), chatId (required), url (required).
send_bulk_imageB
Send the same image to multiple WhatsApp recipients at once
Inputs: sessionId (required), recipients (required), url (required), caption.
send_bulk_textB
Send the same text message to multiple WhatsApp recipients at once
Inputs: sessionId (required), recipients (required), text (required).
send_fileA
Send a file/document to a WhatsApp chat by providing a publicly accessible URL
Inputs: sessionId (required), chatId (required), url (required), filename (required), +1 more.
send_group_messageC
Send a text message directly to a WhatsApp group
Inputs: sessionId (required), groupId (required), text (required).
send_imageB
Send an image to a WhatsApp chat by providing a publicly accessible URL
Inputs: sessionId (required), chatId (required), url (required), caption.
send_textA
Send a text message to a WhatsApp chat. chatId format: 5511999999999@c.us for contacts or 5511999999999-1234567890@g.us for groups.
Inputs: sessionId (required), chatId (required), text (required).
send_videoA
Send a video to a WhatsApp chat by providing a publicly accessible URL
Inputs: sessionId (required), chatId (required), url (required), caption.
start_sessionA
Start a stopped WhatsApp session to make it active
Inputs: sessionId (required).
stop_sessionB
Stop a running WhatsApp session gracefully
Inputs: sessionId (required).
unblock_contactA
Unblock a previously blocked WhatsApp contact
Inputs: sessionId (required), contactId (required).
update_group_subjectB
Change the name/subject of a WhatsApp group
Inputs: sessionId (required), groupId (required), subject (required).
update_webhookC
Update an existing webhook configuration
Inputs: sessionId (required), webhookId (required), url, events, +1 more.
upload_mediaB
Upload media to OpenWA for later use in messages
Inputs: sessionId (required), file (required), type (required).
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelogā¦
TDQS
Scored across 44 tools
Most tools have distinct purposes, but there is overlap between send_text and send_group_message as both can send text to groups. Other tools are clearly separated by resource or action.
All tools follow a consistent verb_noun pattern with underscores (e.g., add_group_member, block_contact). No mixing of styles or irregular naming.
With 44 tools, the server is overly large for its scope. Many operations could be combined (e.g., send_bulk_text and send_bulk_image could share a parameter), exceeding the recommended maximum of 25.
The tool set covers all major WhatsApp operations: sessions, contacts, groups, messaging (including media and bulk), labels, and webhooks. No obvious gaps for typical use cases.
Maintenance
Related MCP Connectors
Send WhatsApp messages and templates, manage chats, contacts, broadcasts and AI agents.
Official WhatsApp Business API (Meta Cloud API) for your own CRM or SaaS, from WasapFlow, a Meta Tech Provider. Your AI can search the Bridge docs, list connected numbers, create Embedded Signup links so clients connect their own WhatsApp (Coexistence supported), send text and template messages, list templates, check and retry failed webhooks, see usage and open support tickets. Docs tools work without a key; account tools use the x-partner-key header.
Read, summarize and send your own WhatsApp messages from AI assistants (OAuth 2.1).
Read, search and reply to your WhatsApp chats from your AI, using your own number.
Related MCP Servers
- AlicenseBqualityDmaintenanceEnables AI assistants to interact with WhatsApp through the WAHA (WhatsApp HTTP API) platform. Supports chat management, message operations including sending/receiving messages, and marking chats as read.5230 npm11ISC
- AlicenseBqualityBmaintenanceBridges the WhatsApp HTTP API with AI assistants to enable full control over messaging, chat management, and interactive workflows through 63 specialized tools. It allows users to automate WhatsApp tasks and receive real-time AI feedback directly on their mobile devices.638 npm6MIT
- FlicenseNot gradedqualityDmaintenanceOpenWA MCP server that bridges AI agents to the OpenWA WhatsApp API, exposing 40 tools for sessions, messages, contacts, groups, and webhooks so agents can read and send WhatsApp messages through a self-hosted OpenWA gateway.-

GoWA MCP Serverofficial
AlicenseNot gradedqualityBmaintenanceEnables AI agents and tools to send and manage WhatsApp messages, media, statuses, and scheduled sends across multiple linked devices.MIT