Agent skill · Databases

realtime

Use when enabling WebSocket subscriptions for live database changes, presence/multiplayer state, or when debugging clients that connect but receive no events

butterbase.ai2,831★ · +400/wk · 1 repos on radarProfile →
claude-codeMIT
Install
npx skills add butterbase-ai/butterbase-skills --skill realtime --agent claude-code

Same command for any agent — swap --agent for codex, cursor, copilot.

Facts
Files in the skill folder: 1
SKILL.md size: 8 KB
Bundled scripts: none
Path: skills/realtime/SKILL.md
Open the folder on GitHub →
Where it comes from
Stars: 532

Weekly change comes from our own snapshots, not the repository page — it measures attention, not adoption.

From the SKILL.md

# Butterbase Realtime Live database change notifications over WebSocket, with per-row RLS enforcement. Once a table is enabled, INSERT/UPDATE/DELETE events stream to subscribed clients **filtered by the same RLS policies** that gate reads. One tool: **`manage_realtime`** with two actions: `configure` and `get`. --- ## 1. The mental model ``` Postgres (data plane) Control API Browser ───────────────────── ──────────── ──────── INSERT/UPDATE/DELETE ──trigger──► realtime.changes ──WAL listener─► WebSocket ──► client │ └── RLS check per (role, user) ──► filter rows ``` When you `configure` a table: 1. A Postgres trigger is installed → writes every change to `realtime.changes`. 2. A LISTEN connection in `RealtimeManager` reads those changes. 3. For each connected client, the change is RLS-checked **as that user** before broadcasting. 4. Clients only receive events for rows they could read with a regular SELECT. --- ## 2. Prerequisites Before calling `configure`, the table must: 1. **Exist.** Run `manage_schema` (`action: "apply"`) first. Realtime won't auto-create it. 2. **Have RLS configured (if you care about isolation).** Realtime respects whatever policies exist via `manage_rls`. **

What's inside
Steps it walks through
  1. 1. The mental model
  2. 2. Prerequisites
  3. 3. Configure tables
  4. Inspect current state
  5. 4. Connect from a client
  6. Welcome and protocol
  7. Client → server messages
  8. Server → client messages
  9. 5. RLS enforcement (the critical pitfall)
  10. Anonymous clients
  11. 6. Connection lifecycle
  12. 7. Common patterns
  13. Live chat
  14. Live dashboard / activity feed
More from butterbase-skills
All skills →
About this skill
What does the realtime skill do?

Use when enabling WebSocket subscriptions for live database changes, presence/multiplayer state, or when debugging clients that connect but receive no events

How do I install it?

Run `npx skills add butterbase-ai/butterbase-skills --skill realtime --agent claude-code` — it drops the skill into your project so the agent can pick it up. Swap the --agent value for codex, cursor or copilot if you use one of those.

Where does this skill come from?

From butterbase-ai/butterbase-skills, a repository with 532 stars. We read it straight from the repository tree rather than a submitted listing, so what you see here is what is actually published.

Is a popular skill a good skill?

Not necessarily. Stars measure attention, not adoption — a repository can trend for a week and be abandoned. That is why we show the weekly change from our own snapshots next to the total, instead of a single flattering number.

Keep going