Package Exports
- @coderbuzz/kvs
Readme
KVS — @coderbuzz/kvs
Self-hosted key-value store for serverless and edge workloads. SQLite-backed. HTTP API. TypeScript SDK. No Redis tax.
Atomic transactions, TTL expiry, built-in queue with retries, real-time WebSocket watch, and push-based work-stealing listeners. Runs anywhere Bun or Node.js runs.
Why KVS Over Redis?
- Self-hosted — no Redis server, no memory overhead, just a SQLite file (~300 KB)
- Zero ongoing cost — deploy on a $5 VPS or Fly.io
- Hierarchical keys —
["users", "alice", "profile"]instead ofuser:alice:profile - Built-in queue — delayed delivery, retries, work-stealing — no separate broker needed
- Real-time watch — subscribe to key changes over WebSocket push, not polling
- Atomic transactions — mix set/delete/enqueue with version checks in one commit
Installation
npm install @coderbuzz/kvsQuick Start
import { KvsClient } from "@coderbuzz/kvs";
const kv = new KvsClient({ url: "http://localhost:3000", token: "my-token" });
await kv.set(["greeting"], "hello world");
const value = await kv.get(["greeting"]);
// => "hello world"
await kv.set(["users", "42"], { name: "Alice", plan: "pro" }, { ttl: 86_400_000 });
const user = await kv.get(["users", "42"]);
// => { value: { name: "Alice", plan: "pro" }, version: 1 }Documentation
Full API reference, self-hosting guide, and deployment examples: DOCS.md
License
MIT © 2026 Indra Gunawan