Skip to content

talkops-ai/kargo

v0.2.1Apache-2.0

Agent Skills and execution-only MCP server for Kargo v1.12 progressive delivery pipelines, freight promotions, rollbacks, credentials, and troubleshooting.


Let your AI assistant manage Kargo promotion pipelines: see what's deployed where, promote and approve freight, roll back stages, and find out why a promotion failed. Secrets stay on the server.

What you get

  • 20 MCP tools (4 read-only) that work against your live Kargo setup
  • 18 resources your assistant can read for context, under kargo://
  • 5 Agent Skills: step-by-step playbooks that teach your assistant how to use the tools well
  • Safe by default: only read-only tools are loaded until you turn on writes, and changes are previewed or confirmed before they happen

Quick start

You'll need:

  • Python 3.12+ and uv, or Docker
  • A Kargo API URL and credentials (admin password or a bearer token)

1. Add the server to your MCP client. For Claude Desktop, Cursor, Windsurf, and most other clients, add this to your MCP config file:

{
  "mcpServers": {
    "kargo": {
      "command": "uvx",
      "args": [
        "--from",
        "talkops-kargo-mcp-server",
        "kargo-mcp-server"
      ],
      "env": {
        "KARGO_BASE_URL": "https://kargo.example.com",
        "KARGO_AUTH_MODE": "static",
        "KARGO_STATIC_BEARER_TOKEN": "<your-kargo-token>"
      }
    }
  }
}

Using Claude Code? Run this instead:

claude mcp add kargo -e KARGO_BASE_URL=https://kargo.example.com -e KARGO_AUTH_MODE=static -e KARGO_STATIC_BEARER_TOKEN=<your-kargo-token> -- uvx --from talkops-kargo-mcp-server kargo-mcp-server

uvx downloads talkops-kargo-mcp-server from PyPI and runs it, so there's nothing else to install. Prefer a normal install? Run pip install talkops-kargo-mcp-server and use kargo-mcp-server as the command.

Prefer Docker? Pull talkopsai/kargo-mcp-server from Docker Hub—no Python setup needed:

{
  "mcpServers": {
    "kargo": {
      "command": "docker",
      "args": [
        "run",
        "-i",
        "--rm",
        "-e",
        "MCP_TRANSPORT=stdio",
        "-e",
        "KARGO_BASE_URL",
        "-e",
        "KARGO_AUTH_MODE",
        "-e",
        "KARGO_STATIC_BEARER_TOKEN",
        "talkopsai/kargo-mcp-server:latest"
      ],
      "env": {
        "KARGO_BASE_URL": "https://kargo.example.com",
        "KARGO_AUTH_MODE": "static",
        "KARGO_STATIC_BEARER_TOKEN": "<your-kargo-token>"
      }
    }
  }
}

2. Restart your client and try asking:

  • "Show me the pipeline for the guestbook project. What's running in each stage?"
  • "Promote the latest freight to staging."
  • "Why did the last promotion to prod fail?"

Allowing changes

Out of the box the server is read-only. To let your assistant make changes (creating and changing projects, warehouses, stages, promotions, credentials, and roles), add "--allow-write" to args (or pass -e MCP_ALLOW_WRITE=true to docker run). Even then, changes are previewed first and destructive actions ask for confirmation.

Configuration

Set these as environment variables (the env block in your client config, or -e with docker run) or pass the matching flag.

VariableFlagDefaultWhat it does
KARGO_BASE_URL--kargo-urlhttp://localhost:8080Your Kargo API URL
KARGO_AUTH_MODE--auth-modeadminadmin, static, or passthrough
KARGO_ADMIN_PASSWORD—nonePassword when using admin mode
KARGO_STATIC_BEARER_TOKEN—noneToken when using static mode
KARGO_PROJECT--projectnoneDefault project
KARGO_VERIFY_SSL--insecure-skip-tls-verifytrueVerify the Kargo TLS certificate
MCP_ALLOW_WRITE--allow-writefalseEnable tools that change Kargo
MCP_TOOLSETS--toolsetsallLimit tools: pipeline, promotion, verification, credentials, rbac, diagnostics, readonly
MCP_TRANSPORT--transportstdiostdio or http
MCP_PORT--port8766Port when using HTTP

Run uvx --from talkops-kargo-mcp-server kargo-mcp-server --help to see every option.

Running over HTTP

To share one server between several clients or run it remotely, start it in HTTP mode with Docker or uvx:

# With Docker (starts in HTTP mode by default)
docker run --rm -p 8766:8766 \
  -e KARGO_BASE_URL=https://kargo.example.com \
  -e KARGO_AUTH_MODE=static \
  -e KARGO_STATIC_BEARER_TOKEN=<your-kargo-token> \
  talkopsai/kargo-mcp-server:latest

# Or with uvx
MCP_TRANSPORT=http MCP_PORT=8766 uvx --from talkops-kargo-mcp-server kargo-mcp-server

Then point your client at http://localhost:8766/mcp:

{
  "mcpServers": {
    "kargo": {
      "url": "http://localhost:8766/mcp"
    }
  }
}

Agent Skills

Skills live in skills/. Each one is a SKILL.md playbook (plus optional references/ and offline scripts/) that teaches your AI assistant how to do a job safely, while the MCP server does the actual work. Tools are the hands, skills are the know-how.

To use them, copy the folders into your assistant's skills directory, for example:

