cloudflare/agents

Build and deploy AI Agents on Cloudflare

View on GitHub ↗Jump to charts ↓Open shareable report

Summary Information

Updated 43 minutes ago
Added to GitGenius on February 23rd, 2026
Created on January 29th, 2025
Open Issues & Pull Requests: 162 (+0)
Number of forks: 678
Total Stargazers: 5,484 (+0)
Total Subscribers: 34 (+0)

Repository Insights (GitGenius)

Median issue/PR response: 3.9 hours
Mean response time: 10.3 days
90th percentile: 24.3 days
Tracked items: 688

How this project is maintained

Around half of the issues opened in the past year never receive a reply. 99% of open issues come from outside the core team, so the backlog reflects real-world use rather than internal planning. Almost all tracked open issues have seen activity in the last three months. Only 10% of issues opened in the past year have been closed. Three people close 79% of everything that gets resolved.

Charts & Analytics

Fetching additional details & charts...

Issue Activity (beta)

Open issues: 117
New in 7 days: 8
Closed in 7 days: 6
Avg open age: 39 days
Stale 30+ days: 38
Stale 90+ days: 5

Recent activity

Opened in 7 days: 7
Closed in 7 days: 5
Comments in 7 days: 7
Events in 7 days: 22

Top labels

  • enhancement (110)
  • bug (82)
  • mcp (42)
  • on the roadmap (38)
  • question (13)
  • documentation (9)
  • details required to debug (7)
  • breaking change (3)

Detailed Description

The Cloudflare Agents repository provides a TypeScript SDK for building and deploying AI agents on Cloudflare's infrastructure. Agents are persistent, stateful execution environments powered by Cloudflare Durable Objects, enabling developers to create long-lived, intelligent applications that maintain their own state, storage, and lifecycle. Each agent can operate independently with built-in support for real-time communication, scheduling, AI model integration, and more. A key architectural advantage is that agents automatically hibernate when idle and activate on demand, allowing millions of concurrent agents to run cost-effectively since inactive agents incur no charges.

The core SDK encompasses a comprehensive feature set designed for production agentic workloads. Persistent state automatically syncs across all connected clients and survives restarts. Type-safe RPC is enabled through callable methods decorated with the @callable() decorator. The framework supports sub-agents through parent-child Durable Object composition via facets and nested routing. Agents can execute as tools themselves with streaming child timelines, and the platform includes one-time, recurring, and cron-based task scheduling. Real-time bidirectional communication occurs through WebSocket connections with lifecycle hooks, while AI chat functionality provides message persistence and resumable streaming. The SDK acts as both MCP servers and clients across multiple transport protocols, exposes browser-side tools to agents via WebMCP, and supports durable multi-step workflows with human-in-the-loop approval capabilities.

The repository is organized into multiple specialized packages. The core agents package contains the Agent class, routing, state management, scheduling, MCP, email, workflows, x402 payments, and browser agent support. The ai-chat package provides higher-level AI chat abstractions with persistent messages and tool execution. The think package offers an opinionated chat agent base with agentic loops and stream resumption. Additional packages handle code mode execution where LLMs generate executable TypeScript, sandboxed execution with virtual filesystems, voice pipelines with STT and TTS, runtime Workers bundling, and Hono middleware integration.

The repository includes over 30 self-contained examples demonstrating various capabilities including a kitchen-sink playground showcasing all features, multiple chat and assistant implementations, MCP server and client patterns, code mode and sandbox examples, voice agents, workflow approvals, authentication, payments, email integration, and game implementations. Examples also cover integration with the OpenAI Agents SDK.

The repository overlaps with other Cloudflare projects including workers-sdk, and external projects like gitpod and opencode based on shared contributor networks.

Development uses Node 24 or higher with pnpm workspaces and Nx for task orchestration. The project is classified across edge computing, serverless, distributed systems, and developer tools domains. While external pull requests are not currently accepted due to rapid SDK evolution, the maintainers actively encourage bug reports, feature requests, and community discussion through GitHub issues and discussions.