GILD verdict
Choose the Claude Agent SDK when your agents run on Claude, need files and a shell with approval steps, and you can host one Claude Code process per session.
- The workflow
- A team building Claude agents into internal tools or per-task containers, where the agent reads and edits files, runs commands, and asks before risky actions.17
- The decisive evidence
- DocumentedThe SDK exposes Claude Code's built-in tools, hooks, subagents, MCP, permission rules, and sessions that resume or fork, so the team writes no tool loop or context compaction of its own.135
- DocumentedEach session is a claude CLI subprocess that owns a shell, a working directory, and transcripts on local disk, sized from 1 GiB RAM and 1 CPU per agent. Transcripts survive a container only through a SessionStore adapter.46
- DocumentedTelemetry comes from the CLI process through OpenTelemetry, with traces in beta, and the SDK's cost fields are estimates that can drift from the bill.910
- ReportedThomson Reuters rebuilt CoCounsel Legal around the SDK in 2026, and Spotify runs its Honk agent on it in Kubernetes pods. Moon Banking rolled back a release whose cost logs tripled, which Anthropic traced to older versions undercounting, and a team measured headless SDK runs using about 1.8 times more of a Max plan's 5-hour window than Claude Code on Sep 25, 2026.19202122
- GILD analysisOf the 98 public accounts on this product's Signals page, all 21 that discuss the harness praise it. The CLI subprocess and Claude Code's defaults each draw concerns in 12, and local sessions in 10. The decision turns on how the team hosts it more than on what the agent can do, and whether Anthropic will meter SDK runs against plan limits like Claude Code is unresolved.
Claude Agent SDK
Agent Framework by Anthropic
+52 Strong positiveFit and limits
Who it fits
- The agent needs Claude Code's file, shell, and web tools, and the team would rather not write a tool loop and context compaction.
- Work runs as internal tools, background jobs, or one container per task, where a process per session is easy to host.
- The team wants hooks and permission rules that decide which tool calls run, with a callback for approvals.
- The organization has settled on Claude and can buy it through the Anthropic API, Amazon Bedrock, Google Cloud, or Microsoft Foundry.
Where it falls short
- Stateless, multi-tenant web backends: each session needs a subprocess, memory, and a session store, which the team builds and operates.
- Teams that need other model providers, or sampling settings such as temperature, which the SDK's option reference does not list.
- Agents that need their own persona: a custom system prompt replaces the claude_code preset, and the team then owns the tool guidance and safety rules it carried.
- Teams that cannot absorb frequent releases: the Python package shipped 139 releases in the year to Oct 28, 2026, and the TypeScript package passed 0.3.300. Moon Banking rolled back from 0.1.60 to 0.1.30 in December 2025 when logged costs tripled, which Anthropic traced to older versions undercounting.
- Teams paying through a Claude plan: builders measured SDK runs using 1.7 to 1.8 times more of the 5-hour window than the same work in Claude Code in September and October 2026, and one found a hit quota returned as a successful result.
Implementation reality
Pick a hosting pattern first
Anthropic documents ephemeral containers per task, long-running containers that hold many sessions, and hybrid containers that hydrate from a SessionStore. Size each host from the documented floor of 1 GiB RAM, 5 GiB disk, and 1 CPU per agent, then measure peak memory on a session of real length.
Move transcripts off the host
Configure a SessionStore so another host can resume a session, and store memory files and working-directory artifacts separately. Capture session IDs from the init message and resume by ID in multi-user apps.
Gate tools before you grant them
Hooks run first, then deny rules, ask rules, the permission mode, and the canUseTool callback. Start with read-only tools, deny shell patterns you never want, and route writes and network calls through the callback or a sandbox.
Cap turns and watch spend
Set a turn limit on every query and a budget per run, export usage through OpenTelemetry, and reconcile against the Usage and Cost API, because the SDK's cost fields are estimates. Pin the SDK version and retest cost after each upgrade.
What to measure in your pilot
- How much memory a long-running SDK session reaches under real tool load, against the documented 1 GiB floor.
- Whether the October 7, 2026 plan credits settle how teams pay for SDK agents, or the terms change again.
- How OpenTelemetry traces, still in beta, compare with third-party instrumentation for debugging subagents.
- Whether Anthropic changes how SDK runs count against a Claude plan's 5-hour window, after builders measured them at 1.7 to 1.8 times Claude Code's rate in September and October 2026.
Sources
- Official documentation
- 18
- Public source
- 4
- Agent SDK docs: Overview (capabilities, login policy, license)
- Agent SDK docs: Quickstart (requirements and model providers)
- Agent SDK docs: How the agent loop works
- Agent SDK docs: Hosting (subprocess model, session patterns, sizing)
- Agent SDK docs: Work with sessions
- Agent SDK docs: Persist sessions to external storage
- Agent SDK docs: Configure permissions
- Agent SDK docs: Modifying system prompts
- Agent SDK docs: Track cost and usage
- Agent SDK docs: Observability with OpenTelemetry
- Agent SDK docs: Migrate to Claude Agent SDK (rename from the Claude Code SDK)
- Claude Help Center: Use the Claude Agent SDK with your Claude plan (updated Oct 7, 2026)
- Claude Help Center: Monthly API credits for Max and Team plans
- Claude API docs: Pricing
- Claude API docs: Claude Managed Agents overview
- Claude Agent SDK for Python on GitHub (MIT license)
- Claude Agent SDK for TypeScript on GitHub (Commercial Terms)
- claude-agent-sdk on PyPI (release history)
- Thomson Reuters Innovation blog: CoCounsel Legal, Reimagined, rebuilt around the Claude Agent SDK (Mar 10, 2026)
- Spotify Engineering: Coding Is No Longer the Constraint, on Honk and the Agent SDK (Jun 3, 2026)
- Claude Agent SDK TypeScript issue #93: cost tripled between 0.1.30 and 0.1.60 (Dec 6, 2025)
- Claude Code issue #97074: headless SDK runs use about 1.8 times more of the 5-hour window (Sep 25, 2026)