Gocd

io.github.Sahilll15由 GitHub 帳號 Sahilll15 發布v0.1.2更新於 Oct 24, 2026

MCP server for GoCD: dashboard, pipelines, artifacts, agents. Context-lean output.

概覽

AI 產生的概覽

讓助理讀取 GoCD 的流水線、階段、代理與成品狀態,並可觸發、暫停或恢復流水線。

可以做什麼
把 GoCD 的 REST API 包裝成 MCP 工具。讀取類工具涵蓋儀表板、流水線狀態、單次執行與歷史、階段執行與歷史、兩次執行比較、成品、代理、材料、環境、流水線群組、伺服器健康與版本。三個寫入類工具可排程流水線執行、暫停流水線或恢復流水線。輸出經過彙總並以欄位導向呈現,保持精簡。
適用情境
當助理需要查看 GoCD 伺服器上的持續交付狀態時使用,例如排查流水線失敗原因、比較兩次執行或讀取建置成品。也適合在聊天用戶端中觸發或暫停流水線。
執行需求
以 stdio 方式在本機執行,可用 Node 18 以上版本的 npx、Go 二進位檔或 Docker 映像。需要 GOCD_BASE_URL(裸主機名稱,結尾不加 /go)與 GOCD_ACCESS_TOKEN(在使用者設定中建立的 GoCD 個人存取權杖)。需要能連線到 GoCD 伺服器的網路。
安裝前請注意
GOCD_ACCESS_TOKEN 是機密,具備該 GoCD 帳號的全部權限。寫入類工具 gocd_trigger_pipeline、gocd_pause_pipeline 與 gocd_unpause_pipeline 會改變伺服器狀態;設定 GOCD_READONLY=1 可將它們隱藏。成品內容與流水線資料會傳送給模型供應商。

安裝

在 SourceWeft 中

  1. 開啟 儀表板中的 Gocd,將其新增到工作區。
  2. 為需要使用其工具的對話啟用該服務。

Desktop only,透過 STDIO。 STDIO 服務會啟動本機處理程序,因此需要 SourceWeft 桌面主機。

其他 MCP 客戶端

參照 儲存庫 中的啟動說明。

README

gocd-mcp

An MCP server for GoCD. It exposes GoCD's REST API as MCP tools so any MCP client (Claude Code, Claude Desktop, Cursor) can read pipeline state and drive pipelines. Two implementations live here and behave identically on the wire: pick whichever fits how you want to install it.

  • go/ — Go implementation. Ships as a single static binary or a Docker image. Fast cold start, low memory.
  • ts/ — TypeScript implementation. Runs on Node with no dependencies, so npx needs no build step.

Both return the same context-lean output: the dashboard is summarized by default, rows are column-oriented, and responses are compact JSON. A full GoCD dashboard is several MB across many pipelines; these tools trim it to what the model needs.

Tools

Read tools (safe):

ToolWhat it does
gocd_dashboardDashboard health. No args = summary; filter/status/detail drill down
gocd_pipeline_statusPaused / locked / schedulable for one pipeline
gocd_pipeline_instanceOne run: stages with per-job result, plus trigger
gocd_pipeline_historyRecent runs for one pipeline. Optional limit
gocd_stage_instanceOne stage run with per-job state and agent
gocd_stage_historyRecent runs of one stage
gocd_compareWhat changed between two runs: commits per material
gocd_list_artifactsA job's artifact files as [path, url]
gocd_get_artifactOne artifact file, tail-capped (cap_kb) to stay context-lean
gocd_list_agentsBuild agents and state. Optional filter, limit
gocd_get_agentOne agent by uuid
gocd_materialsConfigured materials. Optional filter
gocd_environmentsEnvironments and their pipeline/var counts
gocd_pipeline_groupsPipeline groups. Filter to list a group's pipelines
gocd_server_healthServer health messages, counted by level
gocd_versionGoCD server version

Write tools (operate):

ToolWhat it does
gocd_trigger_pipelineSchedule a pipeline run
gocd_pause_pipelinePause a pipeline
gocd_unpause_pipelineResume a pipeline

Set GOCD_READONLY=1 to hide the three write tools. Large listings (dashboard, pipeline_groups, materials, environments) are summarized or filterable so they never dump the raw multi-MB body into the model's context.

Configuration

Two environment variables, both required:

GOCD_BASE_URL=https://gocd.example.comGOCD_ACCESS_TOKEN=<personal access token>

GOCD_BASE_URL is the bare host, without a trailing /go. The tools append /go/api/... themselves. Create the token in GoCD under your profile, Personal Access Tokens.

Install

npx (Node >= 18), recommended

Zero install, nothing to build. This is the simplest way to run the server:

bash
claude mcp add gocd -e GOCD_BASE_URL=... -e GOCD_ACCESS_TOKEN=... -- npx -y gocd-mcp

Published on npm as gocd-mcp and on the MCP Registry as io.github.Sahilll15/gocd, so registry-aware clients can find it by name.

Go binary

Download a prebuilt binary from Releases, or build it:

bash
cd go && go build -o gocd-mcp .

Register it:

bash
claude mcp add gocd -e GOCD_BASE_URL=... -e GOCD_ACCESS_TOKEN=... -- /path/to/gocd-mcp

Docker

bash
claude mcp add gocd -e GOCD_BASE_URL=... -e GOCD_ACCESS_TOKEN=... \  -- docker run -i --rm -e GOCD_BASE_URL -e GOCD_ACCESS_TOKEN ghcr.io/sahilll15/gocd-mcp

To run the TypeScript source directly during development (Node >= 22.6, uses type-stripping):

bash
cd ts && node --experimental-strip-types src/server.ts

Which one

They are functionally identical. In a local benchmark the Go build started about 4x faster (~21ms vs ~80ms cold start) and used about 6x less memory; per-request latency was a tie because the GoCD network round-trip dominates. Prefer the Go binary or Docker image for a spawned-per-session server; prefer npx when you want the zero-install path and already have Node.

Layout

gocd-mcp/├── go/            Go implementation (main.go, internal/gocd)├── ts/            TypeScript implementation (src/server.ts source; publishes as compiled dist/server.js)├── Dockerfile     builds the Go binary into a distroless image├── .goreleaser.yaml + .github/workflows/release.yml   prebuilt binaries + ghcr image on tag└── server.json    MCP Registry manifest

來源:README.md,提交 c03fa4f

工具

0
SourceWeft 尚未在沙箱中啟動過該軟體包,因此其工具未知。

版本歷史

1
  1. v0.1.2最新Sep 16, 2026

評分

已滿足適用檢查項的 40%

該評分衡量此收錄條目的完整程度,依據註冊中心條目、端點與公開來源計算得出。它不是對伺服器本身的評價,也不表示伺服器安全或目前可用:可連通性是帶日期的檢查結果,評分也不包含安裝量或使用者評價。

  • 近 30 天內可連通25 分

    請保持端點能夠回應 MCP 握手;SourceWeft 每 30 天探測一次。

  • 已宣告認證方式10 分

    請在註冊中心條目中宣告憑證請求標頭,或保持端點能夠回應探測,以便判定其認證方式。

  • 已列出工具15 分

    請讓伺服器在無憑證時回應 tools/list,或發布可在沙箱中無憑證啟動的軟體包。

  • 描述必需15 分
  • 圖示10 分
  • 文件15 分
  • 授權條款10 分

    請在儲存庫或註冊中心條目中宣告授權條款。