Listmonk MCP

io.github.tecspda由 GitHub 帳號 tecspda 發布v0.1.3更新於 Oct 30, 2026

Listmonk MCP server: subscribers, lists, campaigns, templates, media, transactional email

已驗證STDIO僅桌面溝通與協作商業與電商

概覽

AI 產生的概覽

針對自架 Listmonk 的 MCP 伺服器,讓助理管理訂閱者、郵件清單、活動、範本與媒體,並寄送郵件。

可以做什麼
  • 檢查 Listmonk 健康狀態與連線狀況
  • 新增、更新、刪除、搜尋與查詢訂閱者,並變更其狀態
  • 建立、更新、刪除與檢視郵件清單及其成員
  • 建立、更新、預覽、立即寄送或排程活動,並以一般取代、正規表示式取代或批次取代編輯活動內容
  • 建立、更新、讀取與刪除範本,可從檔案載入大型 HTML 內容
  • 以 tx 範本寄送交易型郵件,並上傳、重新命名、列出或刪除媒體
適用情境
適合自架 Listmonk 電子報伺服器、想讓助理處理日常清單管理、草擬或修改活動、管理範本與媒體,或寄送單封交易型郵件的情境,不必在管理後台逐項操作。
執行需求
以 stdio 本機程序由 MCP 用戶端啟動,需要 Bun 1.1 或更新版本(透過 bunx 執行)。需要可連線的 Listmonk 位址與 API 使用者,透過 LISTMONK_MCP_URL、LISTMONK_MCP_USERNAME 與 LISTMONK_MCP_PASSWORD 提供。選用的 LISTMONK_MCP_FILES_DIR 可啟用以檔案為基礎的範本與媒體工具;逾時、重試與伺服器名稱變數為選用。
安裝前請注意
LISTMONK_MCP_PASSWORD 中的 API 權杖可存取你的郵件清單資料;應使用權限受限的專用 API 使用者而非管理員帳號,並避免把權杖寫進共用或已提交版控的設定檔。send_campaign、schedule_campaign 與 send_transactional_email 會寄出真實郵件,請保留人工核准。從 Listmonk 讀取的訂閱者名稱與活動內容可能含提示注入;檔案工具僅限 LISTMONK_MCP_FILES_DIR,未設定時停用。

安裝

在 SourceWeft 中

  1. 開啟 儀表板中的 Listmonk MCP,將其新增到工作區。
  2. 為需要使用其工具的對話啟用該服務。

Desktop only,透過 STDIO。 STDIO 服務會啟動本機處理程序,因此需要 SourceWeft 桌面主機。

其他 MCP 客戶端

參照 儲存庫 中的啟動說明。

README

Listmonk MCP Server

[Listmonk MCP Server]

An MCP server for Listmonk, the self-hosted newsletter and mailing list manager. It lets AI agents (Claude Code, Claude Desktop, Cursor, Cline, VS Code and others) manage subscribers, mailing lists, campaigns, templates and media, and send transactional email through your Listmonk instance.

TypeScript port of rhnvrm/listmonk-mcp by Rohan Verma, extended with file-based templates, campaign body editing and hardened file access.

Written in TypeScript, runs on Bun.

Русская версия

Features

  • Subscribers: add, update, delete, change status, search with Listmonk SQL queries, look up by ID or email.
  • Mailing lists: create, update, delete, list, list members.
  • Campaigns: create, update, preview, send now, schedule. Edit the body with plain-text, regex and batch replace.
  • Templates: create, update, delete, read. Large HTML bodies (for example MJML exports) can be loaded straight from a file.
  • Transactional email: send a tx template to one recipient with custom data.
  • Media: upload, rename, delete, list.

Requirements

  • Bun 1.1 or newer.
  • Listmonk with an API user. In the Listmonk admin, open Users, create a user of type API and copy its token. Give it a role with only the permissions the agent needs.

Quick start

