Whatsapp

me.wacli由 wacli.me 發布官方發布者v0.2.1更新於 Oct 25, 2026

Your own WhatsApp as an MCP server: read, search and send from any MCP client.

已驗證Streamable HTTP可網頁執行知識與記憶溝通與協作

概覽

AI 產生的概覽

託管式 MCP 閘道,可連結你自己的 WhatsApp 帳號,讓任何 MCP 用戶端讀取、搜尋並可選擇傳送訊息。

可以做什麼
讀取已連結 WhatsApp 帳號同步存放區中的訊息,並在其中搜尋;讀取以唯讀模式執行,工具呼叫無法變更存放區。只有在帳號擁有者明確為該租戶開啟寫入權限時,才會提供傳送訊息的功能。透過 Streamable HTTP 在 MCP 端點以 bearer 權杖連線,並提供 OAuth 2.1 探索,用戶端可自行取得憑證。像 WhatsApp Web 一樣掃 QR 碼連結一次帳號後,即可在任何 MCP 用戶端使用,不必在本機執行任何程式。
適用情境
適合讓助理查看自己的 WhatsApp 歷史訊息,或從 MCP 用戶端起草並傳送回覆,而不必執行本機橋接程式。適用於個人或小團隊、每個權杖對應一個已連結帳號的情境。
執行需求
位於 wacli.me 的遠端端點,使用 Streamable HTTP,並要求 OAuth 驗證。需要可掃 QR 碼連結的 WhatsApp 帳號,以及在連結頁面簽發的 bearer 權杖。自架需要 Node.js、隨附的 wacli 二進位檔,以及用於回填歷史訊息的同步常駐程式。
安裝前請注意
掃 QR 碼連結屬於「已連結裝置」:持有存放區目錄或租戶權杖的人都能讀取該帳號的訊息,因此兩者都應視為憑證。傳送屬於寫入操作,僅在啟用 allowSend 時才會註冊;除非擁有者要求,否則應保持關閉。此服務是單一主機上的公開 alpha 版本。自架時應綁定回送位址並透過通道存取,不要直接暴露連接埠。

安裝

在 SourceWeft 中

  1. 開啟 儀表板中的 Whatsapp,將其新增到工作區。
  2. 連接 所需的 憑證。它們會被私密儲存,絕不會在公開頁面上展示。
  3. 為需要使用其工具的對話啟用該服務。

Web executable,透過 Streamable HTTP。 遠端服務在工作區中設定後即可從網頁執行環境執行。

交給代理程式安裝

把這段提示詞貼上到 Claude Code、Codex、Cursor 等代理程式,或 SourceWeft 對話中。代理程式會讀取該伺服器的安裝指南,先向你展示發布者、端點和登入方式,經你同意後再把它新增到你的客戶端。金鑰不會寫進任何命令。

閱讀 https://sourceweft.com/mcp/me.wacli%2Fwhatsapp/install.md,並按其中說明把這個 MCP 伺服器接入我的客戶端。修改任何設定之前,先告訴我它的發布者、端點和登入方式,等我確認。不要把 API 金鑰寫進命令或我會提交的檔案;問我金鑰應從哪裡取得。

檢視代理程式所依據的安裝指南

其他 MCP 客戶端

把它新增到你客戶端的 mcpServers 設定中。 客戶端會在首次連接時完成 OAuth 登入。

{
  "mcpServers": {
    "whatsapp": {
      "type": "http",
      "url": "https://wacli.me/mcp"
    }
  }
}

README

wacli.me

Hosted MCP gateway in front of the wacli WhatsApp CLI.

The idea: someone links their WhatsApp account once (QR, like WhatsApp Web) and gets a URL plus a bearer token. Any MCP client can then read, search — and optionally send — without running anything locally.

Status: public alpha. Single host, single process. Live at https://wacli.me.

MIT licensed. Self-hosting is a first-class path — see "Running" below.

Layout

server/      Node MCP server (Streamable HTTP) + static file servingsite/        website sources (pages + layout + assets)web/         generated site, built from site/ by scripts/build.mjs — never editconfig/      tenants.json (gitignored) — token -> store mappingbin/wacli    pinned wacli binary, isolated from any system installstores/      one wacli store directory per tenant (gitignored)scripts/     start/stop/tunnel helpers

Endpoints

PathPurpose
/landing page
/mcpMCP over Streamable HTTP, Authorization: Bearer …
/healthzliveness + tenant count
/connectself-service linking: live QR, issues a token
/.well-known/oauth-*OAuth 2.1 discovery — clients fetch their own credentials

Tenants

config/tenants.json:

json
{  "tenants": [    { "id": "demo", "token": "<32 random bytes, hex>", "store": "/Users/<user>/wacli-me/stores/demo", "allowSend": false }  ]}

The file is re-read every 5 seconds — adding a tenant needs no restart. A token maps to exactly one store directory; tools are constructed per request against that store, so two tenants cannot see each other's data. allowSend is what registers the send_message tool at all; leave it false unless the account owner explicitly asked for write access.

Generate a token with openssl rand -hex 32.

Running

bash
npm install --prefix servernode scripts/build.mjs                        # site/ -> web/PORT=8787 HOST=127.0.0.1 node server/server.mjs

Environment:

VariableDefaultMeaning
PORT8787listen port
HOST127.0.0.1bind address — keep loopback, expose via tunnel
WACLI_BIN./bin/wacliwacli binary
WACLI_ME_TENANTS./config/tenants.jsontenant file

Linking an account

bash
bin/wacli --store stores/<tenant> auth        # prints a QR, scan it on the phonebin/wacli --store stores/<tenant> sync        # backfill history (long-running; run as a daemon)

Without a sync daemon the store only holds what was fetched during the last run.

Security notes

  • Bind to loopback and publish through a tunnel; never expose the port directly.
  • Every MCP request needs a valid bearer token; tokens are compared in constant time.
  • Reads run wacli with --read-only, so a compromised tool call cannot mutate the store.
  • The QR link is a linked device. Whoever holds the store can read that account's messages — treat store directories and tenant tokens as credentials.

License

MIT, see LICENSE. site/assets/qrcode.min.js is Kazuhiko Arase's qrcode-generator, vendored unchanged (MIT). wacli itself is a separate MIT project — this repository only drives it.

Linking an account uses an unofficial WhatsApp client. That is against WhatsApp's terms of service, and Meta may block a number for it. Run it on accounts you own, and tell your users the same.

來源:README.md,提交 0bcd107

工具

0
該伺服器需要登入,因此 SourceWeft 無法在沒有帳號的情況下讀取其工具,也未收錄。已連接帳號所能看到的內容可能因帳號及其權限而異。

版本歷史

2
  1. v0.2.1最新Sep 19, 2026
  2. v0.2.0Sep 18, 2026

評分

已滿足適用檢查項的 85%

該評分衡量此收錄條目的完整程度,依據註冊中心條目、端點與公開來源計算得出。它不是對伺服器本身的評價,也不表示伺服器安全或目前可用:可連通性是帶日期的檢查結果,評分也不包含安裝量或使用者評價。

  • 近 30 天內可連通必需25 分
  • 已宣告認證方式必需10 分
  • 已列出工具15 分

    請讓伺服器在無憑證時回應 tools/list,或發布可在沙箱中無憑證啟動的軟體包。

  • 描述必需15 分
  • 圖示10 分
  • 文件15 分
  • 授權條款10 分