{"id":45339956,"url":"https://github.com/dokkabei97/all-agents-mcp","last_synced_at":"2026-02-24T13:00:40.452Z","repository":{"id":339559036,"uuid":"1160411393","full_name":"Dokkabei97/all-agents-mcp","owner":"Dokkabei97","description":"MCP server that orchestrates Claude Code, Codex, Gemini CLI, and Copilot CLI through a unified stdio interface — ask, compare,   verify, and collaborate across multiple AI agents.","archived":false,"fork":false,"pushed_at":"2026-02-21T10:06:26.000Z","size":1625,"stargazers_count":8,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"master","last_synced_at":"2026-02-23T18:52:25.632Z","etag":null,"topics":["claude-code","codex-cli","copilot-cli","gemini-cli","mcp","orchestration"],"latest_commit_sha":null,"homepage":"","language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/Dokkabei97.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":"CONTRIBUTING.md","funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":"AGENTS.md","dco":null,"cla":null}},"created_at":"2026-02-17T22:52:08.000Z","updated_at":"2026-02-22T22:24:08.000Z","dependencies_parsed_at":"2026-02-22T11:03:30.070Z","dependency_job_id":null,"html_url":"https://github.com/Dokkabei97/all-agents-mcp","commit_stats":null,"previous_names":["dokkabei97/all-agents-mcp"],"tags_count":4,"template":false,"template_full_name":null,"purl":"pkg:github/Dokkabei97/all-agents-mcp","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Dokkabei97%2Fall-agents-mcp","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Dokkabei97%2Fall-agents-mcp/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Dokkabei97%2Fall-agents-mcp/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Dokkabei97%2Fall-agents-mcp/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Dokkabei97","download_url":"https://codeload.github.com/Dokkabei97/all-agents-mcp/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Dokkabei97%2Fall-agents-mcp/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":29783615,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-02-24T10:45:18.109Z","status":"ssl_error","status_checked_at":"2026-02-24T10:45:09.911Z","response_time":75,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.5:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["claude-code","codex-cli","copilot-cli","gemini-cli","mcp","orchestration"],"created_at":"2026-02-21T10:06:11.969Z","updated_at":"2026-02-24T13:00:40.413Z","avatar_url":"https://github.com/Dokkabei97.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"\u003cp align=\"center\"\u003e\n  \u003cimg src=\"etc/all-agents-mcp.png\" alt=\"All Agents MCP\" width=\"600\" /\u003e\n\u003c/p\u003e\n\n# All-Agents-MCP\n\nAn MCP server that orchestrates multiple AI CLI agents — Claude Code, Codex, Gemini CLI, and Copilot CLI — through a unified interface. Delegate tasks, run cross-agent comparisons, and leverage each agent's strengths from any MCP-compatible host.\n\n## Why MCP?\n\nMulti-agent orchestration can also be achieved by configuring CLI integrations directly in `~/.claude/CLAUDE.md`. For example, you can add Codex integration like this:\n\n```markdown\n## Codex CLI Integration\nWhen the user asks to \"consult with Codex\" or similar:\n1. Store the requirement in the $PROMPT environment variable\n2. Run `codex --model gpt-5.3-codex-spark xhigh exec \"$PROMPT\"`\n3. Show the Codex response and add your own commentary\n4. Compare results and select the optimal solution\n```\n\nSimilar patterns can be applied for Gemini CLI, Copilot CLI, and others. This works well for individual use.\n\nHowever, this project was intentionally built as a standalone **MCP server** for the following reason:\n\nIn **enterprise environments**, teams often share a common `CLAUDE.md` managed at the organization or repository level. Embedding agent orchestration logic into `CLAUDE.md` would conflict with or pollute these shared configurations. By encapsulating the orchestration as an **MCP server**, the multi-agent capability becomes a modular, pluggable extension — completely independent of any existing `CLAUDE.md` setup. This allows teams to adopt cross-agent workflows without modifying their shared development guidelines.\n\n## Safe by Design — No OAuth Token Hijacking\n\nSome multi-agent tools work by extracting OAuth tokens from other AI services and calling their APIs directly. This approach (used by projects like [OpenCode](https://github.com/nicepkg/OpenCode)) violates the terms of service of those platforms and can result in **account suspension or permanent bans**.\n\n**all-agents-mcp takes a fundamentally different approach.** It invokes each agent's **official CLI binary** (`claude`, `codex`, `gemini`, `copilot`) as a child process — exactly the same way a human would use them in a terminal. No tokens are extracted, no APIs are called behind the scenes, and no authentication is bypassed.\n\n| | all-agents-mcp | OAuth token hijacking |\n|---|---|---|\n| **How it works** | Calls official CLI commands directly | Extracts tokens from browser/config and calls APIs |\n| **Authentication** | Uses each CLI's own auth flow | Steals OAuth tokens from other services |\n| **ToS compliance** | Fully compliant | Violates platform terms of service |\n| **Account risk** | None | Suspension or permanent ban |\n| **Billing** | Normal CLI usage billing | Unpredictable — may trigger abuse detection |\n\n\u003e Each CLI agent manages its own authentication, billing, and rate limits. all-agents-mcp is simply a process orchestrator — it doesn't touch your credentials.\n\n## Features\n\n- **Single-agent queries** — Ask a specific agent with `ask_agent`\n- **Multi-agent comparison** — Run the same prompt across all agents in parallel with `ask_all`\n- **Task delegation** — Auto-analyze complexity and route to one or multiple agents\n- **Cross-model verification** — Verify answers by running one agent with different models\n- **Specialized tools** — Code review, debugging, explanation, test generation, refactoring\n- **Recursive call prevention** — Automatically excludes the calling agent to avoid infinite loops\n- **Session history** — All interactions are recorded and queryable via MCP resources\n- **Environment-based model config** — Override models at runtime via `AA_MCP_*` environment variables\n\n## Prerequisites\n\n- **Node.js 22+**\n- At least one of the following CLI agents installed and authenticated:\n\n| Agent | Install | Auth |\n|-------|---------|------|\n| [Claude Code](https://docs.anthropic.com/en/docs/claude-code) | `npm i -g @anthropic-ai/claude-code` | `claude` (follow prompts) |\n| [Codex](https://github.com/openai/codex) | `npm i -g @openai/codex` | `codex login` |\n| [Gemini CLI](https://github.com/google-gemini/gemini-cli) | `npm i -g @anthropic-ai/gemini-cli` | `gemini` (follow prompts) |\n| [Copilot CLI](https://githubnext.com/projects/copilot-cli) | `npm i -g @githubnext/github-copilot-cli` | `copilot` (follow prompts) |\n\n## Installation\n\n### Claude Code\n\n#### As a Plugin (recommended)\n\n```bash\n# 1. Add marketplace (includes all Dokkabei97 plugins)\n/plugin marketplace add Dokkabei97/claude-plugins\n\n# 2. Install plugin\n/plugin install all-agents-mcp\n```\n\n\u003e You can also add the plugin repository directly: `/plugin marketplace add Dokkabei97/all-agents-mcp`\n\nThis installs all-agents-mcp as a Claude Code plugin, giving you:\n- 8 skills (`/all-agents-mcp:ask`, `/all-agents-mcp:ask-all`, `/all-agents-mcp:delegate`, `/all-agents-mcp:review`, `/all-agents-mcp:debug`, `/all-agents-mcp:agents`, `/all-agents-mcp:aa-models`, `/all-agents-mcp:aa-fetch`)\n- Automatic MCP server connection via `npx`\n- Session start health checks\n\n#### As MCP Server\n\n```bash\nclaude mcp add all-agents-mcp -- npx -y all-agents-mcp\n```\n\nOr manually add to `~/.claude.json`:\n\n```json\n{\n  \"mcpServers\": {\n    \"all-agents-mcp\": {\n      \"command\": \"npx\",\n      \"args\": [\"-y\", \"all-agents-mcp\"]\n    }\n  }\n}\n```\n\n### Codex CLI\n\n```bash\ncodex mcp add all-agents-mcp -- npx -y all-agents-mcp\n```\n\nOr manually add to `~/.codex/config.toml`:\n\n```toml\n[mcp_servers.all-agents-mcp]\ncommand = \"npx\"\nargs = [\"-y\", \"all-agents-mcp\"]\n\n[mcp_servers.all-agents-mcp.env]\nAA_MCP_LOG_LEVEL = \"warn\"\n```\n\n### Gemini CLI\n\n```bash\ngemini mcp add all-agents-mcp npx -y all-agents-mcp\n```\n\nOr manually add to `~/.gemini/settings.json`:\n\n```json\n{\n  \"mcpServers\": {\n    \"all-agents-mcp\": {\n      \"command\": \"npx\",\n      \"args\": [\"-y\", \"all-agents-mcp\"]\n    }\n  }\n}\n```\n\n### Copilot CLI\n\nAdd to `~/.copilot/mcp-config.json`:\n\n```json\n{\n  \"servers\": [\n    {\n      \"name\": \"all-agents-mcp\",\n      \"type\": \"stdio\",\n      \"command\": \"npx\",\n      \"args\": [\"-y\", \"all-agents-mcp\"]\n    }\n  ]\n}\n```\n\n### From Source\n\n```bash\ngit clone https://github.com/Dokkabei97/all-agents-mcp.git\ncd all-agents-mcp\nnpm install\nnpm run build\n\n# Claude Code\nclaude mcp add all-agents-mcp -- node /path/to/all-agents-mcp/dist/index.js\n\n# Codex\ncodex mcp add all-agents-mcp -- node /path/to/all-agents-mcp/dist/index.js\n\n# Gemini CLI\ngemini mcp add all-agents-mcp node /path/to/all-agents-mcp/dist/index.js\n```\n\n## Plugin Skills\n\nWhen installed as a Claude Code plugin, the following skills are available:\n\n### Skills\n\n| Skill | Usage | Description |\n|-------|-------|-------------|\n| `ask` | `/all-agents-mcp:ask codex \u003cquestion\u003e` | Ask a specific agent a question |\n| `ask-all` | `/all-agents-mcp:ask-all \u003cquestion\u003e` | Ask all agents in parallel and compare |\n| `delegate` | `/all-agents-mcp:delegate \u003ctask\u003e` | Auto-analyze complexity and route to agent(s) |\n| `review` | `/all-agents-mcp:review codex [focus]` | Code review by an external agent |\n| `debug` | `/all-agents-mcp:debug gemini \u003cerror\u003e` | Debug an error with an external agent |\n| `agents` | `/all-agents-mcp:agents` | Show all agents status and health |\n| `aa-models` | `/all-agents-mcp:aa-models` | List available models for all agents |\n| `aa-fetch` | `/all-agents-mcp:aa-fetch \u003curl\u003e [instruction]` | Fetch web page content via Gemini CLI |\n\n## Tools (14)\n\n### Core Tools\n\n| Tool | Description |\n|------|-------------|\n| `ask_agent` | Ask a specific agent a question. Specify which agent and optionally which model. |\n| `ask_all` | Ask all available agents the same question in parallel. Returns a comparison. |\n| `delegate_task` | Delegate a task with automatic complexity analysis. Simple tasks go to one agent; large tasks are split across multiple agents. |\n| `collaborate` | Collaborate with an agent — get its response alongside guidance for synthesizing both perspectives. |\n\n### Verification\n\n| Tool | Description |\n|------|-------------|\n| `verify` | Cross-verify by running the same prompt across multiple models of one agent (e.g., Copilot with GPT, Claude, and Gemini models). |\n\n### Specialized Tools\n\n| Tool | Description |\n|------|-------------|\n| `review_code` | Code review with focus options: `bugs`, `security`, `performance`, `clarity`. |\n| `debug_with` | Debug an error — provide the error message and optional code context. |\n| `explain_with` | Get code explanation at `brief` or `detailed` level. |\n| `generate_test` | Generate tests with optional framework selection (`jest`, `vitest`, `pytest`, `kotest`). |\n| `refactor_with` | Refactor code with a goal: `performance`, `readability`, or `modularity`. |\n\n### Web Tools\n\n| Tool | Description |\n|------|-------------|\n| `fetch_page` | Fetch web page content via Gemini CLI's native browsing. Retrieve and extract content from any URL. |\n\n### Info Tools\n\n| Tool | Description |\n|------|-------------|\n| `list_agents` | List all detected agents and their availability status. |\n| `list_models` | List available models per agent. |\n| `agent_health` | Health check — availability, authentication status, latency. |\n\n## Resources (3)\n\n| URI | Description |\n|-----|-------------|\n| `aa://sessions` | List of all recorded sessions |\n| `aa://session/{id}/history` | Full interaction history for a session |\n| `aa://agents/status` | Current status of all agents |\n\n## Usage Examples\n\nOnce registered, use natural language in Claude Code:\n\n```\n# Ask a specific agent\n\"Ask Codex to implement a binary search function\"\n\n# Compare across agents\n\"Ask all agents how to optimize this SQL query\"\n\n# Delegate a task\n\"Delegate writing unit tests for src/utils/ to Gemini\"\n\n# Collaborate\n\"Collaborate with Copilot to review this architecture\"\n\n# Cross-model verification\n\"Verify with Copilot using gpt-5.2-codex, claude-sonnet-4.5, and gemini-3-pro-preview\"\n\n# Code review\n\"Ask Codex to review this code for security vulnerabilities\"\n\n# Debug\n\"Debug this TypeError with Gemini\"\n\n# Generate tests\n\"Generate vitest tests for this function using Codex\"\n\n# Check status\n\"Show me all available agents and their health\"\n```\n\n## Model Configuration\n\nModels are configured via environment variables with the `AA_MCP_` prefix. Set them in your MCP client config to override defaults at runtime:\n\n```json\n{\n  \"mcpServers\": {\n    \"all-agents-mcp\": {\n      \"command\": \"npx\",\n      \"args\": [\"-y\", \"all-agents-mcp\"],\n      \"env\": {\n        \"AA_MCP_CLAUDE_DEFAULT\": \"claude-sonnet-4.5\",\n        \"AA_MCP_CODEX_ANALYSIS_LEVEL\": \"medium\",\n        \"AA_MCP_GEMINI_MODELS\": \"gemini-2.5-pro,gemini-2.5-flash\"\n      }\n    }\n  }\n}\n```\n\n### Available Environment Variables\n\n| Variable | Default | Description |\n|----------|---------|-------------|\n| `AA_MCP_CLAUDE_DEFAULT` | `claude-opus-4.6` | Claude default model |\n| `AA_MCP_CLAUDE_MODELS` | `claude-opus-4.6,claude-sonnet-4.5,claude-haiku-4.5` | Available Claude models (comma-separated) |\n| `AA_MCP_CODEX_DEFAULT` | `gpt-5.3-codex-spark` | Codex default model |\n| `AA_MCP_CODEX_MODELS` | `gpt-5.3-codex-spark,gpt-5.3-codex,gpt-5.2-codex-max,gpt-5.2-codex` | Available Codex models |\n| `AA_MCP_CODEX_ANALYSIS_LEVEL` | `xhigh` | Codex reasoning depth (`low`/`medium`/`high`/`xhigh`) |\n| `AA_MCP_GEMINI_DEFAULT` | `gemini-3-pro-preview` | Gemini default model |\n| `AA_MCP_GEMINI_MODELS` | `gemini-3-pro-preview,gemini-3-flash-preview,gemini-2.5-pro,gemini-2.5-flash` | Available Gemini models |\n| `AA_MCP_COPILOT_DEFAULT` | `claude-sonnet-4.5` | Copilot default model |\n| `AA_MCP_COPILOT_MODELS` | `claude-opus-4.5,claude-sonnet-4.5,claude-haiku-4.5,gpt-5.2-codex,gemini-3-pro-preview,gemini-3-flash-preview` | Available Copilot models |\n\n## Recursive Call Prevention\n\nWhen all-agents-mcp runs inside an agent (e.g., Claude Code calls all-agents-mcp), it automatically detects the caller and excludes it from the available agent list. This prevents infinite recursive loops.\n\nDetection methods (in priority order):\n1. CLI argument: `--caller=claude`\n2. Environment variables: `CLAUDECODE`, `CODEX_SANDBOX_TYPE`, `GEMINI_CLI`, `COPILOT_CLI`\n3. `process.env._` fallback\n\n## Development Methodology\n\nThis project is built following [AIDE (Agent-Informed Development Engineering) v1.0](./AIDE-REFERENCE.md) — a software development methodology designed for the agentic era. Key principles applied include context budget constraints, locality of behavior, functional core architecture, test-as-specification, and deterministic guardrails.\n\n## Test Status\n\nAll agents have been tested and verified **except Copilot CLI**, which is pending integration testing.\n\n| Agent | Status |\n|-------|--------|\n| Claude Code | Tested |\n| Codex | Tested |\n| Gemini CLI | Tested |\n| Copilot CLI | Not yet tested |\n\n## Architecture\n\n```\nall-agents-mcp/\n├── src/\n│   ├── agents/          # Agent abstraction layer\n│   │   ├── types.ts     #   IAgent interface, AgentResponse, HealthStatus\n│   │   ├── base-agent.ts#   Abstract base with spawn logic\n│   │   ├── claude-agent.ts\n│   │   ├── codex-agent.ts\n│   │   ├── gemini-agent.ts\n│   │   ├── copilot-agent.ts\n│   │   └── registry.ts  #   Detection, registration, recursion guard\n│   │\n│   ├── tools/           # 14 MCP tool definitions\n│   ├── orchestrator/    # Parallel execution, complexity analysis, verification\n│   ├── session/         # File-based session storage\n│   ├── resources/       # 3 MCP resource definitions\n│   ├── config/          # Env var config loader (AA_MCP_* overrides) + Zod schema\n│   ├── utils/           # Logger (stderr), CLI detection\n│   ├── server.ts        # McpServer factory\n│   └── index.ts         # Entry point (stdio transport)\n```\n\n## Development\n\n```bash\nnpm install          # Install dependencies\nnpm run build        # Compile TypeScript\nnpm run dev          # Watch mode\nnpm run lint         # Biome lint + format\nnpm test             # Run tests\n```\n\n### Debug logging\n\n```bash\nAA_MCP_LOG_LEVEL=debug node dist/index.js\n```\n\nLog levels: `debug`, `info` (default), `warn`, `error`. All logs go to stderr to avoid interfering with MCP stdio transport.\n\n## License\n\nMIT\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdokkabei97%2Fall-agents-mcp","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdokkabei97%2Fall-agents-mcp","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdokkabei97%2Fall-agents-mcp/lists"}