MainWP

io.github.mainwpv1.4.0更新于 Oct 6, 2026

Manage WordPress sites in MainWP from AI tools, with approval before destructive changes by default.

概览

AI 生成的概览

让 AI 助手管理自建的 MainWP 仪表盘:列出并同步 WordPress 站点、查看并应用更新,以及处理插件、主题、客户和笔记。

功能
将兼容 MCP 的 AI 客户端连接到自建的 MainWP 仪表盘,用于管理多个 WordPress 站点。约 70 个工具涵盖:列出、同步、检查连通性、添加、重新连接或移除子站点;查看并应用核心、插件、主题和翻译更新;启用、停用或删除插件和主题;管理客户记录、标签和费用;读取机构、客户和站点笔记、技能与记忆。引导式工作流可生成网络摘要、站点报告、安全审计和更新计划。
适用场景
适合管理大量 WordPress 站点的代理机构和自由职业者,用自然语言询问哪些站点有待处理更新、在整个网络中应用更新,或检查哪些客户站点已断开连接。它面向现有 MainWP 仪表盘的维护和客户工作,而不是单个 WordPress 站点。
运行要求
通过 npx 以 npm 包 @mainwp/mcp 在本地运行,因此运行 AI 工具的机器需要 Node.js 20.19 或更高版本。需要可通过 HTTPS 访问的 MainWP Dashboard 6.0 或更高版本、兼容 MCP 的客户端,以及环境变量 MAINWP_URL、MAINWP_USER 和 MAINWP_APP_PASSWORD(WordPress 应用程序密码,不是登录密码)。部分工具需要更新的仪表盘版本。
安装前请注意
该服务器可以更改数据:添加、重新连接或移除子站点,以及启用、停用或删除插件和主题。默认情况下,破坏性更改会先显示预览,只有确认后才执行,安全模式则直接阻止这些操作;更新确认取决于仪表盘版本。MAINWP_APP_PASSWORD 是可随时撤销的 WordPress 应用程序密码,应妥善保密,最好使用专用的管理员账户签发。该服务器只与你的仪表盘通信。

安装

在 SourceWeft 中

  1. 打开 控制台中的 MainWP,将其添加到工作区。
  2. 为需要使用其工具的对话启用该服务。

Desktop only,通过 STDIO。 STDIO 服务会启动本地进程,因此需要 SourceWeft 桌面宿主。

其他 MCP 客户端

参照 仓库 中的启动说明。

README

[MainWP MCP]

Manage your whole WordPress network by talking to your AI assistant.

Website · Documentation · Quickstart · Prompt Cookbook · Video · Community · Discord · Support

[npm version] [CI] [License: GPL-3.0]

Official MainWP MCP Server

The MainWP MCP Server connects Claude, Cursor, OpenAI Codex, VS Code Copilot, and other MCP-compatible AI tools to MainWP, the self-hosted dashboard for managing many WordPress sites, so you can ask in plain English:

"Which sites have pending plugin updates?"

"Update WooCommerce everywhere it's behind."

"Which client sites are disconnected right now?"

"Check what we know about this client's sites before you update anything."

It runs on your own computer, next to your AI tool. Nothing new is installed on your Dashboard or your child sites.

[Terminal conversation through the MainWP MCP server: asking how many sites am I managing, then updating WooCommerce on every site where it is behind]

You stay in control

  • Changes wait for your approval. By default, deleting a site, plugin, or theme shows you a preview first and runs only after you say yes. On Dashboard 6.3 and later, updates work the same way. Update confirmation is coming in MainWP 6.3 but available now in the Early Release program.
  • Safe mode blocks those destructive operations outright, with no approval prompt, while you get comfortable.
  • You choose the tools. Allow and block lists decide which tools your AI can see at all.
  • Your credentials stay with you. The server signs in with a WordPress Application Password that you can revoke at any time, and it talks only to your Dashboard.

How it all works: Safety & Permissions.

What you can do

  • Sites: list, sync, check connectivity, add, reconnect, or remove child sites
  • Updates: see pending core, plugin, theme, and translation updates across the network, and apply them
  • Plugins and themes: see what is installed, activate, deactivate, or delete
  • Clients and tags: manage client records, assign sites, and track costs
  • Knowledge: agency, client, and site notes, skills, and memories your AI reads before it works. Knowledge is coming in MainWP 6.3 but available now in the Early Release program.
  • Guided workflows: network summaries, site reports, security audits, and update plans

Around 70 tools in all, depending on your Dashboard version. See Tools & Resources.

Built for agencies and freelancers who manage many WordPress sites and want AI help with updates, maintenance, and client work.

Requirements

  • Node.js 20.19 or later on the computer that runs your AI tool
  • MainWP Dashboard 6.0 or later, reachable over HTTPS (some tools need a newer Dashboard; the Quickstart lists which)
  • An MCP-compatible AI client

Get started

1. Create an Application Password. In your MainWP Dashboard, go to Users > Profile > Application Passwords, add one named "MainWP MCP Server", and copy it. It is separate from your login password, and you can revoke it at any time. A dedicated administrator account for API access keeps the audit trail clean.

2. Add the server to your AI tool. For Claude Desktop and most other MCP clients:

json
{  "mcpServers": {    "mainwp": {      "command": "npx",      "args": ["-y", "@mainwp/mcp"],      "env": {        "MAINWP_URL": "https://your-dashboard.com",        "MAINWP_USER": "admin",        "MAINWP_APP_PASSWORD": "xxxx xxxx xxxx xxxx xxxx xxxx"      }    }  }}

3. Restart your AI tool and ask "List all my sites". A working setup returns your child sites by name and URL.

Config file locations for each client are in the client setup guide. Every setting is in the Configuration Reference.

Using Claude Code? The plugin installs the server, an agent skill, and ten /mainwp:* workflow commands:

text
/plugin marketplace add mainwp/mainwp-mcp/plugin install mainwp@mainwp-mcp

Credentials still come from your environment. See Claude Code plugin.

Documentation

Full documentation lives at docs.mainwp.com/mcp-server:

Community

Contributing

Bug reports and pull requests are welcome. Please report security issues privately as described in SECURITY.md.

bash
npm ci             # install dependenciesnpm run dev        # run in watch modenpm run inspect    # test with MCP Inspectornpm test           # run testsnpm run lint       # check code stylenpm run format     # fix formatting

CI runs lint, format check, type check, tests, and build on every pull request. When you change a configuration option, update the docs-site configuration reference in the same change. .agents/skills/mainwp-dashboard is the canonical copy of the agent skill; see docs/plugin.md.

License

GPL-3.0. See LICENSE.

来源:README.md,提交 0cff693

工具

0
工具元数据尚未被收录。

版本历史

1
  1. v1.4.0最新Oct 6, 2026