[BUG] Background subagents missing many tools

Status Fixed / completed
Maintainer reply None cached
Activity 4 comments · opened Mar 31, 2026 · closed Mar 31, 2026

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?

Background subagents spawned via the Agent tool with run_in_background: true receive only 7 tools: Bash, Read, Write, Edit, Glob, Grep, Skill. They are missing TaskCreate, TaskUpdate, TaskList, TaskGet, SendMessage, CronCreate, CronList, CronDelete, ToolSearch, and all deferred tools.

Foreground subagents receive 76+ tools including all of the above.

What Should Happen?

Per the subagent docs: "subagents inherit all tools from the main conversation." The tools: frontmatter field should control which tools are available. Background agents should have the same tools as foreground agents minus MCP tools.

Steps to Reproduce

  1. Create ~/.claude/agents/TaskWorker.md:
---
name: TaskWorker
description: Worker with task tools
tools: Bash, Read, Write, Edit, Glob, Grep, Skill, ToolSearch, TaskCreate, TaskUpdate, TaskList, SendMessage
background: true
---
Worker agent.
  1. Spawn it: Agent(subagent_type: "TaskWorker", mode: "bypassPermissions", prompt: "Call TaskCreate with subject 'test'. List ALL your tools.")
  1. Result: Agent reports only 7 tools. TaskCreate unavailable.
  1. Same agent spawned without run_in_background (foreground): All tools available, TaskCreate works.

Claude Model

Opus

Is this a regression?

I don't know

Last Working Version

_No response_

Claude Code Version

2.1.88

Platform

Anthropic API

Operating System

macOS

Terminal/Shell

Cursor

Additional Information

_No response_

View original on GitHub ↗

4 Comments

github-actions[bot] · 6 months ago

Found 3 possible duplicate issues:

  1. https://github.com/anthropics/claude-code/issues/38920
  2. https://github.com/anthropics/claude-code/issues/39962
  3. https://github.com/anthropics/claude-code/issues/13898

This issue will be automatically closed as a duplicate in 3 days.

  • If your issue is a duplicate, please close it and 👍 the existing issue instead
  • To prevent auto-closure, add a comment or 👎 this comment

🤖 Generated with Claude Code

MahdiNazemi · 6 months ago

Related to #39899 and https://github.com/anthropics/claude-code/issues/38920, but I only experience this issue with subagents run in the background.

MahdiNazemi · 6 months ago

As explained in https://github.com/anthropics/claude-code/issues/25200#issuecomment-4100093676, omitting the tools: section will enable almost all the tools except for the "orchestration" tools, i.e., Task, SendMessage, Cron, Team*, AskUserQuestion, PlanMode.

github-actions[bot] · 6 months ago

This issue has been automatically locked since it was closed and has not had any activity for 7 days. If you're experiencing a similar issue, please file a new issue and reference this one if it's relevant.