-
Notifications
You must be signed in to change notification settings - Fork 0
MCP Server
Displace ships a built-in MCP (Model Context Protocol) server that lets AI coding assistants interact with your Kubernetes infrastructure using the same engine that powers the CLI. Any MCP-compatible client — Cursor, Claude Code, VS Code with Copilot, Windsurf, etc. — can connect to the server and use Displace tools directly.
flowchart LR
A["AI Client\n(Cursor, Claude,\nVS Code, etc.)"] <-->|"stdio (JSON-RPC 2.0)"| B["displace mcp serve\n\ncore engine"]
B --> C["Kubernetes Cluster"]
The MCP server communicates over stdin/stdout using JSON-RPC 2.0. It runs as a local process launched by your AI client — no ports, no HTTP, no network exposure.
- Displace CLI installed (Getting Started)
- A Displace account with an API key (for tier-gated tools)
- For deployment tools: a running Kubernetes cluster (
displace installfor local)
Add the following to your Cursor MCP configuration (.cursor/mcp.json in your project or global settings):
{
"mcpServers": {
"displace": {
"command": "displace",
"args": ["mcp", "serve"]
}
}
}Add to your Claude Code MCP settings:
{
"mcpServers": {
"displace": {
"command": "displace",
"args": ["mcp", "serve"]
}
}
}Add to your VS Code settings.json:
{
"mcp.servers": {
"displace": {
"command": "displace",
"args": ["mcp", "serve"]
}
}
}Add to your Windsurf MCP configuration:
{
"mcpServers": {
"displace": {
"command": "displace",
"args": ["mcp", "serve"]
}
}
}If displace is not on your PATH, use the full path to the binary:
{
"mcpServers": {
"displace": {
"command": "/usr/local/bin/displace",
"args": ["mcp", "serve"]
}
}
}The MCP server dynamically registers tools based on your license tier. Your AI client only sees the tools available at your tier level — there's nothing to configure.
| Tool | Description |
|---|---|
displace_analyze_project |
Scan a project to detect framework, dependencies, and deployment requirements |
displace_generate_config |
Generate Kubernetes deployment configuration from analysis results |
displace_deploy |
Deploy an application to a Kubernetes cluster with guardrail validation |
displace_status |
Get current deployment status, pod health, and recent events |
displace_logs |
Retrieve application logs from running pods |
displace_upgrade_info |
Check for CLI updates and view available tier upgrades |
Everything in Community, plus:
| Tool | Description |
|---|---|
displace_validate_production |
Run production readiness checks (security, reliability, best practices) |
displace_diagnose |
Troubleshoot deployment issues with guided root cause analysis |
displace_cost_analysis |
Analyze infrastructure costs and get optimization suggestions |
displace_migration_safety |
Assess safety of database schema migrations before running them |
displace_plan_upgrade |
Create upgrade plans with rollback strategies for K8s version bumps |
displace_multi_cluster |
List and manage clusters across providers |
Everything in Starter, plus:
| Tool | Description |
|---|---|
displace_audit_log |
Query the deployment audit trail for compliance and incident review |
displace_approve_deploy |
Multi-party deployment approval workflow |
displace_policy_check |
Evaluate deployments against organizational policies and naming conventions |
displace_compliance_soc2 |
SOC 2 compliance validation (trust services criteria) |
Everything in Professional, plus:
| Tool | Description |
|---|---|
displace_compliance_hipaa |
HIPAA compliance validation for workloads handling PHI |
displace_compliance_fedramp |
FedRAMP compliance validation (NIST 800-53 controls) |
You can test that the server starts correctly by running it manually:
displace mcp serveYou should see output on stderr:
Displace MCP server v2.0.0 (tier: Community)
Transport: stdio (JSON-RPC 2.0)
Press Ctrl+C to stop.
Press Ctrl+C to stop. The tier displayed depends on your logged-in account.
Note: The server reads from stdin and writes to stdout. When run manually it will appear to hang — this is normal. It's waiting for JSON-RPC messages from the AI client. Use
Ctrl+Cto exit.
When your AI assistant has access to the Displace MCP server, a typical deployment conversation looks like:
-
"Analyze my project" → AI calls
displace_analyze_projectto detect framework -
"Generate deployment config" → AI calls
displace_generate_configwith the detected framework -
"Deploy to my local cluster" → AI calls
displace_deploytargeting your k3d cluster -
"Check the status" → AI calls
displace_statusto verify pods are healthy -
"Show me the logs" → AI calls
displace_logsto retrieve pod output
The AI handles all the JSON-RPC communication automatically — you just describe what you want in natural language.
# Check the binary is on PATH
which displace
# Check version
displace version
# Try with verbose output
displace mcp serve 2>mcp-debug.log- Verify the MCP configuration file is saved and the client has been restarted
- Check the command path — the AI client needs to find the
displacebinary - Check your tier: Community tier shows 6 tools, paid tiers show more
- Look at the AI client's MCP server logs for connection errors
# Verify you're logged in
displace auth status
# Re-authenticate if needed
displace auth loginThe MCP server resolves your tier from your locally cached credentials. If you recently subscribed or changed tiers, re-authenticate to refresh.
- Getting Started — Install Displace and set up your first cluster
- Authentication — Configure your Displace account
- Troubleshooting — General troubleshooting guide