Add MCP server integration for dynamic agent discovery#352
Add MCP server integration for dynamic agent discovery#352mchawda wants to merge 2 commits intomsitarzewski:mainfrom
Conversation
Adds a Model Context Protocol server that exposes all Agency agents as queryable tools and resources. Any MCP client (Cursor, Claude Code, Claude Desktop) can list, search, compose teams, and load full agent prompts without manual file copying. Tools: list_agents, get_agent, search_agents, compose_team, list_divisions Resources: agency://catalog, agency://divisions Made-with: Cursor
Adds concrete tool call examples with sample outputs, Node.js/tsx alternative for users without Bun, and clearer setup instructions. Made-with: Cursor
|
Per CONTRIBUTING.md guidelines for new tooling/integrations, I've opened #353 as a discussion thread for community feedback on this approach. Also just pushed an update with:
Happy to iterate based on feedback. |
Code Review1 issue found. Issue 1 —
|
Agent Information
Agent Name: MCP Server Integration
Category: integrations
Specialty: Dynamic agent discovery and composition via Model Context Protocol
Motivation
The Agency has 160+ agents but no programmatic way to discover, search, or compose them at runtime. Every integration today (Cursor rules, Aider conventions, Windsurf rules) requires running shell scripts and copying static files.
This PR adds an MCP server that turns the agent repo into a live, queryable registry — any MCP-compatible client (Cursor, Claude Code, Claude Desktop) can dynamically list, search, and load agent prompts without manual file management.
What's Included
5 Tools:
list_agentsget_agentsearch_agentscompose_teamlist_divisions2 Resources:
agency://catalogagency://divisionsTechnical Details
@modelcontextprotocol/sdkv1.28.0 + Zod for typed paramsAGENCY_AGENTS_PATHisError: trueTesting
Checklist