Claude Agent SDK Rust — AI skill for Claude Code
Rust SDK for Claude Code CLI - Build production-ready AI agents with type safety.
How to install Claude Agent SDK Rust
This entry records only its repository, not the path inside it, so there is no
exact command to give. Open Wally869/claude_agent_sdk_rust and copy the folder into
~/.claude/skills/, or the file into ~/.claude/agents/.
What Claude Agent SDK Rust does
Rust SDK for Claude Code CLI - Build production-ready AI agents with type safety.
Alternatives in AI
- Welcome — AI Research Skills — You now have access to 86 production-ready skills covering the entire AI research lifecycle: literature survey 5.4k ★
- Contributing To Claude Skills Library — Thank you for your interest in contributing to the Claude Skills Library 5.3k ★
- Anthropic SDK TypeScript — Access to Anthropic's safety-first language model APIs in TypeScript 2.1k ★
README
Claude Agent SDK for Rust
[](https://crates.io/crates/claude-agent-sdk-rust) [](https://docs.rs/claude-agent-sdk-rust)
Rust SDK for building production-ready AI agents with Claude. Replicate the full feature set of the Python Claude Agent SDK with idiomatic Rust patterns.
Overview
The Claude Agent SDK enables you to build powerful AI agents using Claude Code's agent harness. This SDK wraps the Claude Code CLI, providing type-safe access to:
- Automatic context management and compaction
- 20+ built-in tools (file operations, code execution, web search)
- Custom MCP (Model Context Protocol) tools
- Fine-grained permission controls
- Hook system for deterministic behavior
- Interactive bidirectional conversations
- Usage tracking and quota monitoring (Max Plan)
Important Notes
**Structured output requires more than 1 turn.** When using `output_format` with a JSON schema, the CLI may need additional turns internally to produce structured JSON. Set `max_turns` to at least 2-3 (or omit it entirely) — using `max_turns(1)` will likely result in `error_max_turns` with no structured output.
**`max_budget_usd` is a soft cap.** The budget limit is checked between turns, not mid-generation. The current turn will always complete before the budget is evaluated, so actual spend may slightly exceed the configured limit.
**No nested Claude Code instances.** As of [CLI v2.1.41](https://code.claude.com/docs/en/changelog#2141), Claude Code prevents spawning nested instances of itself. The CLI sets `CLAUDECODE=1` in the environment; any child process that tries to start another Claude Code instance will detect this and refuse to launch. This means you cannot test SDK examples from within a Claude Code session (e.g. from Claude Code's Bash tool). Run them from a regular terminal instead. If you need to bypass this, unset the `CLAUDECODE`
Related Skills
Claude Code Global Config
Production-ready global CLAUDE.md template for Claude Code CLI - Anthropic's AI coding assistant. Clean Archit
Ataru
High-performance AI memory retrieval for local agent history — a Rust search core (SDK / API / JSON CLI) plus
Jev Stars
Local-first GitHub stars memory for AI coding agents: Rust CLI turning 1243 starred repos into agent-ready con
Codex Agentic Patterns
Learn to build production-ready AI agents through real-world patterns extracted from OpenAI's Codex CLI
Gemini Prompt Optimizer
Prompt Master for Gemini: an open-source prompt optimizer & prompt maxxing Agent Skill for Gemini CLI, Antigra
Redfox Agent Plugins
Production-ready Agent Skills for Claude Code, OpenAI Codex, Cursor & Gemini CLI — video downloaders (TikTok,
Related Agents
Interface Verifier
Validates interfaces compile correctly across multiple languages. Checks for type safety, circular dependencie
Rust Project
You are a Rust project architecture expert specializing in scaffolding production-ready Rust applica... - wsho
2389 Agent Rust
This is the production-ready Rust implementation of the 2389 Agent Protocol, a standard for interoperable AI a