Claude Agent Sdk Template banner
DV0x DV0x

Claude Agent Sdk Template

AI community

Description

A starter template for building AI agents with the Anthropic Claude Agent SDK

Installation

This entry records only its repository, not the path inside it, so there is no exact command to give. Open the source below and copy the folder into ~/.claude/skills/, or the file into ~/.claude/agents/.

README

Claude Agent SDK Template

A starter template for building AI agents with the [Anthropic Claude Agent SDK](https://docs.anthropic.com/en/docs/claude-code/sdk).

Features

  • Express REST API server with TypeScript
  • Session management with persistence
  • Cost tracking and instrumentation
  • Ready for MCP (Model Context Protocol) integration
  • Hot reload development mode
  • Comprehensive SDK documentation included

Project Structure

├── server/
│   ├── sdk-server.ts           # Express REST API (main entry point)
│   └── lib/
│       ├── ai-client.ts        # Claude SDK wrapper
│       ├── session-manager.ts  # Session lifecycle & persistence
│       ├── instrumentor.ts     # Cost/metrics tracking
│       └── orchestrator-prompt.ts  # System prompt (customize this!)
├── agent/.claude/              # Claude SDK configuration
├── claude_sdk/                 # SDK documentation & guides
│   ├── overview.md             # SDK overview
│   ├── typescript_sdk.md       # TypeScript SDK reference
│   ├── session_management.md   # Session handling guide
│   ├── custom_tools.md         # Creating custom tools
│   ├── mcp.md                  # MCP integration guide
│   ├── subagents.md            # Working with subagents
│   ├── system_prompts.md       # System prompt best practices
│   └── ...                     # More guides
├── .env.example                # Environment variables template
├── package.json
└── tsconfig.json

Quick Start

1. Clone or Fork

git clone https://github.com/anthropics/claude-agent-sdk-template.git
cd claude-agent-sdk-template

2. Install Dependencies

npm install

3. Configure Environment

cp .env.example .env

Edit `.env` and add your API keys:

4. Run the Server

**Development mode** (with hot reload): ```bas