Skip to content

List Events

GET/v1/sessions/{session_id}/events

List the event history of a session.

Path parameters

stringsession_idrequired

The session ID (sess...)

Event object

Optional<string>id

Event ID (sevt...)

Optional<string>type

Event type (see below)

Optional<object[]>content

Typed content blocks carried by the event.

Optional<object | null>stop_reason

Reason execution stopped, when present.

Optional<string | null>model_used

Model used to produce the event, when applicable.

Optional<integer>tokens_in

Input tokens for this event (0 when N/A)

Optional<integer>tokens_out

Output tokens for this event (0 when N/A)

Optional<integer | null>duration_ms

Processing duration in milliseconds, when measured.

Optional<string | null>processed_at

RFC 3339 processing timestamp, when available.

Optional<string>created_at

RFC 3339 timestamp