Pulse Stream
Real applications are full of moments worth reacting to: an order was placed, an agent finished a task, a threshold was crossed. Stream is how those moments travel. It's a per-project event bus — built on NATS JetStream — that your own code publishes to and subscribes from, so one part of your system can announce what happened and any number of others can act on it, without wiring every producer directly to every consumer.
It's genuinely yours to use, not just plumbing for the platform's own telemetry. You define the streams, you publish to them, and you decide who subscribes.
Publishing and subscribing
You create a stream, then publish events to it and open subscriptions:
POST /@<projectSlug>/data-streams/user
{
"displayName": "order-events",
"maxBytes": 1073741824,
"retentionSeconds": 3600
}
POST /@<projectSlug>/data-streams/user/<slug>/publish
GET /@<projectSlug>/data-streams/user/<slug>/subscribe (SSE, resumable with Last-Event-ID)
POST /@<projectSlug>/data-streams/user/<slug>/replay
The server SDKs wrap these calls. The stream's slug, derived from its display name, is what publish, subscribe and replay take:
Create the client once
import { createClient, realtimeTopic } from "@k9o/core";
const k9o = createClient({
orgSlug: "acme",
projectSlug: "task-app",
apiKey: process.env.K9O_API_KEY,
});Compute · Intelligent Messaging & Pub/Sub
// A producer publishes; any number of consumers subscribe, in order, from any point.
await k9o.streams.publish("orders", { id: 1, total: 42 }, { subject: "eu.new" });
for await (const event of k9o.streams.subscribe("orders", { fromSequence: 0 })) {
console.log(event.sequence, JSON.stringify(event.data));
}1 {"id":1,"total":42}A subscriber gets events as they happen. If it drops off and reconnects, it resumes from where it left off rather than missing what happened in the gap — and replay lets a consumer that's coming up fresh work through history from a point in time, so a new service can catch up on what it missed before it existed.
maxBytes is required and caps the stream's storage, from 10 MiB to 64 GiB. retentionSeconds is how long the stream keeps events available for replay, in steps of 15 minutes or whole hours. A short window is enough for consumers that are always online; a longer one is what lets a consumer rebuild state from the record after downtime.
Isolation you can rely on
Your streams are your own in a way that goes deeper than a naming convention. The platform's own telemetry rides the same bus, but as a separate tenant of it — a user/-scoped stream can never collide with a system one. And each project connects on its own cryptographic identity: a separate account on the bus, keyed under the region's own root of trust, so one project's traffic is walled off from another's at the connection layer, not merely filtered by an access rule sitting on top of a shared pipe. Isolation between projects is a property of the transport itself.
Alerting on what flows through
You don't always want to run a consumer just to notice something. A stream can carry alerting rules that watch for a condition and dispatch when it's met — a specific event, a threshold crossed within a window, or the absence of something that should have happened by now. A match sends an email or calls a webhook; webhook deliveries are signed so the receiving end can confirm they genuinely came from Kilimanjaro, and delivery is retried and dead-lettered rather than dropped, with an alarm if a channel goes unreachable. It's the difference between "something watches your data for you" and "you build and operate that watcher yourself."
Storage and delivery are two things
Keeping events on a stream — the retention window, the ability to replay — is what Stream itself meters: storage, essentially, priced by how much you hold and for how long. The moment a live subscriber holds a connection open and events are actively pushed to it, that live delivery is Pulse Feed, metered on its own. The two ride the same /subscribe call and complement each other: Stream is the record you keep, Feed is the push to whoever's watching right now. If you're delivering live updates to end-users' screens, read the Feed page next.