Learn how to build event-sourced applications with Tannur.
npm install @tannur/sdkimport { Tannur } from "@tannur/sdk";
const tannur = new Tannur({
apiKey: process.env.TANNUR_KEY
});await tannur.append("orders", {
type: "ORDER_CREATED",
data: { id: "ord_123", total: 99.99 }
});tannur.append(stream, event)Append a new event to a stream
tannur.read(stream, options)Read events from a stream
tannur.subscribe(stream, callback)Subscribe to real-time updates
tannur.project(stream, reducer)Create a projection from events