Replay timeline
Read what Oblive held for a business over any time range, and one entry's saved content.
The replay timeline answers “what did Oblive hold for this business at moment T?” for any range up to 92 days. It reads saved history only. It never calls a live provider, never fills a gap with current data, and never runs an agent. Running an agent at a past cutoff stays with replay environments. For the whole feature, see Replays and Replays architecture.
Turn it on for one business
Reads need two things: a deployment read token and a per-business flag.
- Set
REPLAY_READ_TOKEN(at least 32 characters) on the backend and the frontend server only. In the local stack, setreplayReadToken(at least 32 characters) inconfig/local-stack.jsonand runbun run stack env. The backend refuses to start when the token equalsAGENT_SERVICE_TOKENorRUN_EXECUTION_CAPTURE_READ_TOKEN, and the stack generator never gives it to agents. - Turn the flag on for the business. No API writes organization config, so it has its own command:
bun run replays:flag --organization 11111111-1111-4111-8111-111111111111 --enabled trueThe flag is off when absent. --enabled false turns it off again. The command changes only organizations.config.replaysEnabled and writes an audit line with the OS user and time.
Read a range
GET /organizations/{organizationId}/replays/timeline?from=2026-10-19T00:00:00.000Z&to=2026-10-26T00:00:00.000Z
Authorization: Bearer <REPLAY_READ_TOKEN>The range is [from, to). Each page holds at most 1,000 entries in available-time order. Pass pagination.nextCursor as cursor for the next page. The first page also carries start, the state at from, and startEntries, the entries that state names. timeline?from=T&to=T returns the state at T.
The response types, the fold and a synthetic fixture live in @oblive/types/replay-timeline:
import { foldReplayState } from "@oblive/types/replay-timeline";
const atPlayhead = foldReplayState(page.start, page.entries, playhead);An entry counts at T only when its available time is before T. Available time is the evidence-availability confirmedAt, or a run’s start or finish. A T after settledThrough (the database clock minus 5 minutes) is provisional, because a confirmation transaction may still be committing. Late arrivals describe the range but became available after to; they are for display and never enter the state.
Entries are visible only while their source is. A saved collection or recording is listed while its integration is enabled and its permission fingerprint matches the current one; reading its content runs the full archive authorization. An Insights result is listed while every analytical source it used is still readable. Internal revisions appear only for scopes the organization’s run-input policy allows. Archives saved before availability records existed appear as gap entries placed at their save time; they never enter the state.
Read one entry
GET /organizations/{organizationId}/replays/entries/observation%3A<archiveId>
Authorization: Bearer <REPLAY_READ_TOKEN>Content comes back as captured JSON, the newest 100 log items of a run with hasOlder, or metadata only. Database images (MongoDB and Redis backups) always return metadata only. Content past its original retention is refused with 410 before any byte is read, even while a replay pin holds it; on the timeline its values become a retention_insufficient gap. Only plain saved objects are served as JSON. Responses carry Cache-Control: no-store and X-Content-Type-Options: nosniff. Every authenticated read, served or refused, writes one audit line at a fixed level that no LOG_LEVEL silences: Replay timeline read. with the organization, the validated range, whether a cursor was sent and how many saved bodies were read, or Replay entry content read. with the validated entry ID. Invalid values are logged as invalid. Requests refused for their token are not logged there. Render content as text, never as markup: messages and pull requests carry third-party text.
Limits and errors
| Status | Code | When |
|---|---|---|
| 400 | invalid_request | A missing or malformed range, cursor or entry id. |
| 401 | agent_unauthorized | Any token other than REPLAY_READ_TOKEN, including agent capabilities. |
| 403 | replays_disabled | The business is unknown or inactive, or its flag is off. |
| 403 | forbidden_source | The source’s access changed since the entry was saved. |
| 404 | missing_source | The entry is not readable in this organization. |
| 409 | integrity_mismatch | Saved content no longer matches its recorded hashes. |
| 410 | content_expired | The content is past its original retention. |
| 413 | limit_exceeded | The range exceeds 92 days, the start exceeds 5,000 keys, or content exceeds 8 MiB. |
| 503 | replay_read_auth_unavailable | The read token is missing or shared with another credential. |
| 503 | replay_unavailable | Any other failure, including a saved record that breaks the contract. |
Ranges, pages and the starting state never truncate: a cap fails explicitly. The full rules are in
docs/plans/replay-rsi-v2/replay-api-and-ui-design.md and decision D046.