git clone https://github.com/talkops-ai/talkops-mcp.git
cp -r talkops-mcp/src/kargo-mcp-server/skills/* ~/.claude/skills/

This folder is also a portable Agent Plugin (plugin.json + mcp.json + skills/), so plugin-aware clients can load the server and skills together.

SkillUse it to
onboarding-kargo-pipelinesSet up projects, warehouses, stages, and promotion steps.
promoting-and-approving-freightCheck which freight can move forward, approve it, and promote it.
rolling-back-kargo-stagesRoll a stage back to its last good freight in an emergency.
troubleshooting-kargo-pipelinesFind out why a warehouse, promotion, or verification failed.
managing-kargo-credentials-and-accessManage repository credentials and roles without exposing secrets.

Reference

All 20 tools

ToolAccessWhat it does
kargo_apply_analysis_templateWriteCreate or update an Argo Rollouts AnalysisTemplate or ClusterAnalysisTemplate for Kargo Stage verification.
kargo_apply_project_configWriteConfigure a Kargo ProjectConfig CRD (auto-promotion policies, webhook receivers, and UI links).
kargo_apply_promotion_taskWriteCreate or update a reusable Kargo PromotionTask or ClusterPromotionTask.
kargo_apply_stageWriteCreate or update a Kargo Stage, merging updates with existing Stage spec and validating DAG cycles.
kargo_apply_warehouseWriteCreate or update a Kargo Warehouse with Git, Image, or Helm Chart subscriptions.
kargo_approve_freightWrite (destructive)Manually approve a Freight bundle (by SHA-1 name or alias) for promotion to a target Stage.
kargo_delete_resourceWrite (destructive)Delete a Kargo Stage, Warehouse, PromotionTask, ClusterPromotionTask, or ProjectConfig after confirmation.
kargo_diagnose_stageReadDiagnose a Kargo Stage by correlating conditions, Promotion step traces, Verification AnalysisRuns, holds, and events (N-to-1).
kargo_diagnose_warehouseReadDiagnose a Kargo Warehouse by inspecting artifact discovery status, conditions, and deprecated Kargo v1.9–v1.12 fields (N-to-1).
kargo_manage_credentialsWrite (destructive)Create, update, or delete Kargo repository credentials, generic secrets, or ConfigMaps without exposing secret values.
kargo_manage_freightWrite (destructive)Update a Freight human-friendly alias, manually assemble a Freight item, or delete unused Freight.
kargo_manage_projectWrite (destructive)Create or delete a Kargo Project (cluster-scoped organizational boundary).
kargo_manage_promotionWrite (destructive)Abort a running/pending Kargo Promotion or refresh (wake) a waiting Promotion.
kargo_manage_rolesWrite (destructive)Create or delete a managed Kargo Role, or grant/revoke OIDC user claims and stage permissions.
kargo_manage_verificationWrite (destructive)Re-run (reverify) or abort a Stage's verification AnalysisRun, or delete an AnalysisTemplate.
kargo_promoteWritePromote Freight to a Stage (by SHA-1 name, alias, or origin Warehouse) or to all immediate downstream Stages.
kargo_query_freightReadQuery and filter Kargo Freight bundles in a project by stage availability, origin Warehouse, or alias.
kargo_refreshWriteTrigger immediate reconciliation or artifact discovery on a Warehouse, Stage, Promotion, ProjectConfig, or ClusterConfig.
kargo_rollback_stageWrite (destructive)Roll back a Kargo Stage to a previous known-good Freight using Kargo's roll-forward promotion model (N-to-1).
kargo_trace_freightReadTrace a Freight bundle or versioned artifact across all Stages in a Kargo project (N-to-1).

All 18 resources

ResourceWhat it returns
kargo://projectsList all Kargo Projects with readiness status
kargo://server/capabilitiesServer write mode, enabled toolsets, Kargo API connectivity, and Kargo version
kargo://cluster-promotion-tasks/{task}Sanitized YAML manifest for a cluster-scoped ClusterPromotionTask
kargo://projects/{project}Project status and ProjectConfig (promotionPolicies, webhookReceivers, generated webhook URLs)
kargo://projects/{project}/analysis-runs/{run}Verification AnalysisRun status and metric results
kargo://projects/{project}/analysis-runs/{run}/logsJob-metric container logs for a verification AnalysisRun
kargo://projects/{project}/analysis-templatesProject AnalysisTemplates and cluster-scoped ClusterAnalysisTemplates available for Stage verification
kargo://projects/{project}/credentialsRedacted repository credentials, generic credentials, and ConfigMaps in a Kargo project (secret values are never exposed)
kargo://projects/{project}/eventsRecent Kubernetes Events in a Kargo project
kargo://projects/{project}/freight/{freight_or_alias}Detailed Freight bundle (SHA-1 id, alias, origin Warehouse, commits, images, charts, stage states)
kargo://projects/{project}/pipelineComplete pipeline DAG topology (Warehouses -> Stages), current Freight, health, auto-promotion, and holds
kargo://projects/{project}/promotion-tasks/{task}Sanitized YAML manifest for a project PromotionTask
kargo://projects/{project}/promotionsRecent Promotions in a Kargo project with phase and timestamps
kargo://projects/{project}/promotions/{promotion}Detailed Promotion execution trace (phase, message, per-step status, timings, outputs)
kargo://projects/{project}/rolesKargo RBAC Roles, OIDC claim bindings, and permissions in a project
kargo://projects/{project}/stages/{stage}Concise Stage status (phase, health, currentFreight, verification, promotions, holds, conditions)
kargo://projects/{project}/stages/{stage}/manifestSanitized YAML manifest for a Kargo Stage (strips managedFields and redacts literal env secrets)
kargo://projects/{project}/warehouses/{warehouse}Concise Warehouse status, subscriptions, lastFreightID, and discoveredArtifacts

Development

git clone https://github.com/talkops-ai/talkops-mcp.git
cd talkops-mcp/src/kargo-mcp-server
uv sync --dev
uv run pytest
uv run kargo-mcp-server --help

Get help

License

Apache 2.0. See LICENSE.