Original: Anthropic Engineering · 29/01/2026
Summary
The key design principle behind Claude Code is that Claude needs the same tools that programmers use every day. Building agents with the Claude Agent SDK The Claude Agent SDK is a collection of tools that helps developers build powerful agents on top of Claude Code. In this article, we walk through how to get started and share our best practices. Category Claude Code Agents Product Claude Code Claude DeveloKey Insights
“The key design principle behind Claude Code is that Claude needs the same tools that programmers use every day.” — Highlighting the importance of providing Claude with tools for programming tasks.
“By giving Claude access to the user\u2019s computer (via the terminal), it\ \ had what it needed to write code like programmers do.” — Emphasizing the flexibility and foundational role of the Claude Agent SDK in creating various types of agents.
“At its core, the SDK gives you the primitives to build agents for whatever workflow you’re trying to automate.” —
Topics
Full Article
Published: 2026-01-29
Source: https://www.anthropic.com/engineering/building-agents-with-the-claude-agent-sdk
Building agents with the Claude Agent SDK The Claude Agent SDK is a collection of tools that helps developers build powerful agents on top of Claude Code. In this article, we walk through how to get started and share our best practices. Category Claude Code Agents Product Claude Code Claude Developer Platform Date September 29, 2025 Reading time 5 min Share Copy link
- Are elements positioned correctly? Is spacing appropriate? Styling
- Do colors, fonts, and formatting appear as intended? Content hierarchy
- Is information presented in the right order with proper emphasis? Responsiveness
- Does it look broken or cramped? (though a single screenshot has limited viewport info) Using an MCP server like Playwright, you can automate this visual feedback loop—taking screenshots of rendered HTML, capturing different viewport sizes, and even testing interactive elements—all within your agent’s workflow. Visual feedback from a large-language model (LLM) can provide helpful guidance to your agent. LLM as a judge You can also have another language model “judge” the output of your agent based on fuzzy rules. This is generally not a very robust method, and can have heavy latency tradeoffs, but for applications where any boost in performance is worth the cost, it can be helpful. Our email agent might have a separate subagent judge the tone of its drafts, to see if they fit well with the user’s previous messages. Testing and improving your agent After you’ve gone through the agent loop a few times, we recommend testing your agent, and ensuring that it’s well-equipped for its tasks. The best way to improve an agent is to look carefully at its output, especially the cases where it fails, and to put yourself in its shoes: does it have the right tools for the job? Here are some other questions to ask as you’re evaluating whether or not your agent is well-equipped to do its job: If your agent misunderstands the task, it might be missing key information. Can you alter the structure of your search APIs to make it easier to find what it needs to know? If your agent fails at a task repeatedly, can you add a formal rule in your tool calls to identify and fix the failure? If your agent can’t fix its errors, can you give it more useful or creative tools to approach the problem differently? If your agent’s performance varies as you add features, build a representative test set for programmatic evaluations (or evals) based on customer usage. Getting started The Claude Agent SDK makes it easier to build autonomous agents by giving Claude access to a computer where it can write files, run commands, and iterate on its work. With the agent loop in mind (gathering context, taking action, and your verifying work), you can build reliable agents that are easy to deploy and iterate on. You can get started with the Claude Agent SDK today. For developers who are already building on the SDK, we recommend migrating to the latest version by following this guide . Acknowledgements Written by Thariq Shihipar with notes and editing from Molly Vorwerck, Suzanne Wang, Alex Isken, Cat Wu, Keir Bradwell, Alexander Bricken & Ashwin Bhat. No items found. Prev Prev 0 / 5 Next Next eBook FAQ No items found. Get Claude Code On the web VS Code JetBrains Slack curl -fsSL
Key Takeaways
Notable Quotes
The key design principle behind Claude Code is that Claude needs the same tools that programmers use every day.Context: Explaining the foundational design principle of Claude Code for building agents.
By giving Claude access to the user’s computer (via the terminal), it had what it needed to write code like programmers do.Context: Highlighting the importance of providing Claude with tools for programming tasks.
At its core, the SDK gives you the primitives to build agents for whatever workflow you’re trying to automate.Context: Emphasizing the flexibility and foundational role of the Claude Agent SDK in creating various types of agents.
Related Topics
- [[topics/agent-native-architecture]]
- [[topics/claude-code]]
- [[topics/ai-agents]]
Related Articles
Equipping agents for the real world with Agent Skills
Anthropic Engineering · explanation · 91% similar
Effective harnesses for long-running agents
Anthropic Engineering · how-to · 85% similar
Claude Code overview
Anthropic Engineering · reference · 83% similar
Originally published at https://www.anthropic.com/engineering/building-agents-with-the-claude-agent-sdk.