
WhatsApp MCP
io.github.adelaidasofia由 GitHub 账号 adelaidasofia 发布v0.1.1更新于 Oct 24, 2026
WhatsApp MCP. SQLCipher-encrypted, scrubber-CI-gated, draft-and-confirm sends, voice transcription.
概览
一个本地 WhatsApp MCP 服务器,让助手在草稿加确认的安全机制下读取、搜索并发送 WhatsApp 消息。
- 可以做什么
- 通过本地 Go 桥接程序对接 WhatsApp Web 多设备协议,并由 Python MCP 层对外提供 11 个工具。助手可以读取聊天、消息和联系人,执行忽略重音、容忍拼写错误的搜索,查看正在输入、在线等状态,并发送文本、表情回应和引用回复。发送必须在草稿与投递之间经过显式的 confirm_send 步骤。语音消息可用 whisper.cpp 在本地转写,还能从 Obsidian 库中拉取匹配的 CRM 上下文。
- 适用场景
- 适合希望助手在本机操作自己 WhatsApp 账号的场景,例如搜索会话、总结对话,或起草由你确认后再发送的回复。也适合看重本地存储、静态加密和审计记录,而不想使用云服务的用户。
- 运行要求
- 仅限桌面端,以 stdio 方式在本地运行。需要 Go 桥接程序(预编译版本,或用 Go 1.26+ 与 C 工具链自行构建)、Python 3.11+ 和 uv,以及与手机进行一次二维码或配对码绑定。可选的语音转写需要 FFmpeg 和 whisper.cpp;当 WHATSAPP_WHISPER_BACKEND 为 openai-api 时需要 WHATSAPP_WHISPER_API_KEY 密钥。配置使用 WHATSAPP_BRIDGE_HOST、WHATSAPP_BRIDGE_PORT、WHATSAPP_DB_KEY、WHATSAPP_VAULT_CRM_PATH 等变量。
安装
在 SourceWeft 中
- 打开 控制台中的 WhatsApp MCP,将其添加到工作区。
- 为需要使用其工具的对话启用该服务。
Desktop only,通过 STDIO。 STDIO 服务会启动本地进程,因此需要 SourceWeft 桌面宿主。
其他 MCP 客户端
参照 仓库 中的启动说明。
README
whatsapp-mcp
[License] [GitHub stars] [Last commit] [Open issues] [PyPI version] [PyPI downloads] [Built by Mycelium AI]
A WhatsApp MCP server for Claude, built directly on whatsmeow. Encrypted at rest, prompt-injection-scrubbed, draft-and-confirm on every send, full audit trail, daily CI security gates. Actively maintained.
Why this one?
The most-starred WhatsApp MCP (lharries/whatsapp-mcp, 5.6K stars) is the architectural reference for this pattern, but has not shipped since July 2025 and leaves the lethal-trifecta problem entirely to the user. This implementation closes the gaps:
Not a fork. The Go bridge is built directly against whatsmeow; the Python MCP layer and SQLite schema are original. Other implementations (lharries, LukasHaas, verygoodplugins) were read as reference only.
What this gives you
Claude can:
- Read your WhatsApp chats, messages, and contacts
- Search messages with accent-insensitive, typo-tolerant matching
- Transcribe voice notes locally via
whisper.cpp(language detected per note). Off until you say yes; Claude offers it once, andpython3 whatsapp-mcp-server/enable_transcription.pyturns it on in one step - Resolve LID (Linked IDentifier) names instead of numeric placeholders
- Send text messages, reactions, and reply-quotes, with a mandatory
confirm_sendstep between draft and delivery - Pull matching CRM context from your Obsidian vault when reading a chat
- See only prompt-injection-scrubbed message text, never raw adversarial input
Everything runs locally on your machine. No cloud sync. No telemetry. Optional OpenAI Whisper backend is opt-in, off by default.
Architecture
Two components, both local:
whatsapp-bridge/(Go). Binds to 127.0.0.1 only. Wrapswhatsmeowfor the WhatsApp Web multidevice protocol. Owns SQLite persistence with SQLCipher encryption. Handles QR and pairing-code auth (live-refreshing terminal QR with Windows-safe rendering, plus a headless auth API —GET /api/auth/qr,POST /api/auth/pair-phone,POST /api/auth/reconnect— so a GUI or supervisor can drive pairing without a terminal), media up/download, session recovery fromStreamReplacedconflicts, call history capture. Exposes a REST API the Python MCP layer consumes.whatsapp-mcp-server/(Python, FastMCP). Consumes the Go bridge REST API. Exposes 11 MCP tools to Claude: full read surface (chats, messages, contacts), accent-insensitive search, presence (typing, online, mark-read), and text-send + reactions + reply-quotes with mandatoryconfirm_send. Runs viauvand stdio transport.
Install
Open Claude Code, paste:
This installs the Python MCP server side. The Go bridge still needs the one-time QR pairing flow with your phone — see the legacy install block below for those steps.
Manual install (full Go bridge + QR pairing)
See SETUP.md for step-by-step install per OS. In short:
- Grab a prebuilt bridge binary from Releases (Windows/macOS/Linux — no compiler needed), or build from source (Go 1.26+ and a C toolchain)
- Python 3.11+ and
uvfor the MCP server layer - Clone this repo; verify with
scripts/check_prerequisites.sh(Windows:scripts\check_prerequisites.ps1) - Start the bridge:
./bin/whatsapp-bridge(Windows:.\bin\whatsapp-bridge.exe) - Scan the QR (it refreshes in place — always scan the one on screen), or pair by typed code with
--pair-phone +15551234567 - Register the MCP in your Claude Code
.mcp.json - Restart Claude Code
FFmpeg and whisper.cpp are only needed if you enable voice-note transcription (off by default); enable_transcription.py configures them for you, and installs them with Homebrew on a Mac (SETUP.md step 4).
Configuration
All configurable via environment variables. See .env.example for the full list.
Key variables:
The DB key and WHATSAPP_DB_KEY
With WHATSAPP_ENCRYPT_DB=true (the default), the bridge encrypts the message
store with a 256-bit SQLCipher key kept in the platform secret store. The key
lifecycle is deliberately conservative, because a wrong key silently orphans
every stored message:
- A fresh key is minted only when the secret store definitively answers
"no such item" (macOS
errSecItemNotFound, WindowsERROR_NOT_FOUND, libsecret clean miss) and no non-empty store database exists yet. - Any other failed read — locked keychain, no D-Bus session, revoked access —
makes the bridge exit with an error instead of minting: the key may still
exist, and overwriting it would make the encrypted store permanently
undecryptable. The error names the fix (e.g.
security unlock-keychain). - If the secret store has no key but a populated store database exists, the bridge also refuses to mint and asks you to supply the original key.
WHATSAPP_DB_KEY (64 hex chars = 32 bytes, e.g. openssl rand -hex 32) is
the escape hatch for all of these: when set, it is used directly and the
platform secret store is never touched. Use it for headless/CI machines,
custom secret managers, restoring a store on a new machine, or booting while
the platform store is unavailable.
Security
This MCP is the highest-trust component in your Claude stack because every WhatsApp message you receive flows through it. See SECURITY.md for the threat model, tool risk-tier classification, and the full list of hardening decisions.
Short version:
- Bridge binds to
127.0.0.1only, never0.0.0.0 - SQLite encrypted at rest with SQLCipher; key stored in the platform secret store (macOS Keychain / Windows Credential Manager / libsecret), with an explicit
WHATSAPP_DB_KEYescape hatch - Every tool call logged to
audit.logwith 30-day retention - Send tools require an explicit
confirm_sendstep between draft and delivery - Incoming message text passes through a prompt-injection scrubber before Claude sees it
whatsmeowpinned to a specific commit; upgrades require diff review- No telemetry, no external API calls by default
Status
v0.1.0, actively maintained.
Shipped: live-refreshing QR (in-place redraw on rotation, Windows-safe rendering, auto fresh batch on expiry) + pairing-code auth (typed 8-char code, Android + iOS) + headless auth API for supervisors, full read surface (chats, messages, contacts), accent-insensitive NFD-normalized search, LID alias resolution with backfill migration for legacy threads, Baileys-store import for one-shot history migration, vault-format markdown export, local whisper.cpp voice transcription, presence (typing, online, mark-read), text-send with mandatory confirm_send, reactions, reply-quotes, prompt-injection scrubber, SQLCipher-encrypted persistence with macOS Keychain key handling, audit log, CI security gates.
Not yet shipped: media-send (image, document), audio-message-send (FFmpeg-Opus path), group broadcast helpers.
See CHANGELOG.md for full history.
MCP Registry
Published on the official MCP Registry under io.github.adelaidasofia/whatsapp-mcp. Two live channels:
.mcpbbundle (canonical, recommended) — one-click install in Claude Desktop / Cursor / any MCPB-aware client. Published as a GitHub release artifact at releases/latest/download/whatsapp-mcp.mcpb. The release manifest carries the SHA256 for tamper detection.- PyPI package (
adelaidasofia-whatsapp-mcp) — historical; available viauvx adelaidasofia-whatsapp-mcpfor stdio-installer flows. The unprefixed names (whatsapp-mcp,whatsapp-mcp-server) are taken by unrelated projects on PyPI, hence the username-prefixed namespace.
The verification marker mcp-name: io.github.adelaidasofia/whatsapp-mcp is embedded in this README (HTML comment near the top) so the registry can verify package-to-server ownership at publish time.
Publishing pipeline: built and shipped via the Mycelium MCP publishing pipeline (two-phase: .mcpb bundle build, then gh release + mcp-publisher publish). The same pipeline produced all 16 sibling MCPs in this family.
Related MCPs
Same author, same architecture pattern (FastMCP, draft+confirm on writes where applicable, vault auto-export, MIT):
- slack-mcp — multi-workspace Slack
- imessage-mcp — macOS iMessage
- google-workspace-mcp — Gmail / Calendar / Drive / Docs / Sheets
- apollo-mcp — Apollo.io CRM + sequences
- substack-mcp — Substack writing + analytics
- luma-mcp — lu.ma events
- parse-mcp — markitdown / Docling / LlamaParse router
- rescuetime-mcp — RescueTime productivity data
- graph-query-mcp — vault knowledge graph queries
- graph-autotagger-mcp — wikilink suggestions from the graph
- investor-relations-mcp — seed-raise pipeline tracker
- vault-sync-mcp — bidirectional vault sync
Telemetry
This plugin sends a single anonymous install signal to myceliumai.co the first time it loads in a Claude Code session on a given machine.
What is sent:
- Plugin name (e.g.
slack-mcp) - Plugin version (e.g.
0.1.0)
What is NOT sent:
- No user identifiers, names, emails, tokens, or API keys
- No file paths, message content, or anything from your work
- No IP address is stored after dedup processing
Why: Helps the maintainer know which plugins people actually install, so attention goes to the ones that get used.
Opt out: Set the environment variable MYCELIUM_NO_PING=1 before launching Claude Code. The hook will skip the network call entirely. Already-pinged installs leave a sentinel at ~/.mycelium/onboarded-<plugin> — delete it if you want to reset state.
License
MIT. See LICENSE.
Not affiliated with WhatsApp or Meta
WhatsApp is a trademark of Meta Platforms, Inc. This project is an independent open-source tool that uses WhatsApp's public web-multidevice protocol. Use of this tool may violate WhatsApp's Terms of Service. Use at your own risk. The authors provide no warranty and accept no liability for account suspension, data loss, or other consequences.
Built by Mycelium AI. MIT license.
来源:README.md,提交 7bb1b4f
工具
0版本历史
1- v0.1.1最新Sep 16, 2026
评分
已满足适用检查项的 50%
该评分衡量此收录条目的完整程度,依据注册中心条目、端点与公开来源计算得出。它不是对服务器本身的评价,也不表示服务器安全或当前可用:可连通性是带日期的检查结果,评分也不包含安装量或用户评价。
- 近 30 天内可连通25 分
请保持端点能够响应 MCP 握手;SourceWeft 每 30 天探测一次。
- 已声明认证方式10 分
请在注册中心条目中声明凭据请求头,或保持端点能够响应探测,以便判定其认证方式。
- 已列出工具15 分
请让服务器在无凭据时响应 tools/list,或发布可在沙箱中无凭据启动的软件包。
- 描述必需15 分
- 图标10 分
- 文档15 分
- 许可证10 分