feat(managed_agents): CMA Sessions API as an MCP server (stdio + HTTP)#617
Conversation
/model-check findingsReviewed model references in the changed files:
No Claude model IDs are referenced in any of the three files (no The files describe the MCP server's structure, setup paths, and tool wrappers — model selection is delegated to the CMA-side agent configuration (created via the One note (not a blocker)
✅ No action required for model usage. |
Thin MCP server wrapping Managed Agents sessions so Claude Desktop or claude.ai can drive hosted CMA agents via tool calls. DIY bridge until 'publish agent to claude.ai' is first-class. 9 tools in shared src/tools.ts — 8 are 1:1 endpoint wrappers; wait_for_idle is the SSE→request/response shim. Two entrypoints: server.ts (stdio, Desktop) and server-http.ts (Streamable HTTP + bearer auth, claude.ai Connector). Dockerfile for Fly/Railway/Render. list_agents capped + name_contains filter (busy workspaces hang auto-pagination). Authoring/destructive/secret endpoints deliberately excluded. README forks on client; CLAUDE.md invokes /claude-api; skill.md has Desktop + Connector setup, relay-mode Project instructions, org-admin gating note. stdio path proven e2e in Claude Desktop; HTTP smoke-tested via ngrok.
25208da to
a090206
Compare
A thin MCP server wrapping the Managed Agents Sessions API, so Claude Desktop or claude.ai web can start and chat with an org's hosted CMA agents via tool calls. DIY bridge until "publish agent to claude.ai" is first-class.
managed_agents/cma-mcp/9 tools (shared
src/tools.ts) — 8 are 1:1 endpoint wrappers;wait_for_idleis the one SSE→request/response shim. Two entrypoints:src/server.tssrc/server-http.tsDockerfilefor Fly/Railway/Render. Authoring (agents.create), destructive ops, and secrets deliberately not exposed; rationale inskill.md.Tested
create_session → send_message → wait_for_idleloop proven end-to-end against a live agent.401unauth'd,tools/listreturns 9 with bearer token.