A session is one recorded run of a workflow. It is the only object you create directly — frames, events, and memory entries are derived from it.Documentation Index
Fetch the complete documentation index at: https://docs.nusomi.com/llms.txt
Use this file to discover all available pages before exploring further.
Lifecycle
| State | Meaning |
|---|---|
created | Session exists but capture hasn’t started. Useful when you want to set metadata before pressing record. |
recording | Frames and events are streaming in. Session is mutable. |
stopped | Capture ended. Indexing has begun. Querying events is allowed but some derived data (memory edges, dataset exports) may still be in progress. |
sealed | Indexing complete. Session is immutable. Replay, recovery, and export are fully available. |
sealed within seconds of stopped for short runs (under five minutes) and within a minute or two for hour-long runs.
Core fields
| Field | Type | Notes |
|---|---|---|
id | string | Format: ses_<26 char id>. Stable, unique within workspace. |
workflow | string | Free-form name. Best practice: stable slug like process_invoice. Used for cross-run grouping in the memory graph. |
status | enum | One of the lifecycle values above. |
metadata | object | Arbitrary JSON. Keep PII out — see masking. |
started_at | timestamp | ISO 8601 UTC. |
stopped_at | timestamp | null | Null while recording. |
duration_ms | integer | Wall-clock duration. |
frame_count | integer | Total captured frames. |
event_count | integer | Total extracted events. |
actor | object | { id, kind: "human" | "model" | "script" }. |
Creating a session
Stopping a session
Stop is idempotent. Calling it twice is safe.Tagging mid-run
You can attach tags as a workflow runs to mark important moments. Tags become anchors in the memory graph.Listing & filtering
Best practices
- Use a stable
workflowslug. It’s the join key across runs.process_invoicegood,Invoice for Acme — May 7bad. - Keep metadata small and structured. Anything you’d want to filter by later goes here. Don’t dump entire request payloads.
- Don’t log secrets in metadata. Field-level masking only kicks in for captured screen content, not for what you put in metadata yourself.
- Stop sessions deterministically. Wrap in
try / finallyso a thrown error doesn’t leave a session recording forever.