Skip to content

Live events

Use the full event stream when you need canonical updates rather than refetching an entire conversation after each notification.

  1. Establish a stream and its cursor before loading the initial snapshot; buffer events while the snapshot loads.
  2. Load the current authorized history once.
  3. Apply buffered and subsequent events, merging messages by their canonical IDs.
  4. Persist an event’s sequence after applying it successfully.

This avoids a gap between reading history and starting to listen. For invalidation-only consumers, the summary stream is an explicit alternative; it does not contain the full message body.

Language API
Python client.events(after=saved_cursor) iterator
TypeScript client.events({ after: savedCursor, signal }) async iterator
Go client.StreamEvents(ctx, EventOptions{After: cursor}, handler)

These are call shapes inside an initialized application, not standalone programs. The SDK reference and maintained client types describe the complete inputs.

Consumers resume from the last fully handled frame and skip replay. Normal server stream rotation reconnects automatically. Authentication denial terminates the stream instead of retrying forever.

A sequence is a resume cursor, not a count of messages you are entitled to see. Server visibility checks still apply. Clear cached private data when identity or access changes, and obey the current history window rather than assuming every message is retained in the initial snapshot.


Read this page as Markdown