Cloudflare is pushing forward aggressively with its ambition to shape the future of AI agents, foreseeing a time when AI will not just assist us but take over entire tasks independently. Recently, Cloudflare made numerous announcements to speed up this agentic development. These advancements include new Agents SDK capabilities, integration of various authentication providers, hibernation features for McpAgent, inclusion of Durable Objects in the free tier, general availability of workflows, AutoRAG for context-aware AI integration, and a new landing page dedicated to agents.
1. New Agents SDK Capabilities
AI agents can now be enhanced to connect and interact with external services using the updated MCP (Model Context Protocol). These enhancements allow developers to build remote MCP clients that come with integrated transport and authentication features. This move is aimed at creating agents capable of securely linking to various third-party services. Specifically, this update brings several crucial features: end-users can be prompted to grant access to third-party services, indicating tools for the agent to use. Moreover, AI agents can now call MCP servers from workflows, scheduled tasks, or any part of the agent, giving them extensive operational flexibility. Finally, agents can seamlessly connect with multiple MCP servers and discover new tools or capabilities provided by third-party services.
2. Build Your Own Authentication Provider for MCP
To ensure secure and reliable connections, integrating authentication and authorization systems is pivotal. Cloudflare now supports integrations with Stytch, Auth0, and WorkOS, making it easier for developers to add these security measures to remote MCP servers. This integration ensures that AI agents can connect to third-party MCP servers in a secure and authenticated manner. By leveraging these integrations, developers can support a variety of authentication flows, including email, social logins, and single sign-on (SSO). This makes it possible to give users fine-grained control over what the AI agents can access, with permissions and consent forms tailored as required. Through these integrations, developers can easily map authorization scopes to the MCP tools and enforce these permissions so agents can only perform allowed actions.
3. Hibernation for McpAgent
The McpAgent class now supports a new WebSockets Hibernation API, allowing MCP servers to sleep when not in use and wake up as needed. This feature offers significant advantages by enabling the maintenance of long-running connections without incurring idle time costs. This is particularly useful for stateful connections where an agent needs to remember context or user preferences. During periods of inactivity, these stateful agents can hibernate, thus optimizing resource usage and incur costs only when actively performing tasks.
4. Durable Objects Free Tier
Now, Durable Objects, a key building block for AI agents, have been included in the free tier. Durable Objects provide both compute and durable storage that are indispensable for developing stateful, serverless applications. These objects act as stateful coordinators, managing real-time client interactions and performing tasks such as making requests to external services. Each Durable Object maintains its state, providing capabilities like zero-latency SQLite storage. With the inclusion in the free tier, developers can now start building and deploying AI agents without any initial commitment, utilizing Durable Objects to scale to millions of agents effortlessly.
5. Workflows General Availability
The general availability of workflows now allows developers to ship production-ready, long-running, multi-step actions in agents. This development is essential for creating complex task flows that need to persist over extended periods. Workflows enable agents to execute multi-step processes with ease, thus unlocking new possibilities for automation and task delegation to AI agents.
6. AutoRAG for Context-Aware AI
AutoRAG (Automatic Relevance and Activation Generator) is another significant development that simplifies integrating context-aware AI into applications. This feature allows developers to embed AI context-awareness in just a few clicks, making it feasible to create agents that can understand and react to context dynamically. AutoRAG is invaluable for developing intelligent agents capable of making contextually informed decisions.
7. New Landing Page for Agents
Cloudflare has launched a new landing page dedicated to AI agents, agents.cloudflare.com. This platform provides all necessary information and resources for those new to agents and seasoned developers. It serves as a one-stop solution for finding everything related to building and maintaining AI agents, from SDK documentation to best practices.
8. New MCP Capabilities in Agents SDK
The updated Agents SDK now includes features aimed at enhancing AI agents’ capabilities in connecting to external services. One important feature is the ability of agents to prompt end-users to grant access to third-party services, essentially allowing the agent to use tools hosted on these services. Furthermore, agents can now call MCP servers from workflows, responding to scheduled tasks or other parts of the agent’s operation. The SDK allows for multiple connections to MCP servers, enabling agents to dynamically discover new tools and capabilities provided by third-party services.
The AI agents’ ability to act as remote MCP clients includes handling transport over Server-Sent Events (SSE) and HTTP, managing connections, discovering tools and capabilities, receiving real-time updates, and maintaining namespaces across multiple services. These features make agents robust and flexible, capable of navigating various external environments seamlessly.
9. Granting Agents Access to Tools with Built-In Authentication Check for MCP Clients
To ensure secure operations, the Agents SDK incorporates a full OAuth authentication flow that allows AI agents to connect to and authorize third-party MCP servers. This integration supports the OAuth 2.1 protocol, which simplifies securing these connections. The SDK automatically handles user redirection, code challenges, authorization code exchanges, and access tokens to make authenticated requests to the MCP server. This built-in flow eliminates the need to develop custom solutions, providing a uniform and secure method for user authentication and authorization.
10. Connecting to Multiple MCP Servers and Discovering Capabilities
With the Agents SDK, developers can simultaneously connect to multiple MCP servers, consolidating and utilizing tools and resources from diverse sources. The key class, MCPClientManager, maintains all these server connections, managing state and ensuring that each connection operates independently without conflicts. This allows the AI agent to navigate multiple environments, discover capabilities, and leverage tools on different servers without risk of namespace collision or efficiency loss.
By maintaining separate authentication contexts for each server, the SDK makes it possible for an AI agent to authenticate and interact with several servers without disrupting processes on any one of them. This feature is particularly useful for developers looking to create versatile agents capable of performing a wide range of tasks based on different service providers’ tools and resources.
11. Bring Authentication & Authorization to Your MCP Server
Developers can now utilize Stytch, Auth0, and WorkOS for comprehensive authentication and authorization systems on their MCP servers. These integrations enable users to sign in through various methods, including email, social logins, and enterprise SSO. They also allow developers to define precise scopes and permissions that map directly to the tools available in MCP. As a result, each user’s interaction with the AI agent is controlled and authorized by their role and permissions within the organization.
For example, using WorkOS, developers can dynamically expose capabilities to AI agents based on the authenticated user’s access rights. This is critical for maintaining security while providing the necessary functionality to users. Stytch and Auth0 also simplify this process, presenting users with consent pages that outline the specific permissions being requested, ensuring that only authorized tools are accessed by the agents. These integrations offer robust security measures, essential for production environments where user data and actions must be tightly controlled and monitored.
12. WebSockets Hibernation: Sleep Mode for Inactive Agents
To optimize resource usage and reduce costs, the McpAgent class now supports the WebSockets Hibernation API, allowing AI agents to go to sleep during periods of inactivity. This automatic hibernation feature preserves the state of the MCP servers, ready to instantaneously wake up when needed.
When a Server-Sent Events (SSE) endpoint request is received, the connection is managed through a WebSocket linked to Durable Objects. During inactivity, the Durable Object can be evicted from memory while keeping the WebSocket open. If activity resumes, the system recreates the Durable Object, ensuring seamless and efficient operation. This hibernation capability ensures that developers only pay for compute resources when the agents are actively working, providing a more cost-effective solution for long-running stateful servers.
13. Benefits of Durable Objects on Free Plan
To further entice developers, Durable Objects are now available on Cloudflare’s free plan, aligning with the goal of enabling the development of real-world applications without significant financial commitment. The free-tier limits are reasonable, allowing for extensive use before incurring costs. For compute requests, the limit is 100,000 per day, while compute duration is capped at 13,000 GB-s per day. Additionally, developers can read up to 5 million storage rows per day and write up to 100,000 storage rows per day. SQL stored data is allowed up to a limit of 5 GB.
These limits offer substantial resources for developers to experiment and deploy AI agents to assess their real-world performance and scalability. By making these provisions available for free, Cloudflare is lowering the barrier to entry for AI agent development, encouraging innovation, and fostering a robust developer community around its technologies.
14. Summary and Additional Resources
Cloudflare is aggressively advancing its vision for the future of AI agents, aiming for a time when AI will not just assist us, but will handle entire tasks autonomously. Recently, the company made several announcements to accelerate this agentic development. These updates include new Agents SDK capabilities and improved integration with various authentication providers. Additionally, they are introducing hibernation features for McpAgent, offering Durable Objects in the free tier, and making workflows generally available.
One of the key updates is the introduction of AutoRAG, a feature designed for context-aware AI integration that represents a significant step forward in making AI more intelligent and adaptable. Additionally, Cloudflare has launched a new landing page dedicated to its agents, making it easier for developers and organizations to understand and leverage these advancements.
These initiatives are part of Cloudflare’s broader strategy to enable more sophisticated and autonomous AI applications. By offering advanced tools and resources, Cloudflare is positioning itself at the forefront of the AI revolution, aiming to reshape how we interact with and utilize AI-driven technologies in the near future.