RemoteTrigger mcp_connections not passed to agent execution environment
Bug Description
Cloud MCP connectors configured via mcp_connections in the RemoteTrigger API are accepted (HTTP 200) but not injected into the remote agent's session. The agent starts, finds no MCP tools, and reports:
"The required MCP tools are not available in this session."
The agent then suggests configuring local MCP servers via settings.json, which is not applicable to remote triggers.
Steps to Reproduce
- Create a RemoteTrigger with
mcp_connectionspointing to cloud-hosted MCP servers (e.g.,gmail.mcp.claude.com,gcal.mcp.claude.com,mcp.supabase.com) - Include a prompt that instructs the agent to use MCP tools (e.g.,
gcal_list_events,gmail_search_messages,execute_sql) - Run the trigger (scheduled or manual via API)
- The agent fires but cannot see any MCP tools
Expected Behavior
MCP tools from the configured mcp_connections should be available to the remote agent, the same way they are in an interactive Claude Code session.
Actual Behavior
The agent reports MCP tools are missing and suggests local settings.json configuration. No MCP tool calls are possible.
What I Tried (all failed)
- Explicit
permitted_toolson each MCP connection — no effect - Disconnected and reconnected all 3 connectors via the web UI, re-added to the task — no effect
- Removed
allowed_toolswhitelist fromsession_context(platform expanded to full 16-tool default) — no effect - Multiple manual trigger runs via the API after each change — all failed identically
Key Detail
The same MCP tools work perfectly in an interactive Claude Code session (CLI). The issue is specific to the remote trigger execution environment.
Environment
- Platform: macOS (Darwin 25.4.0)
- Claude Code CLI
- 3 MCP connections: Google Calendar, Gmail, Supabase (all cloud-hosted connectors authenticated via claude.ai)
- Trigger cron:
0 11 * * 1-5 - Model:
claude-sonnet-4-6
This issue has 2 comments on GitHub. Read the full discussion on GitHub ↗