Skip to main content
GET
Stream changes to the sessions gestalt as Server-Sent Events

Authorizations

Authorization
string
header
required

A Recursion API key, created in the console under API keys.

Headers

Last-Event-ID
string<date-time>

RFC 3339 read timestamp to resume from when after is absent. Required one way or the other, and rejected once more than 30 days old: take a new snapshot instead.

Query Parameters

agent_id
string

The same agent_id filter used for the snapshot.

since
string<date-time>
required

RFC 3339 start of the window, the same value the snapshot was taken with.

after
string<date-time>

RFC 3339 read timestamp to resume from: the snapshot's as_of, or the last frame's. The Last-Event-ID header is honoured when this is absent. Required one way or the other, and rejected once more than 30 days old: take a new snapshot instead.

Response

OK

One Server-Sent Event of streamSessionGestalt: the root sessions whose rows changed since the previous frame, with the read timestamp to resume from. Ordinary callers receive only unclassified public roots; callers with elevated classified-data access can receive classified updates and deletes.

as_of
string<date-time>
required

Read timestamp of this frame; also sent as the SSE id, so a reconnect with Last-Event-ID resumes here.

sessions
object[]
required

Roots visible to the caller in the window whose row changed since the previous frame, each carrying its whole current state; merge them by session_id. Ordinary callers omit classified updates and deletes. A row with deleted true has been removed.

reset
boolean

True when more changed than one frame carries. Discard the gestalt and take a fresh snapshot; sessions is empty.