herdr-mcp
Click on "Deploy Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@herdr-mcp Which of my agents are blocked?"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
"Which of my agents are blocked?"
You: Which of my agents are blocked? Assistant: Let me check your herdr agents... ┌──────────┬─────────┬────────┐ │ AGENT │ STATUS │ PANE │ ├──────────┼─────────┼────────┤ │ docs │ blocked │ w2:p1 │ │ refactor │ blocked │ w1:p3 │ └──────────┴─────────┴────────┘ Two agents are blocked. "docs" is waiting on a review decision in w2:p1. "refactor" hit a merge conflict in w1:p3. Want me to prompt either of them?
Features
🔍 Monitor | List agents, check status (idle/working/blocked/done), read recent output |
🚀 Control | Start agents, send prompts, manage terminal panes |
🔒 Safe by default | Read-only tools always on; write tools require explicit opt-in |
🌐 Remote support | Target agents on remote machines via |
🤖 Universal | Works with Grok Bot, Cursor, Claude, and any MCP client |
Related MCP server: goose-herdr
Quick Install
Every snippet below starts herdr-mcp read-only. See Safety Model to turn on write tools.
Grok Bot (X plugin marketplace)
Install the herdr-mcp plugin from the Grok Bot marketplace. To let the assistant start or prompt agents, set Enable write operations to 1 in the plugin settings.
Cursor
Add to .cursor/mcp.json in your project, or ~/.cursor/mcp.json for all projects:
{
"mcpServers": {
"herdr": {
"command": "npx",
"args": ["-y", "herdr-mcp"]
}
}
}Claude Code
claude mcp add herdr -- npx -y herdr-mcpClaude Desktop
Add to ~/Library/Application Support/Claude/claude_desktop_config.json on macOS:
{
"mcpServers": {
"herdr": {
"command": "npx",
"args": ["-y", "herdr-mcp"]
}
}
}Any MCP Client
npx -y herdr-mcpherdr-mcp speaks MCP over stdio and needs the herdr binary on PATH (Node.js 20+).
Safety Model
herdr-mcp is read-only by default. Assistants can watch your agents but can't change anything until you opt in.
Mode | Tools offered | Enable with |
Read-only (default) | The 8 read tools | Nothing |
Read + write | The 8 read tools plus the 6 write tools |
|
To opt in, add an env block to the server config:
"env": { "HERDR_MCP_ALLOW_WRITE": "1" }In read-only mode the write tools aren't registered: they don't appear in the assistant's tool list, and calling one by name fails before herdr ever runs.
No shell passthrough. There is no tool for herdr's
pane runorpane send-text, or anything else that runs an arbitrary command. herdr is launched with an argument array and no shell, so nothing is interpolated.No flag injection. IDs, agent names, kinds, and keys are validated so they can't be read as herdr options. Prompt text goes in herdr's verbatim text slot, so a prompt like
--waitstays text.Bounded calls. Every herdr call has a timeout (5 minutes at most for waits), a 256 KiB output cap, and is cancelled when the client cancels the request. A herdr process that ignores SIGTERM gets SIGKILL.
Tool annotations. Read tools are marked
readOnlyHint.herdr_agent_prompt,herdr_agent_send_keys, andherdr_pane_closeare markeddestructiveHint, so clients that honor annotations can ask before running them.
One caveat for write mode: herdr_agent_start passes agent_args straight through to the agent's own CLI. Those can include flags that loosen the agent's safety settings, so only approve args you'd type yourself.
Tools
Tool names are stable across releases.
Read-only tools (always offered)
Tool | Description |
| Check that the herdr server is running and report its version |
| List workspaces |
| List tabs, optionally in one workspace |
| List panes, optionally in one workspace |
| List agents with status (idle/working/blocked/done/unknown) |
| Get one agent's status, pane, cwd, and session info |
| Read recent terminal output from an agent as plain text |
| Wait until an agent reaches a status, with a timeout |
Write tools (offered only with HERDR_MCP_ALLOW_WRITE=1)
Tool | Description |
| Create a tab whose root pane is an empty shell; doesn't take focus unless |
| Start an agent ( |
| Send a prompt to an agent, optionally waiting for it to settle |
| Send key presses such as |
| Rename an agent |
| Close a pane and kill whatever runs in it |
Remote Machines
Point herdr-mcp at a machine you've saved in herdr (herdr machine add, then herdr machine list):
{
"mcpServers": {
"herdr-workbox": {
"command": "npx",
"args": ["-y", "herdr-mcp"],
"env": {
"HERDR_MCP_MACHINE": "Build machine"
}
}
}
}Every command is sent as herdr --machine "Build machine" ..., which herdr forwards over SSH to that machine's server. The value must be a saved profile label or ID, not a hostname. Workspace, pane, and agent IDs belong to that machine. To watch several machines, add one server entry per machine.
Usage Patterns
Monitor-first approach
Always check agent status before taking action:
1. herdr_agent_list → see all agents and their states
2. herdr_agent_read → check what an agent has been doing
3. herdr_agent_prompt → only if needed, with human approvalStart-then-prompt recipe
When the user asks for a new agent:
1. herdr_tab_create → returns root_pane.pane_id, an empty shell
2. herdr_agent_start → returns once the agent is ready for input
3. herdr_agent_prompt → send the task the user approvedCritical caveat
The target pane must be at an idle shell prompt before herdr_agent_start. herdr refuses to start an agent in a pane that's running anything else, so create a fresh tab first.
The bundled skills/herdr/SKILL.md teaches assistants these patterns, along with herdr's error codes and when to ask a human.
Development
git clone https://github.com/sunnyvempati/herdr-mcp.git
cd herdr-mcp
npm ci
npm run build
npm test # MCP-surface and runner tests against a fake herdr
npm run typecheckThe tests drive the built server through the official MCP client. src/test/fake-herdr.ts stands in for the herdr binary: it enforces herdr 0.9.5's argument grammar and replies with output captured from real herdr.
Smoke test (requires herdr with a running server)
npm run smoke # or ./scripts/smoke.shIt exercises every read-only tool against your real herdr and never enables write mode. Set HERDR_MCP_MACHINE to smoke-test a remote machine.
Contributing
See CONTRIBUTING.md. Coding agents (and humans) should read AGENTS.md for the engineering principles this repo follows.
License
Available Tools
8 toolsherdr_agent_getGet agentARead-onlyIdempotent
Get one agent's status, pane location, working directory, terminal title, and session info.
Inputs: agent (required).
herdr_agent_listList agentsARead-onlyIdempotent
List the coding agents herdr recognizes, with each agent's status (idle/working/blocked/done/unknown) and pane. The primary monitoring tool.
Inputs: no named parameters.
herdr_agent_readRead agent outputARead-onlyIdempotent
Read recent terminal output from an agent's pane as plain text. Use it to see what an agent did, what it is asking, or why it failed.
Inputs: agent (required), lines, source.
herdr_agent_waitWait for agentARead-onlyIdempotent
Wait until an agent reaches a status. Without 'until', waits for idle, done, or blocked. Returns immediately if the agent already matches.
Inputs: agent (required), until, timeout_ms.
herdr_pane_listList panesBRead-onlyIdempotent
List panes. A pane is a real terminal that survives client detach; it may hold a shell, a process, or a coding agent.
Inputs: workspace_id.
herdr_statusherdr statusARead-onlyIdempotent
Check that the herdr server is running and report its version. Call this first if other herdr tools fail.
Inputs: no named parameters.
herdr_tab_listList tabsARead-onlyIdempotent
List tabs. Tabs are layouts inside a workspace; each contains one or more panes.
Inputs: workspace_id.
herdr_workspace_listList workspacesARead-onlyIdempotent
List herdr workspaces. A workspace is a project-level container that owns tabs and panes and rolls up agent states.
Inputs: no named parameters.
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelog…
TDQS
Scored across 8 tools
Each tool has a distinct purpose: status check, lists for workspaces/tabs/panes, and agent-specific operations (list, get, read, wait). The list/read/wait agent tools are clearly differentiated by their descriptions, so an agent can easily choose the right one.
Almost all tools follow a consistent herdr_ prefix and noun_verb pattern (e.g., herdr_workspace_list, herdr_agent_get). The only deviation is herdr_status, which lacks a verb, but it remains readable and predictable overall.
8 tools is a well-scoped set for a monitoring-focused server. Each tool earns its place by covering a distinct resource or agent operation without redundancy.
The surface covers listing workspaces, tabs, panes, and agents, plus detailed agent monitoring (get, read, wait) and server status. However, it lacks get operations for workspaces, tabs, or panes, and offers no control actions (e.g., create, close, start agent), which are minor gaps for a monitoring server.
Maintenance
Related MCP Connectors
Use your own Windows, Mac or Linux computer from ChatGPT, Claude, Cursor or Gemini CLI: run commands, read, write and search files, run long processes. Your computer only makes an outgoing connection (no open ports or VPN). Read-only mode, allowed folders, blocked commands and an action log keep you in control. Free plan available.
Use your Mac, Windows or Linux computer from ChatGPT, Claude or Codex: files, commands, documents.
Operate Linux, macOS and Windows from your LLM. Every action runs through an auditable allowlist.
Give your AI hands on every computer you own. Remote control of your Windows, Mac and Linux machines from one ChatGPT, Claude or Cursor chat — even from your phone. Ask it to find out why the office server is crawling, update every PC in the house, sort out your mom's laptop from another city, or ship the site from your work machine while you're on a train. It runs commands and reads and writes files; screenshots are a beta you can request. You decide what each computer allows, and you can cut any of them off in a second.
Related MCP Servers
- AlicenseNot gradedqualityDmaintenanceEnables AI assistants to orchestrate Herdr coding agents by wrapping its Unix-socket JSON-RPC API, providing tools for agent management, layout editing, and terminal interaction.ISC
- AlicenseNot gradedqualityDmaintenanceEnables goose to control the Herdr terminal workspace manager, allowing AI agents to inspect and manipulate workspaces, tabs, panes, run commands, and manage agent states.3MIT
- FlicenseAqualityDmaintenanceEnables coding agents to control and inspect a running Herdr terminal session, including listing workspaces, tabs, panes, and agents, reading pane output, prompting agents, sending keys and commands, waiting for output or state, and splitting or closing panes.14-
- AlicenseNot gradedqualityFmaintenanceEnables AI agents to securely spawn, monitor, and control terminal sessions in Herdr, supporting background execution and authenticated access.2MIT