devin-subagents
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., "@devin-subagents spawn 'auth-fix' to add JWT auth middleware and tests"
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.
devin-subagents
简体中文: README_zh.md
Expose devin acp sessions as lifecycle-managed subagents over MCP: parallel dispatch, blocking coordination, mid-flight steering, permission adjudication, and crash-resilient session persistence.
MCP Host ──stdio/MCP──▶ devin-subagents ──stdio/ACP──▶ devin acpAsync dispatch:
spawnstarts a background Devin session and returns immediately ({status: "running"}).Blocking coordination:
waitblocks until the subagent completes, reports progress, requests permissions, or times out.Direct delivery:
wake="done"delivers the complete turn output directly inoutput.text—no secondary query needed.Inbox piggybacking: Unread completion notices and
report()checkpoints automatically ride along in theinboxfield of subsequent MCP tool responses.Hidden sessions: Subagent sessions are marked hidden by default to keep host session lists clutter-free.
Requirements
Node.js ≥ 20 (Session hiding requires
node:sqlitein Node ≥ 22.5; older versions gracefully degrade without breaking core functionality).Authenticated
devinCLI (The bridge manages a backgrounddevin acpprocess).
Related MCP server: ChatGPT Gateway MCP Nyan
Installation
Standard Setup
Register MCP Server: Add to your MCP host configuration:
{ "mcpServers": { "devin": { "command": "npx", "args": ["-y", "devin-subagents"] } } }Note: The server's
cwddetermines the resolution path for.devin-subagents.json(state persistence) and optionaldevin-subagents.config.json. If your host cannot pincwd, pass--config /path/to/config.jsoninargsand specify an absolutestatePathin your config.Install Skill:
npx skills add Duro02/devin-subagents -g -a <harness>Or manually copy or symlink
skills/devin-subagents/to your host's skills directory.
Agent Self-Installation (Recommended)
Paste this prompt directly to your host agent:
Install devin-subagents into this harness—both the stdio MCP server and the skill. Source: https://github.com/Duro02/devin-subagents (use an existing local clone if available).
1. Register a stdio MCP server named `devin` following this harness's conventions: `npx -y devin-subagents`.
2. Install the skill: `npx skills add Duro02/devin-subagents -g -a <this_harness>`; if that fails, copy or symlink `skills/devin-subagents/` into its user-level skill directory.
3. Verify the MCP server is registered and the skill is visible, then prompt me to restart or reload the harness.Usage
spawn("coder-auth", "Implement JWT middleware in src/auth and add unit tests", cwd="/path/to/project")
→ returns immediately: {status: "running"} # devin acp runs in the background
wait("coder-auth", 240000) # blocks until attention is needed
→ wake="done" output.text = full turn output (deliverables here, no extra query)
→ wake="report" subagent called report(message) checkpoint
→ wake="permission" permission request pending → adjudicate with permission("coder-auth", optionId)
→ wake="timeout" still running, returns live snapshot; call wait again to continue
→ wake="stopped"|"dead" subagent stopped or exited; revive with resume("coder-auth")
→ wake="cancelled" wait aborted by cancellation signal; underlying turn continuesCoordination Patterns
Work remains: If the host supports background tasks, run
waitin the background, or continue with other tasks—completion notices andreport()updates will automatically arrive via theinboxfield of subsequent tool results.No work remains: Call
waitdirectly to block until an event wakes it.Timeout safety: Keep
timeout_msbelow your host's tool execution deadline (a host-level hard cutoff yields an unhandled error instead of a structuredtimeoutsnapshot).Mid-flight steering: Use
sendto append instructions (queued in FIFO order during active turns, strictly serialized per session),interruptto cancel the in-flight turn and clear the queue (retains the session), orstop/resumefor lifecycle transitions.Inspection over polling: Always use
waitto wait—never poll in a loop withpoll. Usepollsolely for diagnostics:detail="inspect"provides a live snapshot withactiveTools[].elapsedMsto spot stalled tools;detail="logs"retrieves the chronological event stream.Session visibility: Subagents are marked hidden by default to avoid cluttering
/resume,devin list, and ACPsession/list(sethideFromSessionList: falseto disable).
Tools
Tool | Description |
| Launch a Devin subagent asynchronously; returns |
| Block until attention is needed ( |
| Append follow-up instructions. Queued FIFO during an active turn; strictly serialized per session. |
| Inspect state: |
| Adjudicate a pending permission request (provide |
| Cancel the in-flight turn ( |
| Interrupt running turn, clear queue, and mark the session stopped. |
| Re-activate a stopped, dead, or persisted session (survives bridge restarts). |
| List all live, persisted, and agent-side sessions with status. |
| Switch session permission mode (e.g. |
| Query advertised models and modes (session-specific or bridge defaults). |
| Switch the model for an idle session (e.g. |
Configuration
Optional. Place devin-subagents.config.json in the server's working directory or specify via --config PATH. The configuration schema is strict: unknown keys will cause an error on startup.
Key | Default | Description |
|
| Agent executable command (resolved via PATH or relative to config file). |
|
| Command-line arguments passed to the agent process. |
|
| Path for name→sessionId persistence map (survives bridge restarts). |
|
| Permission policy: |
|
| Default permission mode for new sessions. |
|
| Default model confirmed for new sessions. |
|
| Timeout in milliseconds for non-prompt ACP RPC calls. |
|
| Maximum capacity of each session's event ring buffer. |
|
| Mark sessions with |
|
| Inject |
|
| Automatically enqueue completion and permission events into the |
|
| Append a hint to the spawn prompt informing the subagent of the |
Full example: devin-subagents.config.example.json.
Development
npm test # Deterministic unit tests with built-in mock ACP agent (no external services needed)
npm run smoke # Smoke handshake test against a real agent
npm run e2e # End-to-end integration test (requires Devin credentials)Available Tools
12 toolsinterruptInterrupt a subagentA
Cancel the in-flight turn (ACP session/cancel) and drop queued messages. The session stays alive and resumable.
Inputs: name (required).
listList subagentsA
List live, persisted, and agent-side sessions with status.
Inputs: no named parameters.
modelsReport advertised models/modesA
With 'name': the session's current model/mode and the agent-advertised available lists. Without: the bridge's configured defaults plus the last-advertised agent-level lists (null until the first session is created). Devin model ids are e.g. swe-2-medium / swe-2-high / swe-2-max.
Inputs: name.
permissionAnswer a permission requestA
Grant or deny a pending tool-permission request surfaced by poll (used when permission=operator — the calling agent decides). Pass optionId to approve, omit to deny.
Inputs: name (required), optionId.
pollInspect a subagent or read its event logA
Two observation modes. detail='inspect' (default): a persistent snapshot of what the subagent is doing — lifecycle fields, pending permission, current/latest turn timing and duration, last actual output, active tool calls (merged by id, with elapsed ms), current plan step, latest text, latest error, and last-activity/last-content ages. It is independent of the event log: unaffected by reads or by buffer eviction. detail='logs': the chronological normalized event log (message/thinking/tool/plan/usage/mode/queued/turn_start/turn_end/permission_*) with seq and bridge receipt timestamps, paged by an implicit read cursor; 'limit' bounds each page and nextCursor/hasMore continue it, droppedEvents counts buffer-evicted events. 'since': in inspect mode, a snapshot cursor — wait_ms blocks for events newer than it; in logs mode it replays events after that seq without moving the read cursor. wait_ms blocks briefly while a turn can still produce events.
Inputs: name (required), limit, since, detail, +1 more.
resumeResume a subagentA
Re-activate a stopped/dead/persisted Devin session (survives bridge restarts). Safe no-op on already-running subagents.
Inputs: name (required).
sendSend a message to a subagentA
Send a follow-up prompt to a subagent. While a turn is running the message is queued in FIFO order and starts as the next turn once the current one finishes (turns are strictly serialized per session). Stopped/dead subagents must be resumed first.
Inputs: name (required), text (required).
set_modeChange a subagent's permission modeA
Switch the session's mode (e.g. 'bypass', 'smart'). Validated against the session's advertised availableModes when known.
Inputs: mode (required), name (required).
set_modelChange a subagent's modelA
Switch an idle session's model via session/set_config_option and confirm the echoed value (e.g. 'swe-2-high'). Rejected while the session is starting/running/stopped/dead — resume or wait for idle first. Validated against the advertised model list when known.
Inputs: name (required), model (required).
spawnSpawn a Devin subagentA
Create a new Devin session and start it on a task in the background. Returns immediately; use poll to watch progress. Multiple subagents can run in parallel.
Inputs: name (required), task (required), cwd, mode, +1 more.
stopStop a subagentA
Interrupt any running turn, drop queued messages and mark the subagent stopped. The session is kept and can be continued later with resume.
Inputs: name (required).
waitWait until a subagent needs attentionA
Block until the subagent needs you, then return what happened. Wakes on: turn drained to idle (wake='done'), a pending permission request (wake='permission' — answer via the permission tool), a report() checkpoint from the subagent (wake='report' — a report is delivered once, even if it arrived before this call), terminal states (wake='stopped'/'dead'), or timeout (wake='timeout', snapshot shows live state). Already-attention states return immediately, so it doubles as 'is it done?'. On hosts supporting MCP tasks this runs as a background task; elsewhere it blocks.
Inputs: name (required), timeout_ms.
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelog…
TDQS
Scored across 12 tools
Most tools have distinct purposes: spawn creates sessions, send queues prompts, poll and wait observe but in different modes (snapshot vs. event log vs. blocking on attention), interrupt/stop/resume manage lifecycle, list enumerates, permission handles approvals, set_mode/set_model configure. Minor overlap between poll and wait (both report on state) but their interfaces are distinct enough to disambiguate.
Most are short imperative verbs (spawn, send, poll, wait, interrupt, stop, resume, list, permission) with a few two-word names (set_mode, set_model). The style is consistent (all lowercase, underscore for compound names), but the verbs are not a predictable verb_noun pattern (e.g., no create_session vs. list_sessions). Some naming like 'permission' is a noun rather than a verb (grant_permission would be clearer).
Twelve tools is well-scoped for a subagent management server. Each tool addresses a distinct lifecycle aspect: creation, communication, observation, control, listing, permission, and configuration. No redundancy in count, and the size supports both granular control and ease of discovery.
The surface covers the full lifecycle: create (spawn), interact (send), observe (poll/wait), control (interrupt/stop/resume), enumerate (list), authorize (permission), and configure (set_mode/set_model). Missing features like killing without resume or session cleanup are not core gaps; they're likely handled via stop and resume. The tool set is comprehensive for subagent management.
Maintenance
Related MCP Connectors
Hosted MCP memory and agent control plane for durable conversations, jobs, and operations.
- aXDeprecatedio.github.ax-platform
Agent-native collaboration network: orchestrate a team of long-running agents from any MCP client.
MCP-first control plane for ProAgentStore agents and private instances.
Coordinate multiple AI agents over MCP: atomic claims, leases, shared ledger, handoffs, tasks.
Related MCP Servers
- FlicenseNot gradedqualityBmaintenanceAgent orchestration system that runs coding-agent sessions (Claude Code, Codex) with policy mediation and exposes tools via MCP.-
- AlicenseNot gradedqualityBmaintenanceEnables agent clients to safely connect to tools and execution resources through MCP with authorization, approvals, audit, chat-context isolation, SSH/Docker access, and long-running command session tracking.MIT
- AlicenseBqualityBmaintenanceEnables launching and supervising local Codex and Claude Code agent sessions and one-shot tasks, exposing run, list, stop, and output operations over MCP with session-scoped permissions and sandbox controls.2264 npm1MIT
- AlicenseBqualityBmaintenanceEnables any MCP host to delegate work to multiple coding-agent CLIs such as Codex, Claude Code, and Antigravity as subagents, preserving native sessions and supporting team-based supervision and agent-to-agent messaging.179 npmApache 2.0