# What changed in agents

> 55 changes in agents 0.3 to 0.28 from its official release notes, upgrade guides and advisories: 11 breaking, 4 security, 23 new APIs and options. Each one cited. Sources checked 2026-10-18. HTML: https://unstale.sh/npm/agents/

To see which of these apply to a repository, run `npx @unstale/cli init` in it.

## agents 0.28

### Breaking changes

- Rejects a Legacy request when its factory returns an instance still serving another request without closing that instance. (0.28.1) — [release notes](https://github.com/cloudflare/agents/releases/tag/agents%400.28.1)
- Requests for a session ended with DELETE now receive 404 immediately instead of being served until deferred teardown runs. (0.28.1) — [release notes](https://github.com/cloudflare/agents/releases/tag/agents%400.28.1)
- MCP client transports now follow redirects only within the same origin. (0.28.1) — [release notes](https://github.com/cloudflare/agents/releases/tag/agents%400.28.1)
- OpenCodeHarness session.events() now streams a session snapshot followed by events translated into the kinds PiHarness reports; raw OpenCode events remain available and resumable from session.log(). (0.28.1) — [release notes](https://github.com/cloudflare/agents/releases/tag/agents%400.28.1)

### New APIs and options

- AI Gateway dynamic routes can be selected with ai("dynamic/<route>"). (0.28.1) — [release notes](https://github.com/cloudflare/agents/releases/tag/agents%400.28.1)
- AI SDK models routed with your own vendor key can use vendorKey: "request". (0.28.1) — [release notes](https://github.com/cloudflare/agents/releases/tag/agents%400.28.1)
- Adds the zdr gateway option to createAI for AI SDK and Pi AI models. (0.28.1) — [release notes](https://github.com/cloudflare/agents/releases/tag/agents%400.28.1)
- Adds a tool for creating and manipulating a persistent browser session, available through the pi, ai-sdk, and tanstack-ai integrations. (0.28.0) — [release notes](https://github.com/cloudflare/agents/releases/tag/agents%400.28.0)
- Adds `browserTool()` to the pi browser integration. (0.28.0) — [release notes](https://github.com/cloudflare/agents/releases/tag/agents%400.28.0)
- Adds a tool that reads URLs as Markdown, JSON, or text, including HTML, PDF, and Office documents via Worker AI. (0.28.0) — [release notes](https://github.com/cloudflare/agents/releases/tag/agents%400.28.0)

### Behavior and default changes

- The lifecycle capability is now stable. (0.28.0) — [release notes](https://github.com/cloudflare/agents/releases/tag/agents%400.28.0)
- The MCPClientManager capability is now stable. (0.28.0) — [release notes](https://github.com/cloudflare/agents/releases/tag/agents%400.28.0)
- The Scheduler capability is now stable. (0.28.0) — [release notes](https://github.com/cloudflare/agents/releases/tag/agents%400.28.0)
- The State capability is now stable. (0.28.0) — [release notes](https://github.com/cloudflare/agents/releases/tag/agents%400.28.0)
- ThinkHarness keeps sessions and operations in the shared `agents/harness/store`; migrations run on first run. (0.28.0) — [release notes](https://github.com/cloudflare/agents/releases/tag/agents%400.28.0)
- The WebSockets capability is now stable. (0.28.0) — [release notes](https://github.com/cloudflare/agents/releases/tag/agents%400.28.0)

## agents 0.27

### Breaking changes

- Removes the first-pass Channels entry points and API; Channels moves to agents/experimental/channels, and the old helpers and composites are removed. (0.27.0) — [release notes](https://github.com/cloudflare/agents/releases/tag/agents%400.27.0)
- Moves Email to the experimental Channels entry point while retaining verified ingress and normalization. (0.27.0) — [release notes](https://github.com/cloudflare/agents/releases/tag/agents%400.27.0)
- Moves Slack to the experimental Channels entry point while retaining verified ingress and normalization. (0.27.0) — [release notes](https://github.com/cloudflare/agents/releases/tag/agents%400.27.0)
- Moves Telegram to the experimental Channels entry point while retaining verified ingress and normalization. (0.27.0) — [release notes](https://github.com/cloudflare/agents/releases/tag/agents%400.27.0)
- Ingress Channels require a participant callback so the application identifies the sender; Channels does not choose an identity. (0.27.0) — [release notes](https://github.com/cloudflare/agents/releases/tag/agents%400.27.0)
- Rejects immediately when the supplied signal is already aborted instead of remaining pending until the operation settles. (0.27.0) — [release notes](https://github.com/cloudflare/agents/releases/tag/agents%400.27.0)
- send() and listConversations() reject after the client closes; follow() and close() cancel pending reconnects to avoid unwanted sockets. (0.27.0) — [release notes](https://github.com/cloudflare/agents/releases/tag/agents%400.27.0)

### Security

- Adds a way to provide credentials outside the container, which only sees a placeholder key. (0.27.0) — [release notes](https://github.com/cloudflare/agents/releases/tag/agents%400.27.0)

### New APIs and options

- Adds a draft harness interface for Channels; the interface may change. (0.27.0) — [release notes](https://github.com/cloudflare/agents/releases/tag/agents%400.27.0)
- Adds a terminal client for a conversation's Web Channel with live transcripts, approvals, client tool results, and turn cancellation. (0.27.0) — [release notes](https://github.com/cloudflare/agents/releases/tag/agents%400.27.0)
- Adds an AI SDK harness that runs messages with streamText and keeps sessions and transcripts in the Durable Object, enabling Channels.forHarness to serve an AI SDK model. (0.27.0) — [release notes](https://github.com/cloudflare/agents/releases/tag/agents%400.27.0)
- Adds a Worker entry point for verifying channel webhooks, routing Web Channel upgrades to conversation-owning agent objects, and delivering outbound messages. (0.27.0) — [release notes](https://github.com/cloudflare/agents/releases/tag/agents%400.27.0)
- Adds an experimental Lifecycle capability that serves harness sessions as conversations to joined surfaces, with durable, resumable responses on Streams. (0.27.0) — [release notes](https://github.com/cloudflare/agents/releases/tag/agents%400.27.0)
- Connects a harness to Channels using a channels configuration. (0.27.0) — [release notes](https://github.com/cloudflare/agents/releases/tag/agents%400.27.0)
- Adds an experimental harness that runs agent CLIs such as Claude Code or Codex in a Cloudflare Container and drives them from a Durable Object. (0.27.0) — [release notes](https://github.com/cloudflare/agents/releases/tag/agents%400.27.0)
- Adds an OpenCode plugin factory that serves Workers AI models through the AI binding. (0.27.0) — [release notes](https://github.com/cloudflare/agents/releases/tag/agents%400.27.0)
- Adds an AI SDK tool for sending a message to a surface through the gateway. (0.27.0) — [release notes](https://github.com/cloudflare/agents/releases/tag/agents%400.27.0)
- Adds headers to the WebSocket upgrade made by the terminal client. (0.27.0) — [release notes](https://github.com/cloudflare/agents/releases/tag/agents%400.27.0)
- Adds an experimental OpenCode v2 harness hosted in a Durable Object, with session recovery after eviction and hibernation when idle. (0.27.0) — [release notes](https://github.com/cloudflare/agents/releases/tag/agents%400.27.0)
- Adds a callback for sharing an agent object between participants or refusing them. (0.27.0) — [release notes](https://github.com/cloudflare/agents/releases/tag/agents%400.27.0)
- Adds a Think agent-loop harness with durable sessions, resumable turns, and the shared harness interface served by Channels. (0.27.0) — [release notes](https://github.com/cloudflare/agents/releases/tag/agents%400.27.0)
- Adds a Web Channel and client for browser and terminal access to conversations over agent WebSockets, including transcript, turns, approvals, client tool results, and conversation operations. (0.27.0) — [release notes](https://github.com/cloudflare/agents/releases/tag/agents%400.27.0)
- Adds a tool over Cloudflare's Web Search API for the pi harness, the AI SDK, and TanStack AI. (0.27.0) — [release notes](https://github.com/cloudflare/agents/releases/tag/agents%400.27.0)
- Adds an AI SDK ChatTransport over the Web Channel so AI SDK UIs can join a Channels conversation. (0.27.0) — [release notes](https://github.com/cloudflare/agents/releases/tag/agents%400.27.0)
- Adds use for protocol handlers that run before the configured WebSocket handlers. (0.27.0) — [release notes](https://github.com/cloudflare/agents/releases/tag/agents%400.27.0)

### Behavior and default changes

- Gets a tool-specific description covering the cdp API, common mistakes, runtime limit, and screenshot result limit, so the model no longer runs codemode.search first. (0.27.0) — [release notes](https://github.com/cloudflare/agents/releases/tag/agents%400.27.0)
- AiSdkHarness passes tools to convertToModelMessages so each tool's toModelOutput shapes results on later turns instead of exposing raw JSON output. (0.27.0) — [release notes](https://github.com/cloudflare/agents/releases/tag/agents%400.27.0)
- Clears the removed server's saved OAuth state from Durable Object storage, including tokens and pending or discovery state, without affecting other servers or revoking provider tokens. (0.27.0) — [release notes](https://github.com/cloudflare/agents/releases/tag/agents%400.27.0)
- Handles Cloudflare Access by obtaining a token from cloudflared and sending it on the WebSocket upgrade; explicit credentials take precedence. (0.27.0) — [release notes](https://github.com/cloudflare/agents/releases/tag/agents%400.27.0)

### Fixes and other changes

- Fixes startup with stored sessions so a restarted agent continues acknowledging messages. (0.27.0) — [release notes](https://github.com/cloudflare/agents/releases/tag/agents%400.27.0)
- Drops a URL fragment before connecting because WebSocket URLs cannot carry one. (0.27.0) — [release notes](https://github.com/cloudflare/agents/releases/tag/agents%400.27.0)
- Live read and readBatches re-poll before waiting for the next append, preventing readers from stalling when chunks arrive while a batch is being handled. (0.27.0) — [release notes](https://github.com/cloudflare/agents/releases/tag/agents%400.27.0)
- Rechecks that the v1 chunk table exists before using it, preventing append failures when another Streams instance folds rows and drops the table. (0.27.0) — [release notes](https://github.com/cloudflare/agents/releases/tag/agents%400.27.0)
- A routed wake whose owner facet is no longer registered ends quietly instead of throwing Invalid job outcome on the alarm. (0.27.0) — [release notes](https://github.com/cloudflare/agents/releases/tag/agents%400.27.0)
- Replaces a cut-off assistant reply with the server's copy after a mid-stream WebSocket disconnect when the server sends that copy on reconnect. (0.27.0) — [release notes](https://github.com/cloudflare/agents/releases/tag/agents%400.27.0)
- Reads payments from MCP SDK v2 servers and matches payment headers case-insensitively. (0.27.0) — [release notes](https://github.com/cloudflare/agents/releases/tag/agents%400.27.0)

## agents 0.3

### Security

- Cloudflare Agents has a Reflected Cross-Site Scripting (XSS) vulnerability in AI Playground site (0.3.10) — [security advisory](https://github.com/advisories/GHSA-W5CR-2QHR-JQC5)
- Cloudflare Agents is Vulnerable to Reflected Cross-Site Scripting in the AI Playground's OAuth callback handler (0.3.10) — [security advisory](https://github.com/advisories/GHSA-CVHV-6XM6-C3V4)
- Cloudflare Agents SDK has Insecure Direct Object Reference (IDOR) via Header-Based Email Routing (0.3.7) — [security advisory](https://github.com/advisories/GHSA-R7X9-8PH7-W8CG)
