In short.
Cloudflare’s agents-sdk skill is an instruction pack for coding assistants helping developers build Cloudflare agent applications, but its examples need version checks and are not ready-to-deploy projects. Its main value is specific guidance on configuration, state, chat, recovery and integration choices. The files also contain example inconsistencies and an explicit warning that experimental Code Mode does not pause tools for human approval. No code was executed, and runtime correctness, performance and deployment costs are not established.
Researched and written by an AI model and checked by a second AI model. How it works
The report covers the complete agents-sdk instruction folder at revision 5108325ecceabc899c761e07aa617b09c02445ee: SKILL.md and all 20 reference files, together with the repository-level Apache 2.0 LICENSE as the related licensing notice. Original-source access is preserved through the repository and revision-specific links. Linked pages, SDK implementations, dependency packages and other folders are excluded. Examples were inspected as text only; no installation, build, deployment, model call, browser session or other code execution occurred.
The overview
Identity
The resource is the agents-sdk instruction skill in Cloudflare’s cloudflare/skills repository. Its stated purpose is to help an assistant build, debug or review applications using the agents package. It is not the Agents SDK implementation, an AI model or a hosted agent service.
The original source is [https://github.com/cloudflare/skills/tree/main/skills/agents-sdk]. The version described here is [https://github.com/cloudflare/skills/tree/5108325ecceabc899c761e07aa617b09c02445ee/skills/agents-sdk]. The instruction pack consists of SKILL.md and 20 reference files; the repository-level LICENSE supplies the associated licensing terms.
Assessment
This is a useful companion for Cloudflare-specific coding assistance, particularly when an assistant might otherwise rely on outdated API knowledge. Its concrete guardrails include matching agent classes to Durable Object bindings, adding rather than rewriting migrations, avoiding experimentalDecorators with callable methods, and checking package versions before adapting chat examples.
Treat it as implementation guidance, not production-ready code. Several references primarily direct the reader to external documentation, and some included snippets need clarification or correction. The files support an assessment of the guidance’s substance, but not a claim that using it improves coding accuracy or produces working deployments.
Users
The closest fit is a JavaScript or TypeScript developer using an AI coding assistant on a Cloudflare Workers project. It is relevant to new agent implementations, reviews of existing applications, and changes involving state, routing, chat clients, background work or MCP integrations.
Beginners get a small counter example and a map of relevant documentation, but the skill assumes familiarity with packages, configuration files and application code. It is not a no-code builder or a complete introductory course. Experienced developers are more likely to benefit from its distinctions between recovery mechanisms, client connection types and version-sensitive APIs.
Capabilities
The skill covers SQLite-backed agent state, client synchronization, SQL queries, WebSocket remote method calls, routing, delayed and recurring schedules, FIFO background queues, retries, durable fibers and Workflows. These are capabilities it explains or points to, not functions implemented by the instruction files themselves.
For AI applications, it covers persisted streaming conversations through AIChatAgent, resumable streams, tool interactions, human approvals and server-triggered conversation turns. Integration references address MCP clients and servers, inbound and reply email routing, webhooks, Web Push notifications and structured diagnostic events that can be forwarded through Tail Workers.
Experimental references cover browser interaction, voice, the higher-level Think chat class and Code Mode. Code Mode lets a model generate JavaScript that coordinates exposed tools inside an isolated Worker sandbox; its approval limitations are important before using it for actions with consequences.
Using it
Requirements
Using the instruction pack requires an assistant or reader able to access SKILL.md and its relative reference files. Following its documentation-oriented approach also requires access to the linked Cloudflare pages. The folder does not establish a supported assistant list, a minimum assistant version or an assistant-specific installation procedure.
The application examples require the agents package and Cloudflare Workers configuration with nodejs_compat, Durable Object bindings and SQLite-class migrations. Chat guidance adds agents, @cloudflare/ai-chat, ai and @ai-sdk/react. Model access and credentials depend on the chosen provider; Workers AI examples use an AI binding.
Optional features add their own requirements. Browser tooling uses BROWSER and LOADER bindings, Code Mode requires worker_loaders, and voice uses @cloudflare/voice with a selected speech provider. Minimum package versions and a complete compatibility matrix are not supplied.
Mechanism
SKILL.md acts as a task guide: it introduces the SDK, maps topics to documentation, provides compact examples and points to local references for deeper guidance. Its central approach is to consult current documentation instead of assuming an assistant’s remembered API knowledge is accurate.
The SDK architecture described in the skill routes requests to named agent instances, such as /agents/counter/user-123. State updates use setState, while methods decorated with callable are exposed over WebSocket RPC. The client reference distinguishes useAgent for React state and RPC, AgentClient for other WebSocket clients, agentFetch for one-off HTTP requests, and useAgentChat for chat messages and streaming.
These instructions guide code generation and review; they do not themselves provide a running server, a model connection or an authorization boundary. The routing reference shows hooks for connection and request authentication, and the client reference calls out token refresh and connection cleanup.
Setup
Obtain the instruction folder from the original repository and keep SKILL.md alongside references/ so its relative links remain usable. How to register that folder with a particular coding assistant is not documented in the supplied scope. The npm commands in the skill install application dependencies, not the skill itself.
For an application, the skill starts with checking for the agents package and installing it if absent. Its configuration guidance requires each exported agent class to have a matching Durable Object binding and new_sqlite_classes migration entry, with nodejs_compat enabled. New classes should receive new migration tags rather than changes to old migrations.
The configuration reference also describes Vite integration, extending agents/tsconfig, generating binding types with npx wrangler types, and storing secrets with Wrangler rather than hardcoding them. Its sample configuration needs adaptation to the actual class names, assets and selected services; it is not a universal project configuration.
Example
The supplied Counter example illustrates a small per-user stateful agent. It starts with count set to zero, rejects negative counts in a validation hook, and exposes increment as a callable method that updates state through setState. Requests use a route such as /agents/counter/user-123, while a React client selects Counter and the user-123 instance.
To turn this into an application, the project would need matching Counter bindings and migration entries, appropriate environment types, routing and client wiring. This example demonstrates state and remote calls, not AI model behavior. It is a source illustration only; no successful build, connection or state update was observed.
Assessment & evidence
Limitations
The skill is not self-contained: many references defer implementation details to external documentation, and installation commands do not pin dependency versions. Experimental browser, voice, Think and Code Mode APIs should not be assumed to have stable interfaces.
Two visible example issues need attention before reuse. The webhook snippet reads request.text() for signature verification and then reads it again for JSON parsing; an implementation should save and reuse the raw body. The durable-execution example calls ctx.stash as a function, while its API table describes a read/write property. These are source-level observations, not observed runtime failures.
The Code Mode reference explicitly states that needsApproval tools execute immediately in the sandbox without an approval pause. Its default blocking of external fetch calls does not replace authorization for tools exposed by the host. It should not be relied on to enforce human approval before consequential actions.
Background recovery also needs application design. The queue reference says exhausted items are removed and there is no built-in dead-letter queue. The fiber reference says the original function is not restored after eviction and errors are not automatically retried.
Reasoning
The strongest reason to use this skill is its treatment of engineering choices that can look interchangeable in a short generated example. It separates synchronized state from SQL collections, sequential queues from durable multi-step Workflows, and checkpointed fibers from automatic replay. Those distinctions matter when deciding what must survive disconnection, eviction or a failed external operation.
For chat, it distinguishes client reconnection from Durable Object eviction and message persistence from starting a model turn. The server-driven message reference calls for waiting for stable conversation state before non-chat updates, while the approval reference distinguishes approval responses from client tool outputs and calls out timeout handling.
These details make the skill more useful than a generic chatbot recipe, but their value is guidance rather than demonstrated reliability. Application-specific authorization, idempotent side effects, recovery handling and validation remain the developer’s responsibility.
Alternatives
The direct alternative to using the instruction pack is consulting the Cloudflare documentation it references, starting at [https://developers.cloudflare.com/agents/index.md]. That suits developers who prefer to work directly from documentation rather than through an assistant skill. The linked pages themselves are outside this report’s scope.
Within the described SDK options, AIChatAgent gives the developer control over the chat-generation implementation, while experimental Think supplies the streamText loop, tool execution and persistence behind a higher-level class. The Think reference requires an experimental compatibility flag.
The skill also identifies simpler choices for narrower tasks: ordinary tool calling instead of Code Mode for a single call, callable streaming RPC instead of chat machinery for non-chat output, and fetch instead of browser automation when HTML or API data is sufficient. No cross-vendor feature or performance comparison is established.
Evidence
The source material comprises SKILL.md, all 20 reference files in the agents-sdk folder and the repository-level LICENSE at revision 5108325ecceabc899c761e07aa617b09c02445ee. It provides detailed instructions and examples for intended API use, configuration and design tradeoffs.
The Agents SDK implementation, dependency packages, linked documentation pages, linked migration guides and other repository folders are outside the scope. Their URLs appearing in the skill does not establish their contents or compatibility.
No code was executed. The source material does not establish successful builds, production deployments, security-audit results, benchmarks or measured improvements in assistant output. Runtime behavior and compatibility with a particular project remain unassessed.
Access & freshness
Costs
The Apache license grants no-charge, royalty-free permissions for the covered material, but that does not establish free application deployment. Prices for the coding assistant, Workers, Durable Objects, storage, Workflows, model inference, browser services and voice providers are not supplied. Total operating cost is unknown.
The queue reference identifies a concrete cost consideration: retry delays keep the Durable Object active, and retries block later items in the sequential queue. It recommends considering execution cost and latency when choosing retry budgets and using scheduling for long recovery waits. No measured resource use or cost comparison is provided.
Rights
The repository LICENSE is Apache License 2.0, available at [https://github.com/cloudflare/skills/blob/5108325ecceabc899c761e07aa617b09c02445ee/LICENSE]. It permits reproduction, modification and redistribution of covered source material, including commercial use, subject to its conditions.
Redistribution requires a license copy, retention of applicable notices, prominent notices on changed files, and preservation of relevant NOTICE attributions if such a file accompanies the work. The license includes a qualified patent grant, does not provide general trademark rights, and supplies the work without warranty.
These terms support redistribution of the instruction pack with its license and applicable notices. They do not, by themselves, establish rights for external documentation, dependency packages or services referenced by the skill.
Freshness
This report describes the source snapshot obtained on 18 November 2026 at Git revision 5108325ecceabc899c761e07aa617b09c02445ee. That snapshot date is not established as the commit date or a release date, and the main branch may subsequently differ.
The files explicitly acknowledge version sensitivity. Chat guidance calls for checking installed agents, @cloudflare/ai-chat and AI SDK versions. MCP guidance prefers createMcpHandler over the deprecated McpAgent while making migration choices dependent on installed versions and session needs.
The compatibility_date of 2025-01-28 appears in an example Workers configuration; it is not an SDK version or evidence of a skill release date. Current dependency compatibility and the continued accuracy of linked documentation are not established by the instruction snapshot.
Actions
Start with the original instruction folder and retain its references and license. Confirm how your coding assistant accepts skills, then check the application’s installed package versions before applying examples. A small state-and-RPC application is a more focused starting point than enabling chat, browser, voice and background processing together.
Before production use, align class names, bindings and migrations; configure secrets and authentication; resolve the webhook body-reading and checkpoint API issues; and verify recovery for both client disconnection and Durable Object eviction. Record exhausted queue failures when recovery or auditing is required, and do not use the documented Code Mode path as a human-approval gate.
The included feedback guide provides a route for reporting incorrect skill guidance. It warns that GitHub issues are public, calls for removing sensitive information, and requires approval of the exact issue title and body before submission.
