[BUG] MCP tool calls in CCR Routines fail with "requires approval" — no approval UI shown, reconnect does not resolve
Preflight Checklist
- [x] I have searched existing issues and this hasn't been reported yet
- [x] This is a single bug report (please file separate reports for different bugs)
- [x] I am using the latest version of Claude Code
What's Wrong?
MCP tool calls made inside a Claude Code Routine (automated, non-interactive CCR session) consistently fail with:
Streamable HTTP error: Error POSTing to endpoint: MCP tool call requires approval
The Anthropic CCR proxy (api.anthropic.com/v2/ccr-sessions/{id}/mcp) returns this error on every call.
Since Routines have no interactive user present, no approval UI can appear — and indeed none appears. Disconnecting and reconnecting the MCP connectors (Heptabase) does not resolve the issue. The MCP config file (/tmp/mcp-config-{session_id}.json) is correctly generated with valid server IDs and proxy URLs.
What Should Happen?
MCP connectors that have been authorized in claude.ai settings should work in Routines without requiring per-call interactive approval. This was the behavior until recently.
Error Messages/Logs
Steps to Reproduce
- In claude.ai/code, configure a Routine that calls MCP tools (e.g. Heptabase get_journal_range, Notion notion-create-pages)
- Ensure the MCP connectors are connected (OAuth authorized) in claude.ai settings
- Trigger the Routine
- Observe that every MCP tool call fails with MCP tool call requires approval
- No approval UI appears anywhere in the browser
- Disconnecting and reconnecting the MCP connector does not fix the issue
- The same MCP tools work correctly in local Claude Code CLI with the same OAuth-authorized connections
Claude Model
Sonnet (default)
Is this a regression?
Yes, this worked in a previous version
Last Working Version
_No response_
Claude Code Version
2.1.146
Platform
Anthropic API
Operating System
macOS
Terminal/Shell
Other
Additional Information
_No response_
Showing cached comments. Read the full discussion on GitHub ↗
12 Comments
Found 2 possible duplicate issues:
This issue will be automatically closed as a duplicate in 3 days.
🤖 Generated with Claude Code
Hitting this same regression — adding context in case it helps triage.
Setup:
Claude Code on the web, scheduled routine triggered daily.
Routine has a Google Drive connector attached with the "Claude can use all tools from these connectors — including writes — without asking for permission during runs" banner showing in the config UI.
Routine was recreated fresh today (after the original failed), so the config is not stale.
Symptom (exact match):
Every MCP Drive tool call returns:
Streamable HTTP error: Error POSTing to endpoint: MCP tool call requires approval
No approval UI surfaces (it can't — it's a headless scheduled run), so the routine deadlocks on the first connector call and never produces output.
Confirmation it's session-type specific, not config:
I ran the identical workflow in an interactive web session today (same account, same connector, same repo), and every Drive call succeeded without an approval prompt. The interactive session sees the Drive tools under a UUID-prefixed namespace (mcp__<uuid>__search_files); the routine session appears to be hitting the same backend but gated.
Regression confirmed:
This routine was working previously and started failing around the May 19 build. Symptom and build window match other reports filed the same day.
Business impact:
Production daily routine is broken. No direct-API workaround available in our environment due to deployment constraints. Currently running the routine manually each morning as a holding pattern.
Happy to share routine ID / failed session IDs privately if it helps — let me know where to send them.
Seeing the same thing here. If it helps to narrow it down routines worked fine on may 19th around 5PM. 24 hours later the same routines failed with this exact error message as shared above.
@localden - As I commented in #61200 - I see this still happening in scheduled routines. The Notion MCP continues to fail. This worked briefly Sunday and then regressed every day after that.
Any updates here. The notion connector still isn't working correctly in routines
This looks like a headless-approval state mismatch rather than a connector-auth problem.
For Routines, the runtime probably needs an explicit effective permission mode for each MCP call before execution:
The key invariant is that "connected" and "authorized" are not the same as "this exact routine may execute this write call unattended."
Acceptance tests I would want:
That would preserve unattended routines without turning connector OAuth into ambient execution authority.
does this affect
.mcp.jsonin a repo as well? I have a custom mcp server which runs npx commands, and it's asking for approval everytime in CCR, I cannot get it to do anything without asking meI would treat a repo
.mcp.jsonserver as the same approval-surface class only if it is being invoked from a headless routine or remote run where no interactive prompt can actually resolve.The useful split is:
A custom server that runs through
npxshould not inherit authority from "connector is configured" or "repo file exists." The routine needs either a pre-run policy record that binds the server command and tool scope, or a fail-closed no-effect result before execution starts.The negative controls I would want are:
So yes, if
.mcp.jsonis involved in CCR, I would test it as a scoped server-definition approval problem, not only as a per-call popup bug.@rpelevin I am running in a remote run. when I wake up the run has been sitting there for 2-3 hours waiting for approval.
I _do_ see the approval prompt though.
do I make a separate issue? this is the only open issue best fits my current problem
I would split this into a separate issue if the prompt is actually visible, because that is a different failure mode from "no approval UI can surface."
The boundary I would describe is:
The bug title I would use is something like:
Remote run waits for visible MCP approval prompt but does not resume after wake
That separates it from this routine issue while preserving the shared invariant: approval_pending is not the same as approval_denied, and a remote/run resume boundary should not strand the tool call without a typed terminal outcome.
In the new issue, I would include whether clicking approve after the wake does anything, whether the prompt was shown in browser or CLI/TUI, the MCP server type, and any run id or timestamp that maintainers can correlate.
@rpelevin mm, well it does resume after I approve. maybe it's a PEBKAC error :/
I'd just like the CCR to run without asking me to run MCP tools in the
.mcp.json- I have approved the tools insettings.json, however, this seems to be ignored in scheduled CCR runsThanks, that clarification helps. If approving does resume the run, I would keep this in the same issue and narrow it to the scheduled-run policy import path rather than wake/resume.
The distinction I would test is:
The regression I would write is:
That would separate user mistake from product behavior: the run log should say whether settings approval was ignored, ineligible for scheduled CCR, invalidated, or applied.