
Building a Custom Agent with the Claude Agent SDK
A practical, code-first walkthrough of the Claude Agent SDK: custom tools, MCP servers, and subagents — the same engine that powers Claude Code, in your own app.

A practical, code-first walkthrough of the Claude Agent SDK: custom tools, MCP servers, and subagents — the same engine that powers Claude Code, in your own app.

Claude Code is the most agentic coding CLI Anthropic ships — but it does not have to talk to Anthropic. Because Claude Code speaks the standard Anthropic Messages API, you can point it at any compatible endpoint with a single environment variable. That means OpenRouter, your local Ollama server, a private LiteLLM proxy, or a self-hosted model behind your own router all work without forking the source. This guide walks through the three setup paths, which models actually deliver usable tool-use at each tier, what breaks, and when you should stop and switch back to the official API. ...
AI coding assistants have moved from novelty to necessity. But the hype cycle has settled, and we now have real data on what works and what doesn’t. The Landscape Tool Best For Limitations GitHub Copilot Autocomplete, boilerplate Struggles with multi-file refactors Cursor Full-featured AI IDE Context window limits on large codebases Claude Code Terminal-native agentic coding Requires explicit instruction OpenCode Interactive CLI with subagents Needs good task decomposition Where AI Excels Test Generation AI-generated tests catch edge cases humans miss. In our codebase, AI-authored tests found 23% more boundary condition bugs than human-written equivalents: ...
When your analytics queries go from “how did we do last week?” to “what’s happening right now?”, your data warehouse needs to evolve. Here’s how we built a real-time pipeline handling 500K events/second with sub-second query latency. Architecture Overview ┌──────────┐ ┌──────────┐ ┌────────────┐ ┌──────────┐ │ Services │────▶│ Kafka │────▶│ ClickHouse │────▶│ Grafana │ │ (protobuf)│ │ (Avro) │ │ (MergeTree)│ │ Dashboards│ └──────────┘ └──────────┘ └────────────┘ └──────────┘ │ ▼ ┌──────────┐ │ Schema │ │ Registry │ └──────────┘ Why ClickHouse Over Traditional OLAP? ClickHouse is a columnar database built for real-time analytics. Unlike Snowflake or BigQuery: ...
Two years ago we rewrote a Go microservice in Rust. Here’s what we learned—the good, the ugly, and the surprising. The Numbers Before we get into opinions, here are the cold hard metrics comparing the Go (1.21) and Rust (1.78) versions processing 10M API requests: Metric Go Rust Delta P99 latency 340ms 28ms -92% Memory (steady state) 2.1 GB 48 MB -98% CPU (avg) 4.2 cores 0.8 cores -81% Binary size 12 MB 4.8 MB -60% Lines of code 4,200 5,800 +38% The latency drop isn’t just about Rust being faster—it’s about tail latency predictability. Go’s GC pauses, while short, created sporadic spikes that triggered downstream timeouts. ...
Edge computing is reshaping how we think about distributed systems. Instead of shipping every byte to a centralized data center, computation happens at the periphery—closer to where data originates. Why Edge Computing Matters Now Three forces are driving this shift: 5G networks provide the bandwidth and low latency edge nodes need IoT device explosion generates terabytes of data that make no sense to transmit raw AI inference at the edge demands real-time responses for autonomous vehicles, factory robotics, and AR applications Architecture Patterns Modern edge architectures typically follow a three-tier model: ...