Summary
Sub-agents spawned via sessions_spawn see sessions_list, sessions_history, and sessions_send mentioned in their system prompt, but these tools are not actually bound to the Anthropic API call. When the model tries to use them, it outputs text that looks like a tool call instead of triggering a real tool_use block.
Config
"tools": {
"subagents": {
"tools": {
"allow": [
"sessions_spawn",
"sessions_list",
"sessions_history",
"sessions_send"
]
}
}
}
Expected Behavior
Sub-agents should be able to call sessions_list and sessions_history and get actual results, enabling cross-session visibility as documented.
Actual Behavior
- Sub-agent sees tools listed in system prompt
- Sub-agent attempts to call
sessions_list
- Instead of a
tool_use block, the model outputs text like:
{"name": "sessions_list", "parameters": {}}
stopReason is "stop" not "tool_use"
- No actual tool execution occurs
Evidence
From transcript inspection:
- Sub-agent thinking: "From the system prompt, I can see the following tools mentioned..."
- Response contains only
thinking + text blocks, no tool_use blocks
stopReason: "stop" confirms no tools were invoked
Environment
- OpenClaw version: 2026.1.29
- Model: claude-opus-4-5
- OS: macOS (Darwin arm64)
Root Cause Hypothesis
The tools.subagents.tools.allow config injects tool names into the sub-agent's system prompt, but does not add corresponding tool definitions to the Anthropic API tools parameter. The model hallucinates tool calls based on prompt text.
Workaround
None known. Sub-agents cannot currently use session tools despite config allowing them.
Summary
Sub-agents spawned via
sessions_spawnseesessions_list,sessions_history, andsessions_sendmentioned in their system prompt, but these tools are not actually bound to the Anthropic API call. When the model tries to use them, it outputs text that looks like a tool call instead of triggering a realtool_useblock.Config
Expected Behavior
Sub-agents should be able to call
sessions_listandsessions_historyand get actual results, enabling cross-session visibility as documented.Actual Behavior
sessions_listtool_useblock, the model outputs text like:stopReasonis"stop"not"tool_use"Evidence
From transcript inspection:
thinking+textblocks, notool_useblocksstopReason: "stop"confirms no tools were invokedEnvironment
Root Cause Hypothesis
The
tools.subagents.tools.allowconfig injects tool names into the sub-agent's system prompt, but does not add corresponding tool definitions to the Anthropic APItoolsparameter. The model hallucinates tool calls based on prompt text.Workaround
None known. Sub-agents cannot currently use session tools despite config allowing them.