One-click install (then replace the placeholder URL, user and token in the client's MCP settings):

[Install in Cursor] [Install in VS Code]

Claude Code

bash
claude mcp add --transport stdio --scope user \  --env LISTMONK_MCP_URL=https://listmonk.example.com \  --env LISTMONK_MCP_USERNAME=api_user \  --env LISTMONK_MCP_PASSWORD=your-api-token \  listmonk -- bunx listmonk-mcp-ts

Claude Desktop, Cursor, Cline and other clients

Add the server to the client's MCP config (mcpServers section):

json
{  "mcpServers": {    "listmonk": {      "command": "bunx",      "args": ["listmonk-mcp-ts"],      "env": {        "LISTMONK_MCP_URL": "https://listmonk.example.com",        "LISTMONK_MCP_USERNAME": "api_user",        "LISTMONK_MCP_PASSWORD": "your-api-token",        "LISTMONK_MCP_FILES_DIR": "/path/to/email-templates"      }    }  }}

Where the config file lives for each client: Claude Desktop, Cursor and Windsurf, Cline, VS Code.

The server is started by the client when a session opens and stops with it. You do not need to keep it running.

Configuration

VariableRequiredDefaultDescription
LISTMONK_MCP_URLyesListmonk base URL, http:// or https://
LISTMONK_MCP_USERNAMEyesAPI user name
LISTMONK_MCP_PASSWORDyesAPI user token
LISTMONK_MCP_FILES_DIRnoDirectory the file tools may read from. File tools are disabled when it is not set
LISTMONK_MCP_TIMEOUTno30HTTP timeout, seconds
LISTMONK_MCP_MAX_RETRIESno3Retries on network errors. Only GET requests are retried
LISTMONK_MCP_SERVER_NAMEnoListmonk MCP ServerServer name reported to the client

Variables can also come from a .env file in the working directory, or from a file passed with --config /path/to/.env.

CLI options: -c, --config <file> loads an env file, -v, --version prints the version.

Tools

AreaTools
Healthcheck_listmonk_health
Subscribersadd_subscriber, update_subscriber, remove_subscriber, change_subscriber_status, list_subscribers, get_subscriber_by_id, get_subscriber_by_email
Mailing listsget_mailing_lists, get_list_by_id, get_list_subscribers_tool, create_mailing_list, update_mailing_list, delete_mailing_list
Campaignsget_campaigns, get_campaign, get_campaign_preview, create_campaign, update_campaign, send_campaign, schedule_campaign
Campaign bodyreplace_in_campaign_body, regex_replace_in_campaign_body, batch_replace_in_campaign_body
Templatesget_templates, get_template, create_template, update_template, create_template_from_file, update_template_from_file, delete_template
Transactionalsend_transactional_email
Mediaget_media_list, upload_media_file, rename_media, delete_media_file

Templates from a file

Passing a large HTML body inline through a tool call is slow and the model can change it while copying. create_template_from_file and update_template_from_file read the body from a file instead, so the stored template matches the file byte for byte. subject is required for tx templates.

The file path can be absolute or relative to LISTMONK_MCP_FILES_DIR.

Security

  • File access is limited to LISTMONK_MCP_FILES_DIR. create_template_from_file, update_template_from_file and upload_media_file refuse any path outside it, symlinks included, and are disabled when it is not set. Subscriber names, campaign bodies and other data read from Listmonk may contain instructions written by strangers (prompt injection). Without this limit such text could make the agent read ~/.ssh or .env and email it out.
  • Keep approval on for sending tools. send_campaign, schedule_campaign and send_transactional_email send real email. Do not auto-approve them in your client.
  • Use a dedicated API user with a role limited to what the agent needs, not an admin account.
  • Keep the token out of shared files. If your MCP config is committed or synced, pass the token through the environment instead.

Development

bash
git clone https://github.com/tecspda/listmonk-mcp-ts.gitcd listmonk-mcp-tsbun installcp .env.example .env   # fill in your Listmonk detailsbun run start          # run the serverbun run dev            # run with reload on changebun run check          # type checkbun test               # tests

To run a local checkout from an MCP client, use "command": "bun", "args": ["run", "/path/to/listmonk-mcp-ts/src/index.ts"].

Need a Listmonk instance for testing? See Docker setup.

License

MIT

來源:README.md,提交 756dcf6

工具

0
SourceWeft 曾在隔離沙箱中以無憑證方式啟動該軟體包一次,以列出其工具,但未能完成:伺服器未能啟動。

版本歷史

2
  1. v0.1.3最新Oct 29, 2026
  2. v0.1.1Oct 21, 2026

評分

已滿足適用檢查項的 50%

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

  • 近 30 天內可連通25 分

    請保持端點能夠回應 MCP 握手;SourceWeft 每 30 天探測一次。

  • 已宣告認證方式10 分

    請在註冊中心條目中宣告憑證請求標頭,或保持端點能夠回應探測,以便判定其認證方式。

  • 已列出工具15 分

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

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