Installation
Clone the repo into site/modules/, install in ProcessWire admin, build the MCP server, and configure Cursor.
Requirements
- ProcessWire 3.0+
- PHP 8.0+
- Node.js 18+
- Cursor IDE with MCP support
Install the ProcessWire module
Clone the repo directly into your ProcessWire site/modules/ folder as PromptWire:
git clone https://github.com/PeterKnightDigital/PromptWire-MCP.git site/modules/PromptWire
Or download the zip, extract it, and rename the folder to PromptWire inside site/modules/.
Then in ProcessWire admin: Modules > Refresh > Install PromptWire.
The admin dashboard (ProcessPromptWireAdmin) is installed automatically. You'll find it under Setup > PromptWire Admin.
Build the MCP server
The MCP server is a small Node.js process that bridges Cursor and ProcessWire. It lives in the module directory.
cd site/modules/PromptWire/mcp-server
npm install
npm run build
This produces the compiled server at mcp-server/dist/index.js.
Configure Cursor
Create or edit .cursor/mcp.json in your project root:
{
"mcpServers": {
"PromptWire: My Site (Local)": {
"command": "node",
"args": ["/path/to/pw-site/site/modules/PromptWire/mcp-server/dist/index.js"],
"env": {
"PW_PATH": "/path/to/your/processwire/site",
"PHP_PATH": "/path/to/php"
}
}
}
}
Here's what each setting does:
| Setting | What it is |
|---|---|
"PromptWire: My Site (Local)" | A label of your choice. This is the name that appears in Cursor's MCP panel. Use whatever makes sense for your project. |
command | The runtime that starts the MCP server. Always "node". |
args | The path to the compiled MCP server inside your PromptWire module directory. Point this to mcp-server/dist/index.js within wherever you installed the module. |
PW_PATH | The absolute path to your ProcessWire install root (the directory that contains site/ and wire/). |
PHP_PATH | The absolute path to your PHP binary. Optional if php is already on your system PATH. |
Finding your PHP path
If you're not sure where your PHP binary is, run one of these in your terminal:
which php
This works on macOS and Linux. If you use MAMP, XAMPP, or Homebrew, the path will be something like:
- MAMP:
/Applications/MAMP/bin/php/php8.x.x/bin/php - Homebrew:
/opt/homebrew/bin/phpor/usr/local/bin/php - XAMPP:
/Applications/XAMPP/bin/php - System (macOS):
/usr/bin/php
If which php returns the correct version (8.0+), you can omit PHP_PATH entirely and PromptWire will use the default php command.
Cursor will detect the config and start the MCP server automatically. You should see your chosen label in Cursor's MCP panel.
Verify the connection
In Cursor chat, try a simple query:
Show me the site health check.
The agent will call pw_health and return your ProcessWire version, template count, field count, and page count. If that works, everything is connected.
Upgrading from PW-MCP
If you previously used PW-MCP (the pre-1.5 name), install PromptWire alongside it. On install or upgrade, PromptWire automatically detects and removes the old PwMcp/ and PwMcpAdmin/ directories from site/modules/.
Your data directories are unchanged: .pw-sync/ for schema and site/assets/pw-mcp/ for content sync. No migration is needed for existing data.
Update your .cursor/mcp.json to point to the new module path (site/modules/PromptWire/). If you used the PW_MCP_CLI_PATH environment variable, rename it to PROMPTWIRE_CLI_PATH. If you used PW_MCP_API_KEY on a remote site, rename it to PROMPTWIRE_API_KEY.