WhatsApp Business MCP Server
Utilizes the Meta Graph API to interface with WhatsApp Business accounts, facilitating template management and business profile configurations.
Provides tools for the WhatsApp Business Cloud API to send text, media, location, and interactive messages, manage message templates, and monitor messaging analytics.
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., "@WhatsApp Business MCP Server Send a message to +5511999998888 saying your order is ready"
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.
@bridgeapi/mcp-whatsapp
MCP Server para WhatsApp Business Cloud API — Conecte qualquer AI Agent ao WhatsApp via Model Context Protocol.
Parte do ecossistema BridgeAPI: conectores MCP para plataformas brasileiras.
O que faz
Este MCP server expõe a WhatsApp Business Cloud API como tools padronizados do Model Context Protocol. Isso permite que qualquer AI Agent (Claude, ChatGPT, LangChain, CrewAI, etc.) envie mensagens, gerencie templates, consulte analytics e muito mais — tudo via MCP.
Tools disponíveis
Tool | Descrição |
| Envia mensagem de texto (dentro da janela de 24h) |
| Envia template pré-aprovado (fora da janela de 24h) |
| Envia imagem, vídeo, áudio ou documento |
| Envia mensagem com botões ou lista |
| Envia localização |
| Envia cartão de contato |
| Marca mensagem como lida |
| Lista templates com status de aprovação |
| Cria novo template para aprovação |
| Deleta template |
| Lista números com quality rating |
| Retorna perfil do negócio |
| Atualiza perfil |
| Métricas de mensagens por período |
| Upload de mídia para envio |
| URL de download de mídia recebida |
Resources (contexto read-only)
Resource | URI |
Templates ativos |
|
Perfil do negócio |
|
Números registrados |
|
Prompts (guias reutilizáveis)
Prompt | Uso |
| Guia para enviar campanha de marketing |
| Guia para responder suporte |
| Guia para criar templates seguindo regras da Meta |
Instalação
npm install @bridgeapi/mcp-whatsappConfiguração
Variáveis de ambiente obrigatórias
export WHATSAPP_ACCESS_TOKEN="your-system-user-token"
export WHATSAPP_PHONE_NUMBER_ID="your-phone-number-id"
export WHATSAPP_BUSINESS_ACCOUNT_ID="your-waba-id"
# Opcional:
export WHATSAPP_API_VERSION="v21.0" # defaultComo obter: Acesse Meta Business Manager → WhatsApp → Configuração da API.
Uso com Claude Desktop
Adicione ao seu claude_desktop_config.json:
{
"mcpServers": {
"whatsapp": {
"command": "npx",
"args": ["@bridgeapi/mcp-whatsapp"],
"env": {
"WHATSAPP_ACCESS_TOKEN": "your-token",
"WHATSAPP_PHONE_NUMBER_ID": "your-phone-id",
"WHATSAPP_BUSINESS_ACCOUNT_ID": "your-waba-id"
}
}
}
}Uso com Cursor
Adicione ao seu .cursor/mcp.json:
{
"mcpServers": {
"whatsapp": {
"command": "npx",
"args": ["@bridgeapi/mcp-whatsapp"],
"env": {
"WHATSAPP_ACCESS_TOKEN": "your-token",
"WHATSAPP_PHONE_NUMBER_ID": "your-phone-id",
"WHATSAPP_BUSINESS_ACCOUNT_ID": "your-waba-id"
}
}
}
}Exemplos de uso
Após configurar, você pode falar diretamente com o Claude:
Enviar mensagem
"Envie uma mensagem para +5541999999999 dizendo: Seu pedido #1234 foi enviado!"
Listar templates
"Quais templates de WhatsApp estão aprovados?"
Criar campanha
"Preciso criar uma campanha de marketing para o produto 'Curso de IA'. Me ajude a criar o template e enviar."
Ver analytics
"Mostre as métricas de mensagens dos últimos 7 dias."
Desenvolvimento
# Clone e instale
git clone https://github.com/bridgeapi-dev/mcp-whatsapp.git
cd mcp-whatsapp
npm install
# Build
npm run build
# Testar com MCP Inspector
npm run inspect
# Dev mode (watch)
npm run devArquitetura
Agent (Claude/ChatGPT/LangChain)
│
▼ (MCP Protocol - JSON-RPC 2.0)
┌──────────────────────────────┐
│ @bridgeapi/mcp-whatsapp │
│ ┌────────────────────────┐ │
│ │ pre_execute hook ◄────│──│── Phase 2: Execution Engine
│ │ (Phase 1: no-op + log) │ │
│ └────────┬───────────────┘ │
│ ▼ │
│ ┌────────────────────────┐ │
│ │ WhatsApp Cloud API │ │
│ │ (Meta Graph API v21.0) │ │
│ └────────┬───────────────┘ │
│ ▼ │
│ ┌────────────────────────┐ │
│ │ post_execute hook ◄────│──│── Phase 2: Response validation
│ │ (Phase 1: no-op + log) │ │
│ └────────────────────────┘ │
└──────────────────────────────┘Os hooks
pre_executeepost_executeestão prontos para receber a Execution Engine na Fase 2 do BridgeAPI, mas na v0.1 são no-ops que apenas logam o contexto.
Roadmap
v0.1 — Tools core de messaging, templates, analytics, media
v0.2 — Webhook receiver para mensagens recebidas
v0.3 — Streamable HTTP transport (para uso remoto via Gateway)
v1.0 — Pronto para produção com rate limiting e error recovery
Ecossistema BridgeAPI
Conector | Status |
WhatsApp Business API | ✅ v0.1 |
Hotmart | 🔜 Em desenvolvimento |
Eduzz | 🔜 Planejado |
Pix / Pagamentos | 🔜 Planejado |
NFe / Notas Fiscais | 🔜 Planejado |
Guru | 🔜 Planejado |
Licença
MIT — use livremente.
Links
BridgeAPI — Plataforma gerenciada
MCP Specification — Protocolo oficial
WhatsApp Cloud API Docs — Documentação da Meta
Available Tools
16 toolscreate_templateA
Create a new message template for approval by Meta. Templates are required for outbound messages outside the 24-hour window.
Inputs: name (required), category (required), components (required), language.
delete_templateA
Delete a message template by name. This action is irreversible.
Inputs: template_name (required).
get_analyticsC
Get messaging analytics (sent, delivered, read counts) for a date range.
Inputs: start_date (required), end_date (required), granularity.
get_business_profileB
Get the WhatsApp Business profile (about, address, description, email, websites, profile picture).
Inputs: no named parameters.
get_media_urlA
Get the download URL for a received media file. URLs are valid for 5 minutes.
Inputs: media_id (required).
get_phone_numbersA
List all phone numbers registered on this WhatsApp Business Account, including quality rating and messaging limits.
Inputs: no named parameters.
list_templatesB
List all message templates in the WhatsApp Business Account, optionally filtered by status.
Inputs: status, limit.
mark_message_readB
Mark a received message as read (blue checkmarks). Use the message_id from a received webhook.
Inputs: message_id (required).
send_contact_messageC
Send a contact card to a WhatsApp number.
Inputs: to (required), contacts (required).
send_interactive_messageC
Send an interactive message with buttons or a selection list.
Inputs: to (required), interactive_type (required), body_text (required), buttons, +4 more.
send_location_messageC
Send a location pin to a WhatsApp number.
Inputs: to (required), latitude (required), longitude (required), name, +1 more.
send_media_messageC
Send an image, video, audio, or document to a WhatsApp number.
Inputs: to (required), media_type (required), media_url, media_id, +2 more.
send_template_messageA
Send a pre-approved template message. Required for initiating conversations outside the 24-hour window. Templates must be approved by Meta before use.
Inputs: to (required), template_name (required), language, components.
send_text_messageA
Send a text message to a WhatsApp number. Works within the 24-hour conversation window. For messages outside this window, use send_template_message instead.
Inputs: to (required), body (required), preview_url.
update_business_profileC
Update the WhatsApp Business profile information.
Inputs: about, description, address, email, +1 more.
upload_mediaB
Upload a media file for later sending. Returns a media_id that can be used with send_media_message.
Inputs: file_url (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 16 tools
Every tool has a clearly distinct purpose with no ambiguity. For example, send_text_message, send_media_message, and send_template_message each handle different message types, while get_business_profile and update_business_profile are clearly separate read and write operations. The descriptions reinforce these distinctions, making tool selection straightforward.
All tool names follow a consistent verb_noun pattern with clear, descriptive verbs like create, delete, get, list, mark, send, and update. There are no deviations in style (e.g., no camelCase or mixed conventions), making the naming highly predictable and readable throughout the set.
With 16 tools, the server is well-scoped for managing a WhatsApp Business Account, covering key areas like messaging (text, media, templates, interactive), profile management, analytics, and media handling. Each tool earns its place without feeling excessive or thin, aligning well with the domain's complexity.
The tool set provides complete CRUD/lifecycle coverage for the WhatsApp Business domain. It includes creation (e.g., create_template, upload_media), retrieval (e.g., get_business_profile, list_templates), updates (e.g., update_business_profile, mark_message_read), and deletion (delete_template), with no obvious gaps that would hinder agent workflows.
Related MCP Connectors
WhatsApp for AI agents — your own number or the official Cloud API: messages, media, templates.
WhatsApp for Claude, ChatGPT or any AI agent: search, reply and send. Personal or Business API.
WhatsMCP connects Claude and other MCP-compatible AI agents directly to WhatsApp. Send and receive text, images, documents, and voice notes; manage groups (create, add/remove members, promote admins); look up contacts and profiles; follow channels; and read call and message history — all through a standard MCP interface. For voice use cases, WhatsMCP offers SIP-based calling plans (inbound-only, or full inbound/outbound) so AI voice agents can answer and place WhatsApp calls, plus low-latency WebSocket integrations with voice agent providers like ElevenLabs. Multiple WhatsApp accounts can be paired and managed per workspace, with webhook support for real-time inbound message delivery to your own infrastructure.
Send WhatsApp messages and templates, manage chats, contacts, broadcasts and AI agents.