Claude: Zero to Hero
Agents · module 5 of 5

Managed Agents

What you’ll learn: running agents on Anthropic’s infrastructure instead of your own.


What it is

You define the agent. Anthropic runs it — in a managed cloud sandbox, with session management, memory, webhooks, scheduling and multi-agent orchestration handled for you.

The trade: less control over the runtime, dramatically less operational work.


Managed Agents vs. the Agent SDK

  Agent SDK Managed Agents
Runs on Your infrastructure Anthropic’s
You operate Hosting, scaling, session storage, sandboxes Nothing
Control Full Configuration-level
Sandbox You choose (Docker, K8s, dev container…) Managed, or self-hosted
Best when You need custom orchestration or must run in your own VPC You want an agent running without an ops project

Both use the same underlying model and tool concepts. Migrating between them is not a rewrite.


The pieces

Agent setup

Define the agent: instructions, tools, model, permissions. See Define your agent.

Sessions

Start a session, stream events, operate on it mid-run.

Outcomes

Define what “done” means, declaratively. This is the termination-condition problem from Agent design principles, given first-class support.

See Define outcomes.

Environments and sandboxes

Configure the cloud environment the agent runs in — or bring your own sandbox if you need the execution inside your network.

Memory stores

Persistent memory across sessions, as a managed resource. This is the “external state” principle from Context engineering, without you running the storage.

See Memory stores.

Tools, MCP, and Skills

Credentials

Vaults hold credentials the agent needs, so secrets aren’t in prompts or configuration.

See Authenticate with vaults.

Permission policies

Declarative control over what the agent may do. See Permission policies.

Files

Attach files to a session and download what the agent produces. See Attach and download files.

GitHub

First-class GitHub access for agents that work on repositories. See Access GitHub.

Scheduling and webhooks

Multi-agent orchestration

Coordinate multiple managed agents. See Multiagent orchestration.

Dreams

A distinct capability with its own lifecycle (create, cancel, archive). See Dreams.


Prototyping in the Console

You can prototype an agent in the Console before writing any code — define it, run it, iterate on the instructions, then move to the API.

See Prototype in Console.


When to choose Managed Agents

Good fit:

Poor fit:


Migrating

If you have something built on the Agent SDK or an older shape, there’s a migration path.

See Migration.


Try it

Exercise 1 — Console prototype. Define an agent in the Console. Run it. Iterate on the instructions until the output is good. Note how much faster this is than writing code first.

Exercise 2 — Outcomes. Define an explicit outcome. Give the agent a task it can’t complete. Confirm it stops cleanly rather than looping.

Exercise 3 — Memory store. Build an agent that accumulates knowledge across sessions via a memory store. Run it three times on related tasks. Verify the third run benefits from the first two.

Exercise 4 — Scheduled deployment. Schedule a recurring agent. Check the output twice before trusting it.

Exercise 5 — Webhook. Trigger an agent from an event. Subscribe to a webhook for its completion.

Exercise 6 — Compare. Build the same simple agent twice: once on the Agent SDK, once as a Managed Agent. Compare the code volume and the operational surface.


Checkpoint


Going deeper