# Claude Code Subagents and Hooks
Run a Multi-Agent Dev Team, Stop Token Burn, and Ship PRs 2x Faster

- Price: $12.99 (Kindle ebook)
- Level: Advanced
- Pages: 190
- Best for: Running a multi-agent Claude Code dev team
- You finish with: A planner-coder-reviewer stack, five hooks, worktree isolation, and cost routing that cuts the token bill 30%
- Series: Claude Code: Your Multi-Agent Dev Team, book 1 of 3
- Buy on Amazon: https://amzn.to/4uD7Mlt
- Web page: https://youcanbuildthings.com/books/claude-code-subagents-hooks

## What you get

You spawn subagents and they burn 85% of your tokens cold. This ships the working stack: a three-agent dev team, five hooks, worktree isolation, a kill switch, and the settings.json that cuts your token bill 30%.

Turn Claude Code from a smart autocomplete into your own dev team. A small multi-agent stack (planner, coder, reviewer), five hooks that catch silent failures, worktrees that keep parallel workers from clobbering your repo, a kill-switch hook, and the cost routing that drops your token bill 30%. 190 pages of operator discipline, not a 500-page recipe dump.

## Chapters

1. The 90% Layer (Why You're Using Claude Code Wrong): The gap between chat-box autocomplete and a multi-agent dev team.
2. How Claude Code Actually Works (Subagents, Skills, Hooks, MCP): What each of the four primitives is and what context it carries.
3. Tool, Skill, or Subagent? The Decision Framework: The four-axis filter that stops you defaulting to a subagent.
4. Your First Three Subagents (Not Forty-Seven): Install a working planner, coder, reviewer stack on your own repo.
5. Writing Self-Contained Subagent Prompts: The four-field briefing that stops cold subagents from guessing.
6. Hooks: Stop Flying Blind: Wire a SubagentStop hook and watch every subagent in real time.
7. Running Subagents in Parallel (Without Clobbering): Git worktree isolation so workers never overwrite each other.
8. The Stack in Action: Skills + Hooks + Subagents Together: One skill, three subagents, one hook, wired into an issue-to-PR pipeline.
9. Pay Less, Bill More: Token Economics + Operator Control: Route workers to cheap models and cut the subagent line item 30%.
10. Catching Silent Failures in Production: Three gates and a kill-switch hook that catch the runaway before it ships.
11. When NOT to Spawn a Subagent (The 47-Specialist Trap): The Goldilocks Test that retires agents that don't earn their slot.
12. Your Power-User Stack: What to Run This Month: A signed 30-day plan from chat-box habit to multi-agent workflow.

## Free guides from this book

- [Claude Code Hooks: Wire a SubagentStop Hook](https://youcanbuildthings.com/articles/claude-code-hooks-subagentstop.md): Wire a Claude Code SubagentStop hook to a log file and tail it live, so you catch hung, runaway, and suspiciously-fast subagents before they ship bad code.
- [Run Claude Code Subagents in Parallel Without Clobbering](https://youcanbuildthings.com/articles/claude-code-parallel-subagents-worktrees.md): Multi-agent development with Claude Code clobbers files when workers share a checkout. Use git worktree isolation and claude --bg to fan out workers safely.
- [Set Up Claude Code Subagents: Three, Not Forty-Seven](https://youcanbuildthings.com/articles/claude-code-subagents-setup.md): Install Claude Code subagents the right way: three scoped agents (planner, coder, reviewer) wired to a main-thread planner, running end-to-end on your repo.
- [Tool, Skill, or Subagent? The Claude Code Decision](https://youcanbuildthings.com/articles/claude-code-tool-skill-or-subagent.md): Stop defaulting to a subagent. A four-axis Claude Code framework routes logic to an inline prompt, a tool call, a skill, or a subagent by cold-start cost.
- [Why Claude Code Subagents Burn So Many Tokens](https://youcanbuildthings.com/articles/claude-code-subagents-token-usage.md): Claude code subagents cost up to 85% of a heavy session. Route workers to cheaper models, audit the env var that undoes it, and cut the subagent bill 30%.
