MCP Configuration for AI Coding Agents
The Model Context Protocol (MCP) allows AI coding agents to interact with your deployment.io infrastructure. Once configured, agents like Claude Code, Cursor, OpenAI Codex, Gemini CLI, and Antigravity can deploy your apps, manage environments, and monitor builds — directly from your development workflow.
Prerequisites
- A deployment.io account
Connection Methods
There are two ways to connect your coding agent to deployment.io:
- OAuth (recommended) — The agent opens a browser window, you log in and approve access. No manual key copying needed.
- API Key — Generate a key from the dashboard and paste it into your agent's configuration.
Method 1: OAuth (Recommended)
OAuth lets you connect with a single click — no API key to copy or manage.
Claude Code CLI
Run the following command:
claude mcp add deployment-io --transport http https://api.deployment.io/v1/mcp
Claude Code will open a browser window where you log in to deployment.io and approve access. The connection is established automatically.
Claude Desktop
- Go to Settings > MCP Servers (or Connectors).
- Click Add MCP Server.
- Enter the URL:
https://api.deployment.io/v1/mcp - Claude Desktop will open a browser for you to log in and approve access.
Cursor
- Open Cursor and go to Settings > Tools & MCP.
- Click Add Custom MCP.
- Enter the URL:
https://api.deployment.io/v1/mcp - Cursor will open a browser for you to log in and approve access.
OpenAI Codex
- Add the server to your
~/.codex/config.toml:
[mcp_servers.deployment-io]
url = "https://api.deployment.io/v1/mcp"
- Run the OAuth login command:
codex mcp login deployment-io
Codex will open a browser window where you log in to deployment.io and approve access.
Antigravity
- Open the Menu in the Agent pane and go to MCP Servers > Manage MCP Servers.
- Click View raw config to open
mcp_config.json. - Add the following configuration:
{
"mcpServers": {
"deployment-io": {
"serverUrl": "https://api.deployment.io/v1/mcp"
}
}
}
- Click Refresh. Antigravity will open a browser for you to log in and approve access.
Method 2: API Key
If your agent doesn't support OAuth, or you prefer manual configuration, use an API key.
Step 1: Generate an API Key
- Go to Organization Settings > Agent Keys in your deployment.io dashboard.
- Click Create New Key and give it a descriptive name (e.g., "Claude Code Key").
- Copy the API key immediately — you won't be able to see it again.
Step 2: Copy the MCP Configuration
After generating your key, you'll see an MCP JSON configuration block like this:
{
"mcpServers": {
"deployment-io": {
"url": "https://api.deployment.io/v1/mcp",
"headers": {
"Authorization": "Bearer YOUR_API_KEY"
}
}
}
}
Replace YOUR_API_KEY with the key you copied in Step 1.
Agent Setup with API Key
Claude Code CLI
claude mcp add deployment-io --transport http https://api.deployment.io/v1/mcp \
-h "Authorization: Bearer YOUR_API_KEY"
Claude Desktop
Add the configuration to your claude_desktop_config.json file:
- macOS:
~/Library/Application Support/Claude/claude_desktop_config.json - Windows:
%APPDATA%\Claude\claude_desktop_config.json
Merge the MCP JSON config from Step 2 into the file.
Cursor
- Open Cursor and go to Settings > Tools & MCP.
- Click Add Custom MCP.
- Paste the MCP JSON configuration from Step 2 into the editor.
- Save and restart Cursor.
Windsurf
- Open Windsurf and go to Settings > MCP.
- Click Add Server and select HTTP.
- Paste the MCP JSON configuration from Step 2.
- Save and restart Windsurf.
OpenAI Codex
Add the server to your ~/.codex/config.toml:
[mcp_servers.deployment-io]
url = "https://api.deployment.io/v1/mcp"
bearer_token_env_var = "DEPLOYMENT_IO_API_KEY"
Then set the environment variable:
export DEPLOYMENT_IO_API_KEY=YOUR_API_KEY
Gemini CLI
Run the following command:
gemini mcp add -s user --transport http \
--header "Authorization: Bearer YOUR_API_KEY" \
deployment-io https://api.deployment.io/v1/mcp
Or manually add to your ~/.gemini/settings.json:
{
"mcpServers": {
"deployment-io": {
"httpUrl": "https://api.deployment.io/v1/mcp",
"headers": {
"Authorization": "Bearer YOUR_API_KEY"
}
}
}
}
Antigravity
- Open the Menu in the Agent pane and go to MCP Servers > Manage MCP Servers.
- Click View raw config to open
mcp_config.json. - Add the following configuration:
{
"mcpServers": {
"deployment-io": {
"serverUrl": "https://api.deployment.io/v1/mcp",
"headers": {
"Authorization": "Bearer YOUR_API_KEY"
}
}
}
}
- Click Refresh and restart Antigravity.
Troubleshooting
- Verify your connection works: Run a simple prompt like "list my environments" in your agent. If the connection is working, you'll see your environments listed.
- Check the MCP URL: Ensure the URL is exactly
https://api.deployment.io/v1/mcpwith no trailing slash. - OAuth issues: If the browser authorization window doesn't open, check that your agent supports OAuth-based MCP connections. Fall back to the API key method if needed.
- Regenerate the key: If your API key stops working, it may have been revoked. Create a new one from the Agent Keys settings page.
- Revoke access: You can revoke OAuth-connected agents or API keys anytime from Organization Settings > Agent Keys.