claude-max-mcp
Click on "Install 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., "@claude-max-mcpexplain the concept of recursion in simple terms"
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.
claude-max-mcp
An MCP server that turns your Claude Max / Pro subscription into a backend any AI agent can call.
If you pay for Claude Max or Pro, you have a real allotment of Claude usage already — but most agent tools (Cline, Continue, Cursor, custom MCP setups, even Claude Code nested inside another agent) hit the Anthropic API directly with separate credit-card billing. You end up paying twice.
This is a small stdio MCP server that fixes that. It exposes a single tool — ask_claude — which spawns Claude Code under the hood and uses your existing Claude.ai OAuth session to route the call. Net effect: the call counts against your Max/Pro subscription credits, not against any API key.
Your MCP-compatible agent
(Cline • Continue • Cursor • Claude Code itself •
Hermes Agent • custom agents • etc.)
│
│ ask_claude(prompt)
▼
┌──────────────────┐
│ claude-max-mcp │ ← this repo
│ (stdio server) │
└──────────────────┘
│
│ spawn claude -p --model claude-opus-4-7
▼
┌──────────────────┐
│ Claude Code CLI │
└──────────────────┘
│
│ OAuth via ~/.claude.json
▼
Claude Max / Pro subscription
(your existing monthly allotment)Why this exists
Three real scenarios this solves:
Reduce duplicate billing. Stop paying for Max and API credits when the agent work could just count against Max.
Prompt-enhancement router → Claude delegate. A cheap router model (Gemini, Sonnet, Haiku) does no substantive reasoning — it just adds context (project name, today's date, scope hints) to the user's message and forwards it verbatim to Claude Opus 4.7. Claude does all the actual thinking, billed to your Max subscription. Reference template in
examples/hermes/SOUL-additions.md.Nest agents inside Claude Code. Use this from within a Claude Code session so a sub-agent can make its own scoped Claude call without polluting the parent session's context.
Related MCP server: OpenAI Agents MCP Server
Install
# 1. Install Claude Code CLI if you don't have it
npm install -g @anthropic-ai/claude-code
# 2. Log in once (OAuth — uses your Claude Max / Pro subscription)
claude /login
# 3. Install this MCP server
npm install -g claude-max-mcp
# or run from source:
# git clone https://github.com/Jonahbkerr/claude-max-mcp
# cd claude-max-mcp && npm install
# 4. Smoke test
claude-max-mcp --smoke
# → ✓ claude-max-mcp smoke test passed (model: claude-opus-4-7)Register with your MCP client
The server is stdio. Drop it into your client's MCP config.
Claude Code itself
Add to ~/.claude/settings.json under mcpServers:
{
"mcpServers": {
"claude-max": { "command": "npx", "args": ["-y", "claude-max-mcp"] }
}
}Cline (VS Code)
In Cline's MCP server settings:
{
"mcpServers": {
"claude-max": {
"command": "npx",
"args": ["-y", "claude-max-mcp"]
}
}
}Continue (VS Code / JetBrains)
In ~/.continue/config.yaml:
mcpServers:
- name: claude-max
command: npx
args: [-y, claude-max-mcp]Any other MCP-compatible client
Same pattern — command: npx, args: [-y, claude-max-mcp]. See examples/ for ready-to-paste configs.
Configure
Set on the MCP client side when you register the server:
Env var | Default | What it does |
|
| Model passed to |
|
| Path to the Claude Code CLI. |
|
| How long a single delegated call can run. |
|
| Working dir for the claude subprocess — point at a project root if you want Claude to see CLAUDE.md / files there. |
|
| Override the exposed tool name (useful when running multiple instances). |
| (empty) | Extra space-separated args to pass to |
You can register the same server multiple times under different names with different env to expose multiple tools to the same agent (e.g. one Opus instance scoped to a project, one Haiku for one-liners). See examples/hermes/multi-instance.sh.
How it works
docs/architecture.md — data flow, OAuth discovery, model selection, why subprocess.
docs/faq.md — Max sub credit math, common errors, troubleshooting, what this does and doesn't do.
Honest tradeoffs
Not free. Each call debits your Claude subscription allotment. The savings come from avoiding additional API billing, not from making Claude free.
Opus is ~5× Sonnet in credit terms. Burning thousands of Opus delegations per day will exhaust Max usage caps. Use
CLAUDE_MAX_MCP_MODEL=sonnetor=haikufor routine work.Subprocess overhead ≈ 1–2s per call. Fine for chat / agent latency, not for sub-second tool loops.
Daemon-managed clients (launchd, systemd) often strip PATH — set
PATHorCLAUDE_MAX_MCP_BINexplicitly in env config.
Security
Anthropic credentials never pass through this server. It shells out to
claude, which reads its own OAuth from~/.claude.json.The MCP surface is one tool, one string argument. No file I/O, no shell injection (args go through
spawn, not a shell), no recursive tool-use loops.To restrict what Claude can do during delegated calls, set
CLAUDE_MAX_MCP_CWDto a sandboxed directory and useCLAUDE_MAX_MCP_EXTRA_ARGS="--allowed-tools=Read,Glob,Grep"(or similar) to scope its toolset.
License
MIT — see LICENSE.
Issues, PRs, and "this should also work with X" reports welcome.
Available Tools
1 toolask_claudeA
Delegate a substantive task to Claude Code, billed against the user's Claude Max / Pro subscription (model: claude-opus-4-7). Use this for: code generation, deep reasoning, multi-step engineering, refactoring, or anything that needs more capability than the routing model can reliably deliver. The receiver has NO memory of the calling agent's conversation — include everything Claude needs in the prompt argument: the user's verbatim request, project / file context, relevant prior messages, and what kind of output you want back. Returns Claude's full text response.
| Name | Required | Description | Default |
|---|---|---|---|
| prompt | Yes | The full prompt to send to Claude. Claude has no access to the calling agent's conversation — include all context here. |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
No annotations are provided, so the description must carry the full burden. It discloses key behaviors: no memory of conversation, billing against subscription, and the model used. It lacks details on potential rate limits or response format beyond 'full text response', but overall is transparent.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is extremely concise—two sentences—with no wasted words. It front-loads the core purpose and then provides essential usage guidance. Every sentence earns its place.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Given the tool has only one parameter and no output schema, the description is fully complete. It explains the tool's purpose, when to use it, how to structure the input, and the key behavioral constraint (no memory). No additional information is necessary for correct invocation.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema coverage is 100% for the single parameter. The description adds significant meaning: it explains why the prompt must contain all context (no conversation access) and what elements it should include, going well beyond the schema's basic description.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states the tool's purpose: delegating tasks to Claude Code. It specifies the model (claude-opus-4-7) and the subscription billing context, and contrasts with the routing model, providing strong clarity even without sibling tools.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description explicitly lists when to use the tool (code generation, deep reasoning, multi-step engineering, refactoring) and what to include in the prompt (user request, context, prior messages, desired output). It also warns that Claude has no conversation memory, guiding correct usage.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections. Dates show when Glama detected each change.
1 tool update
v0.1.1- First observed
ask_claude
TDQS
With only one tool, there is no possibility of confusion or overlap. The tool's purpose is distinct and unambiguous.
The single tool name 'ask_claude' follows a clear verb_noun pattern. Consistency is perfect due to the lack of other tools.
The server contains only one tool, which is appropriate for its narrow scope of delegating tasks to Claude Code. While a slightly larger set might be expected for a full SDK, the single tool is well-justified and not trivial.
The tool fully covers the stated domain of delegating substantive tasks to Claude Code. No additional tools are necessary for the server's purpose.
Maintenance
Resources
Unclaimed servers have limited discoverability.
Looking for Admin?
If you are the server author, to access and configure the admin panel.
Related MCP Connectors
Hosted MCP server connecting claude.ai, ChatGPT and other AI apps to your own computer
- QuallaaOAuthcom.quallaa
Talk to your public-facing AI from any MCP client — Claude, ChatGPT, Cursor, Cline, Windsurf.
Hosted Amazon Seller Central and Amazon Ads MCP server for Claude, ChatGPT, Cursor, and agents.
MCP server connecting AI agents to 100+ apps (Gmail, Slack, Notion, GitHub) via one-click OAuth.
Related MCP Servers
- AlicenseBqualityCmaintenanceA Model Context Protocol (MCP) server that lets you seamlessly use OpenAI's models right from Claude.128176MIT
- FlicenseBqualityDmaintenanceA Model Context Protocol server that enables Claude users to access specialized OpenAI agents (web search, file search, computer actions) and a multi-agent orchestrator through the MCP protocol.410-
- AlicenseNot gradedqualityAmaintenanceMCP server that bridges ChatGPT Plus/Pro to Claude Code, enabling chat, deep research, and image generation via your own account.47MIT
- AlicenseNot gradedqualityDmaintenanceAn MCP server that exposes your local Claude Code CLI over HTTP+SSE, enabling any MCP-compatible client to use your Claude Code MAX/PRO subscription remotely.162MIT
Latest Blog Posts
- Who's Calling? MCP Hosts Are an Identity Blind Spot (And the Spec Knows It)By Om-Shree-0709 on .mcpAgent IdentityOAuth 2.1
- Your AI Chatbot Just Exposed Your CEO's Salary to an InternBy Om-Shree-0709 on .Agent IdentityMCP SecurityOAuth Delegation
- Why MCP Servers Need Execution Sandboxing (And Why Your Current Stack Isn't Enough)By Om-Shree-0709 on .Agentic AiPrompt InjectionWebAssembly
MCP directory API
We provide all the information about MCP servers via our MCP API.
curl -X GET 'https://glama.ai/api/mcp/v1/servers/Jonahbkerr/claude-max-mcp'
If you have feedback or need assistance with the MCP directory API, please join our Discord server