
A warm welcome to the course. Discover what the Claude Agent SDK is, preview the three complete agents you will build, and understand why autonomous AI agents are a skill worth learning right now.
Learn what the SDK is, what makes it different from the raw Anthropic API, and how it compares to Claude.ai, the Client SDK, and Managed Agents.
Meet the four components — your Python code, the SDK relay, Claude the reasoner, and Claude Code the executor — and understand the THINKING vs DOING distinction.
A detailed walkthrough of the 10-step agent loop, the five message types you will see in your code, and why understanding this loop makes you a better agent developer.
A quick orientation to the course resources. Learn how to find Colab notebook links in the Resources, understand the difference between Starter and Solution notebooks, and see how each notebook is structured — self-contained setup cells, inline comments, and markdown cells that guide you through the code
Get your coding environment ready in minutes. Set up Google Colab, add your Anthropic API key to Colab Secrets, install the SDK, and verify everything is working.
Write your first autonomous agent. Learn async/await in Python and run your first query() call in Google Colab.
Learn the four message types in the agent stream — SystemMessage, AssistantMessage, UserMessage, and ResultMessage — and extract the final result cleanly.
Build your first complete agent from scratch. The File Explorer Agent explores a directory, reads every file, and produces a clean summary report.
A calm walkthrough of every common error beginners hit — API key issues, SDK not installed, runtime restarts, asyncio errors, and invalid model names.
A focused deep dive into the three core file tools. Learn what each one does, when to use it, and the critical difference between Write and Edit.
Give your agent terminal superpowers. Learn how Bash runs any shell command and how Monitor watches a live process and reacts to output line by line in real time.
Teach your agent to find things. Glob finds files by pattern, Grep searches inside files with regex. Includes a beginner-friendly regex introduction and a combined demo.
Your agent goes live on the internet for the first time. WebSearch finds current information, WebFetch retrieves full page content. Includes a combined research workflow demo.
Build human-in-the-loop agents that pause mid-task and ask clarifying questions. Includes the complete HTTP connection, streaming input, and keep-alive mechanism explained clearly.
The Section 3 payoff. A multi-tool agent that searches a codebase for TODOs, asks the user how they want the report, and produces a clean prioritised summary.
Learn the complete 6-gate permission evaluation flowchart, the difference between allowed_tools and disallowed_tools, the five permission modes, and the bypassPermissions gotcha.
Build a read-only agent and two auto-edit configurations running the same task. See why multiple permission combinations can produce identical results through different gate paths.
Learn how PreToolUse hooks work and build automated blocking rules for dangerous Bash commands, sensitive path writes, and out-of-bounds file access — with live trigger demos.
The course capstone. A production-safe agent that reviews code for quality and security issues with three stacked layers of protection and human-in-the-loop interaction.
AI agents are how software gets built next. This course teaches you to build them — from scratch, in Python, using the Claude Agent SDK.
The Claude Agent SDK is the same technology that powers Claude Code — Anthropic's AI coding assistant used by hundreds of thousands of developers worldwide. This course gives you programmatic access to that same engine, so you can build autonomous agents that read files, run commands, search the web, ask users questions, and complete complex multi-step tasks — without writing a single line of tool execution logic yourself.
What You Will Build
By the end of this course you will have built three complete agents from scratch:
File Explorer Agent — autonomously explores a directory, reads every file, and produces a clean summary report. Your first complete autonomous agent.
Codebase TODO Summarizer Agent — searches an entire codebase for TODO comments, filters results by priority based on your preferences, and produces a structured report. Uses Glob, Grep, Read, and AskUserQuestion working together.
Safe Code Review Agent — the course capstone. Reviews code for quality issues and security vulnerabilities — hardcoded credentials, SQL injection, poor error handling — without being able to modify a single file. Three layers of production safety built in.
What You Will Learn
Section 1 — The Big Picture Understand exactly how the Claude Agent SDK works under the hood before writing a single line of code. The four components, the agent loop, pipe communication between the SDK and Claude Code, and session management. This mental model makes everything else in the course click.
Section 2 — Your First Agent Everything runs in Google Colab — no local setup required. Write your first query() call, master async/await in Python, read and filter the agent message stream, and build your first complete agent. A dedicated troubleshooting lecture covers every common error you might hit.
Section 3 — Built-In Tools Deep Dive A systematic tour of every built-in tool the SDK provides:
File tools — Read, Write, Edit — including the critical Write vs Edit distinction
Shell tools — Bash for terminal commands, Monitor for live process output
Search tools — Glob and Grep with a beginner-friendly regex introduction
Web tools — WebSearch and WebFetch for live internet access
User interaction — AskUserQuestion with the complete human-in-the-loop flow explained clearly — including how the HTTP connection, streaming input, and keep-alive mechanism work together
Section 4 — Permissions & Safety Control exactly what your agent is allowed to do. The complete 6-gate permission evaluation flowchart. The difference between allowed_tools, disallowed_tools, and the five permission modes. How to use PreToolUse hooks to automatically block dangerous operations. By the end of this section you will know how to build agents that are safe enough for production.
How This Course Is Delivered
Every coding lecture runs in Google Colab — click the link in the course resources and you are coding immediately. No local Python setup, no virtual environments, no dependency headaches. Each lecture comes with a solution notebook hosted on GitHub.
The course uses claude-haiku-4-5 by default — the fastest and most cost-effective Claude model — keeping your API costs low while you learn. You can switch to any Claude model with a single variable change.
Requirements
Basic Python — functions, loops, variables
A Google account — for Colab
An Anthropic API key — free tier is sufficient
Why Learn This Now
AI agents are moving from demos to production. Developers who can build, control, and constrain autonomous agents have a genuine skill advantage. The Claude Agent SDK is production-grade, actively maintained by Anthropic, and powers one of the most widely used AI coding tools in the world. This course gives you a solid foundation — built on real code, real agents, and real production-safety patterns.