Connect Patcherly to your AI assistant¶
Patcherly offers a MCP (Model Context Protocol) server so AI tools such as Cursor, VS Code, Claude Desktop, and other MCP-compatible clients can work with your workspace - list errors, review sites, export metrics, and (when permitted) approve fixes - using the same permissions as the dashboard.
Before you connect¶
- A workspace admin must enable MCP for your workspace under Profile → MCP (Read / Write / Export toggles per domain). New workspaces start with MCP off until an admin opts in.
- You need a Patcherly account and access to the workspace you want the assistant to use.
- Your plan limits (fixes, sites, exports, etc.) still apply: MCP uses the same quotas as the dashboard.
[!TIP] Switch to the correct workspace in the dashboard before you authorize MCP. The token is bound to the workspace that was active at consent time. Changing workspaces later does not widen an existing token - disconnect and authorize again if you need a different workspace.
If you are not already signed in to Patcherly, the browser consent step opens the login form first, then returns you to the same authorize page (your OAuth request is not lost).
What you can do with MCP¶
When your role and workspace policy allow it, your assistant can:
| Area | Examples |
|---|---|
| Profile | Read your masked profile (no secrets) |
| Sites | List sites, inspect status (incl. reported connector version / outdated flag), export CSV, disconnect, delete (with confirmation) |
| Errors | List and inspect errors (including AI explanation and patch via get_error), export CSV, trigger analysis, approve/reject/ignore, rollback, delete (with confirmation) |
| Metrics | Read KPI cards and export metrics CSV |
| Audit | Read audit events and export audit CSV |
| Usage | Read AI/fix usage summaries and export usage CSV |
Never available via MCP: account deletion, billing or payment changes, reading raw AI API keys, MFA enrollment, inviting team members, or wiping entire databases. Destructive deletes require an explicit confirmation flag in the tool call - your assistant should ask you before proceeding.
Connect your client¶
Overview on the Patcherly website: patcherly.com/mcp.
Production MCP URL (every client uses this):
Authorization (browser sign-in) uses your Patcherly dashboard at https://app.patcherly.com (authorize page). When your client opens OAuth, approve only the scopes your workflow needs. After you approve, the browser may hand off to the assistant and leave the tab open - once the client shows connected, you can close that window.
Quick install¶
| Client | One step |
|---|---|
| Cursor | Install in Cursor · Cursor Directory (plugin + skills) - details below |
| Claude Code | claude mcp add --transport http patcherly https://mcp.patcherly.com/mcp → claude mcp login patcherly - details |
| Codex CLI | codex mcp add patcherly --url https://mcp.patcherly.com/mcp → codex mcp login patcherly - details |
| VS Code | Add remote URL + OAuth - VS Code |
| Claude Desktop | Custom connector / remote URL - Claude Desktop |
| Other MCP apps | Same URL + OAuth - Other MCP apps |
Cursor¶
One click - then sign in when Cursor asks:
Install Patcherly MCP in Cursor
Open Customize → MCPs, choose Authenticate (or Connect / Login) for patcherly, complete the browser consent, and confirm tools such as list_errors appear. Prefer Authenticate over Logout if a previous attempt interrupted.
Optional - add to your project .cursor/mcp.json instead of the button above:
No client id is required in mcp.json. You can also install the Patcherly Cursor plugin (same server, plus skills for triaging errors and exports) from the Cursor Directory listing, the Cursor marketplace, or the public cursor/ folder on patcherly-mcp-plugins.
Claude Code (terminal)¶
Complete sign-in in the browser. In Claude Code, run /mcp to confirm patcherly is connected. Optional full plugin (skills included): claude/ on patcherly-mcp-plugins.
Codex CLI (terminal)¶
Start a new session and run /mcp to verify the connection. Optional full plugin: codex/ on patcherly-mcp-plugins.
VS Code¶
- Open the Command Palette (Ctrl+Shift+P on Windows/Linux, Cmd+Shift+P on Mac).
- Run MCP: Add Server → HTTP / remote.
- Enter
https://mcp.patcherly.com/mcpand finish sign-in in the browser.
Or add this to your user or workspace mcp.json (VS Code Copilot):
Reload the window if tools do not appear immediately. No API key or client id is required - sign in with OAuth when prompted.
Claude Desktop¶
Patcherly is a remote MCP server (no local MCP binary). Prefer adding a custom connector / remote MCP URL in Claude Desktop or Claude.ai:
- Add connector URL
https://mcp.patcherly.com/mcp. - Complete OAuth sign-in in the browser when prompted.
If your Claude build still uses a local MCP config file, the same URL-only entry works:
Restart Claude if tools do not appear, then sign in when prompted.
Other MCP apps¶
Use URL https://mcp.patcherly.com/mcp in any client that supports remote HTTP MCP with OAuth. Apps that only support local plugins cannot connect to Patcherly's hosted server directly.
Workspace admin: MCP policy¶
Workspace admins configure MCP under Profile → MCP:
| Domain | Typical caps |
|---|---|
| Profile | Read |
| Sites | Read, Write, Export |
| Errors | Read, Write, Export |
| Metrics | Read, Export |
| Audit | Read, Export |
| Usage | Read, Export |
- Read - list and inspect data in that domain.
- Write - approve fixes, change error status, manage sites, and similar dashboard actions exposed as MCP tools.
- Export - CSV exports via
export_targets,export_errors,export_metrics,export_usage, andexport_audit(same data as dashboard Export buttons; field separator follows Profile → Date and Data Formatting → CSV delimiter, semicolon by default).
If all domains are off, authorize requests return forbidden until an admin enables at least one domain.
Tightening policy later revokes scopes that exceed the new policy on live tokens automatically.
Manage connections¶
- Profile → MCP (AI assistant connections) - see your active MCP sessions (one row per assistant connection; optional assistant label, scopes, last used, session end) and revoke any you no longer trust.
- MCP sessions last at most 30 days from when you approve the connection. After that (or if you revoke), your assistant must authorize again.
- Password change or password reset revokes MCP tokens for your account (reconnect under Profile → MCP). Disabling MFA does the same. Enabling MFA does not revoke MCP by itself.
- Removed team members lose MCP access immediately; re-invited users must connect again.
Example prompts¶
Once connected, you can ask your assistant in natural language, for example:
- "List open errors on my WordPress site."
- "Summarize fix usage this billing period."
- "Show audit events from the last 24 hours."
- "Approve the pending fix for error ID …" (only if Write is enabled and you confirm)
The assistant discovers available tools from the MCP server after authentication. If a tool is missing, your role or workspace policy may not include that domain.
Security tips¶
- Grant only the scopes you need on the consent screen.
- Revoke unused tokens from Profile → MCP.
- Do not paste Patcherly passwords or connector secrets into AI chat: MCP uses OAuth, not your connector HMAC secret.
- Treat write-capable tokens like dashboard admin access - revoke them when a project ends.
Troubleshooting¶
| Symptom | What to check |
|---|---|
| Authorize returns forbidden | Workspace MCP policy may be all-off - ask a workspace admin to enable domains under Profile → MCP. |
| Tool list is empty or tools fail | Your role may lack RBAC for that domain (e.g. metrics export needs permission to view metrics). |
| Wrong workspace data | Token was issued for another workspace - revoke the connection, switch workspace in the dashboard, authorize again. |
| 403 after team change | Removed members lose access immediately; reconnect with a new token if you were re-invited. |
| Client cannot reach MCP | Confirm URL https://mcp.patcherly.com/mcp and that your network allows HTTPS to Patcherly. |
| Cursor shows Logout / Unauthorized after install | Use Authenticate or Connect (not Logout). If it stays stuck, fully quit Cursor, clear MCP tokens from the Command Palette (Cursor: Clear All MCP Tokens), restart, and authenticate once. |
| Platform maintenance | If MCP is temporarily disabled platform-wide, authorize and tool calls may return unavailable - try again later. |
For connector setup (errors from your app), see Installing a Connector.