Deploy Center Docs Guides GitHub Download

MCP server for AI agents

Last updated · Edit on GitHub

On this page

An MCP server (stdio) that wraps the deploys CLI. A coding agent such as Claude Code, Cursor, Codex or VS Code Copilot can then ask "what is waiting to go live?", read release notes and build logs, and, only if you turn it on, deploy one project after you said yes.

It is read-only by default. Nothing here turns auto-deploy back on.

Install#

Needs Node 18 or newer and the deploys CLI (it comes with Deploy Center).

cd integrations/mcp
npm ci

The server finds deploys in this order: DEPLOYS_BIN, then PATH, then /Applications/Deploy Center.app/Contents/Resources/deploys, then the same under ~/Applications. Replace /path/to/deploy-center below with where you cloned this repo.

Why Node: the official TypeScript SDK runs as one plain .mjs file with no build step, and the lockfile pins it (@modelcontextprotocol/sdk 1.32.2). Every agent host that speaks MCP already starts Node servers, and the tests drive it over stdio from integrations/tests/run.sh with the same stand-in deploys as the other add-ons.

Claude Code#

claude mcp add deploys -- node /path/to/deploy-center/integrations/mcp/server.mjs

With deploys allowed (see Safety):

claude mcp add deploys -e DEPLOYS_MCP_ALLOW_DEPLOY=1 -- node /path/to/deploy-center/integrations/mcp/server.mjs

Add --scope user to have it in every project. claude mcp list shows it.

Claude Desktop#

~/Library/Application Support/Claude/claude_desktop_config.json:

{
  "mcpServers": {
    "deploys": {
      "command": "node",
      "args": ["/path/to/deploy-center/integrations/mcp/server.mjs"],
      "env": { "DEPLOYS_MCP_ALLOW_DEPLOY": "0" }
    }
  }
}

An app started from the Dock does not get your shell's PATH. If Claude Desktop cannot start node, give its full path (which node). The deploys from the app bundle is found without PATH; a different one needs DEPLOYS_BIN.

Cursor#

~/.cursor/mcp.json (all projects) or .cursor/mcp.json (one project):

{
  "mcpServers": {
    "deploys": {
      "command": "node",
      "args": ["/path/to/deploy-center/integrations/mcp/server.mjs"]
    }
  }
}

VS Code#

.vscode/mcp.json in the workspace (or "MCP: Add Server" in the command palette):

{
  "servers": {
    "deploys": {
      "type": "stdio",
      "command": "node",
      "args": ["/path/to/deploy-center/integrations/mcp/server.mjs"]
    }
  }
}

Tools#

ToolRuns
deploys_changeddeploys changed --jsonProjects with commits or PRs that are not live yet.
deploys_statusdeploys status --jsonWhat is building, and the newest state of each project (failed ones too).
deploys_explain(project)deploys explain <p>Why a project is, or is not, counted as changed.
deploys_notes(project)deploys notes <p>Release notes (Markdown) between what is live and the branch.
deploys_logs(project, lines)deploys logs <p> <lines>The end of the newest build log. lines 1–2000, default 80.
deploys_doctordeploys doctorTools and logins, as JSON. No key is printed.
deploys_simulate(days?)deploys simulate --days <n> --jsonEstimate: what auto-deploy would cost per month (builds, minutes, USD) vs. deploying once a day. days 1–90, default 30.
deploys_ledgerdeploys ledger --jsonEstimate: builds skipped and minutes and USD saved since auto-deploy was turned off.
deploys_deploy(project, preview?)deploys <platform> deploy-json <p> [--preview]Only with DEPLOYS_MCP_ALLOW_DEPLOY=1. Any platform deploys knows; the CLI checks the deploy window and approvals. Returns id, url, state. No preview on Render.
deploys_rollback(project)deploys <platform> rollback <p>Only with DEPLOYS_MCP_ALLOW_DEPLOY=1. Production back to the deploy that was live before.

deploys_simulate and deploys_ledger answer "what does auto-deploy cost us?" and "what did turning it off save?". Their numbers are estimates from pushes on GitHub and each project's average build; the method field in the result says how they were counted and priced, and the tool descriptions tell the agent to quote them as estimates. They read GitHub and the build history of every project, so they can take a minute or two, and have their own timeout (DEPLOYS_MCP_SLOW_TIMEOUT, default 300 s).

To find out which platform a name is on, deploy and rollback use deploys list --json when the CLI has it, and otherwise deploys status --json --no-github, which needs no GitHub calls. A name on two platforms is refused until it is written platform:name (vercel:web).

Example#

You: what's waiting to go live?

Agent calls deploys_changed: Two projects have changes that are not live: app-web (4 commits since it was deployed 3 days ago) and api on Render. Want the release notes?

You: notes for app-web

Agent calls deploys_notes(project: "app-web") and shows the list of commits and PRs.

You: ship app-web

Agent: This deploys app-web to production on Vercel, with the 4 commits above. It starts one build. Go ahead?

You: yes

Agent calls deploys_deploy(project: "app-web"): Started: dpl_…, https://app-web-….vercel.app (QUEUED). I can check deploys_status in a minute.

Without DEPLOYS_MCP_ALLOW_DEPLOY=1 the last step is not possible: the agent has no deploy tool and tells you to deploy in Deploy Center or with deploys vercel deploy app-web.

Safety#

EnvDefault
DEPLOYS_MCP_ALLOW_DEPLOYoff1 adds deploys_deploy and deploys_rollback.
DEPLOYS_BINsearchThe deploys to run.
DEPLOYS_MCP_TIMEOUT90Seconds per command.
DEPLOYS_MCP_SLOW_TIMEOUT300Seconds for deploys_simulate and deploys_ledger.
DEPLOYS_MCP_MAX_OUTPUT20000Characters per answer.
DEPLOYS_MCP_MAX_DEPLOYS3Deploys plus rollbacks one server process may start.
DEPLOYS_MCP_ALLOW_PROJECTSanyComma list (web,vercel:api): only these may be deployed or rolled back.

Tests#

integrations/tests/run.sh

The MCP part runs when node is installed and npm ci was run here; otherwise it says skip mcp. It lists the tools, calls the read tools (simulate and ledger answer from the fixture reports in tests/fixtures/savings/), checks that the write tools are missing without the flag, rejects bad names, and deploys through a stand-in deploys.

Not tested yet: a real deploy through each host (Claude Code, Claude Desktop, Cursor, VS Code).