local-first · peer-to-peer

Stays in sync.
Even offline.

Creeba keeps your app and its data in agreement across every device — directly peer to peer. A server is optional; the internet is optional.

$ bun add @streamline-pulse/creeba-core

How it works

Three moving parts. No server in the middle.

  1. 01

    Capture

    Every change becomes an operation in a local, append-only journal — the op-log. Your database keeps working exactly as before.

  2. 02

    Gossip

    Peers exchange those operations directly — over the LAN via mDNS, or across the internet through encrypted QUIC. No round-trip to a server.

  3. 03

    Converge

    A hybrid logical clock and last-writer-wins merge replay the journal in order, so every device ends up in agreement — automatically.

Why creeba

Local-first, without the lock-in.

Pluggable transports

Encrypted QUIC over iroh with serverless mDNS discovery. Swap the transport, keep the core.

Portable op-log

Hybrid logical clock + LWW convergence — mergeable state across nodes, no database lock-in.

Opaque payloads

Your database stays local. The network carries only your app's payloads — never the database.

Offline by default

The app runs entirely on the device. No connection required, ever — sync catches up when peers meet.

Bring your own store

Plug an OpStore + Projection over Prisma, SQLite, DuckDB or raw SQL. The core has zero native deps.

Typed & tiny

TypeScript-first, generic over your payload. Runs on Bun, Node, the browser and React Native.

Minimal setup

A transport, your payload, done.

sync.ts
import { CreebaSync } from '@streamline-pulse/creeba-core'
import { IrohMdnsTransport } from '@streamline-pulse/creeba-iroh-mdns'

const sync = new CreebaSync({
  transport: new IrohMdnsTransport(),
  identity: { userId },
  topic: 'my-app',
})

// received from a peer → persist locally
sync.on('data', (change) => store.apply(change))

await sync.start()
sync.broadcast(change)
Works with your stack

One binding, every relational store — plus Mongo.

PostgreSQLMySQL / MariaDBSQLiteCockroachDBMongoDB…or your own store

@streamline-pulse/creeba-oplog-prisma captures mutations transparently via a Prisma $extends — one schema covers the relational connectors, a Mongo variant is provided. No ORM? Implement two small interfaces.

Where it fits

Real apps, real users, shaky connectivity.

Offline-first shops

Point-of-sale and stock that never freeze when the Wi-Fi drops mid-sale.

Field teams

Inspectors, deliveries, surveys — capture on the ground, converge back at base.

Clinics & sites

Records that stay available and consistent across devices on the same network.

Multi-tenant SaaS

Each organisation's data converges cleanly and stays isolated from the rest.

Build local-first — without the rewrite.

Add creeba to the database and app you already have.

$ bun add @streamline-pulse/creeba-core