{
  "markdown": "# hatchet-mcp\n\n[![CI](https://github.com/ElliotPadfield/hatchet-mcp/actions/workflows/ci.yml/badge.svg)](https://github.com/ElliotPadfield/hatchet-mcp/actions/workflows/ci.yml)\n[![npm version](https://img.shields.io/npm/v/hatchet-mcp.svg)](https://www.npmjs.com/package/hatchet-mcp)\n[![license: MIT](https://img.shields.io/badge/license-MIT-blue.svg)](./LICENSE)\n\nAn MCP server that lets AI agents observe and operate [Hatchet](https://hatchet.run) workflows — status, runs, logs, workers, and metrics, plus trigger / cancel / replay.\n\n**Why:** Hatchet has a great API but no MCP. This wraps it so agents (Claude Code / Desktop, etc.) can see and act on workflow state.\n\n## Install\n\nAdd this to your Claude Code / Claude Desktop MCP config:\n\n```json\n{\n  \"mcpServers\": {\n    \"hatchet\": {\n      \"command\": \"npx\",\n      \"args\": [\"-y\", \"hatchet-mcp\"],\n      \"env\": { \"HATCHET_CLIENT_TOKEN\": \"<your-hatchet-api-token>\" }\n    }\n  }\n}\n```\n\nGet the token from the Hatchet dashboard → **API tokens**. The token is a JWT that encodes the server URL and tenant, so it's the only required setting.\n\n## Configuration\n\n| Variable | Required | Description |\n| --- | --- | --- |\n| `HATCHET_CLIENT_TOKEN` | Yes | Hatchet API token (JWT). Encodes the server URL + tenant, so it's normally all you need. |\n| `HATCHET_API_BASE` | No | Override the API base URL. Self-hosters can point this at any Hatchet instance. |\n| `HATCHET_TENANT_ID` | No | Override the tenant id decoded from the token. |\n\nSelf-hosting? Set `HATCHET_API_BASE` to your own Hatchet instance and it works anywhere.\n\n## Tools\n\n### Observability (read-only)\n\n| Tool | Description |\n| --- | --- |\n| `whoami` | Show the resolved Hatchet tenant + server URL and confirm the token works. |\n| `list_workflows` | List workflow definitions for the tenant. |\n| `list_runs` | List workflow runs (with an optional lookback window and filters). |\n| `get_run` | Get the full detail of one workflow run — status, tasks, errors. |\n| `get_run_logs` | Get log lines for a task by its external id. |\n| `list_workers` | List workers and their status. |\n| `get_queue_metrics` | Get task/queue metrics for the tenant (queue health). |\n\n### Actions (mutate live state)\n\n| Tool | Description |\n| --- | --- |\n| `trigger_workflow` | Trigger a new workflow run by name with a JSON input payload. |\n| `cancel_runs` | Cancel one or more runs/tasks by external id. |\n| `replay_runs` | Replay/retry one or more runs/tasks by external id. |\n\n## Safety\n\nThe read tools (`whoami`, `list_workflows`, `list_runs`, `get_run`, `get_run_logs`, `list_workers`, `get_queue_metrics`) are non-destructive.\n\n`trigger_workflow`, `cancel_runs`, and `replay_runs` **mutate live state** — their descriptions are prefixed `MUTATES LIVE STATE` so agents and users know they affect real runs.\n\nThe token grants full tenant access — treat it as a secret. Never commit it to source control.\n\n## Development\n\n```bash\npnpm install\npnpm test    # vitest\npnpm build   # tsup -> dist/index.js\n```\n\nTypeScript / ESM, tested with [vitest](https://vitest.dev).\n\n## Status\n\nv0.1.0 — all tools verified against Hatchet Cloud; works with self-hosted instances via `HATCHET_API_BASE`. `trigger_workflow` uses the stable `/workflow-runs/trigger` endpoint.\n",
  "bytes": 3240,
  "sha": "ff4ae537d224df7d5b4fbf443af868a044fe70aefcee34bd61332cedc08139fb",
  "repo_slug": "elliotpadfield/hatchet-mcp",
  "fonte": "repo",
  "truncated": false,
  "api": "https://agentalog.com/api/listings/mcp_io_github_elliotpadfield_hatchet_mcp_6b843885/readme"
}