durable-objects

Manage stateful coordination and SQLite-backed storage for Cloudflare Workers.

2|Updated Mar 29, 2026
One-click install
npx skills add https://github.com/NagyVikt/codex-plugins --skill durable-objects-nagyvikt
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: durable-objects
Source: https://github.com/NagyVikt/codex-plugins/tree/main/plugins/cloudflare/skills/durable-objects
Command: npx skills add https://github.com/NagyVikt/codex-plugins --skill durable-objects-nagyvikt

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve?

This skill addresses the complexity of managing stateful coordination, persistent connections, and strong consistency requirements in serverless edge environments.

Core Features & Use Cases

  • Stateful Coordination: Manage chat rooms, multiplayer game sessions, and collaborative document states with strong consistency.
  • Persistent Connections: Handle WebSocket connections and real-time notifications directly at the edge.
  • SQLite Storage: Implement per-entity storage using built-in SQLite, ideal for multi-tenant SaaS or per-user data management.

Quick Start

Use the durable-objects skill to initialize a new stateful class with SQLite storage and configure the necessary wrangler bindings for your project.

Frequently Asked Questions about durable-objects

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I manage stateful coordination and persistent storage in Cloudflare Workers?

Stateful coordination in Cloudflare Workers is managed using Durable Objects to maintain strong consistency and persistent storage directly at the edge. This approach facilitates the implementation of RPC methods and SQLite-backed entity state for serverless applications.

What is the best way to handle WebSocket connections at the edge?

Handling WebSocket connections at the edge is best achieved using Durable Objects within Cloudflare Workers. They provide persistent connections and real-time notification capabilities, ensuring stateful coordination for applications like chat rooms or multiplayer game sessions.

Can I use SQLite for per-entity storage in serverless edge environments?

Yes, you can implement per-entity SQLite storage in serverless edge environments using Cloudflare Durable Objects. This built-in SQLite storage is ideal for managing multi-tenant SaaS data or per-user states with strong consistency requirements.

How do I configure wrangler bindings for a new stateful class with SQLite storage?

Configuring wrangler bindings for a stateful SQLite class requires initializing a new Durable Object in your Cloudflare Workers project. This setup ensures architectural compliance with Cloudflare's concurrency, migration, and testing best practices for edge applications.

When do I need Durable Objects for my Cloudflare Workers application?

You need Durable Objects when your Cloudflare Workers application requires stateful coordination, persistent connections, or strong consistency. They are essential for managing collaborative document states, real-time notifications, and per-entity SQLite storage in serverless edge environments.

Does this approach ensure architectural compliance with Cloudflare's concurrency and migration best practices?

Yes, using Durable Objects ensures architectural compliance with Cloudflare's concurrency, migration, and testing best practices. This approach provides strongly consistent stateful coordination and persistent storage for edge applications, preventing common serverless state management issues.