Sessions
Browse and inspect individual Claude Code sessions — the list view, the summary, and the session call graph.
What is a session?
A session is one continuous Claude Code work session. Trenchcoat creates a
session row the first time it receives any event carrying a given session_id,
and every later event with that id joins the same session — including
late-arriving ones from a retry.
Sessions are the primary unit of attribution: tokens, tool calls, subagents and cost estimates all roll up to a session.
A session's started_at and ended_at are derived, not reported. Trenchcoat
takes the earliest and latest event timestamps it has ingested for the session,
so Duration is wall-clock across captured events. There is no separate
"session closed" signal and no inactivity timeout.
The plugin flushes its event queue only at SessionEnd. A session that ends
uncleanly — a crash, a closed laptop, a killed terminal — leaves its hook events
queued locally, and they are delivered by a later session's flush. If Claude
Code's OpenTelemetry export is also configured, that half arrives continuously
(~5s) and is unaffected.
Sessions list
Sessions in the sidebar shows a paginated table, 20 rows per page, most recent first.
| Column | What it shows |
|---|---|
| Started | Start time in your local timezone. This is the link into the detail view |
| Summary | A one-line, model-written description of what the session was for — see below |
| Duration | Wall-clock from first to last captured event |
| Events | Total events ingested for the session |
| Tools | Count of tool events |
| Cost | Estimated cost. -- means the session's model has no pricing row and could not be priced |
The Summary column has five states
The summary is generated by a model from the prompt and response text captured on the OpenTelemetry path. The states are deliberately distinct because they have different causes and different remedies:
| State | Means |
|---|---|
| (the summary text) | Generated successfully |
| Generating… | Queued; the job runs about two minutes after the session ends, to let the last turns arrive |
| No content | The session genuinely captured no prompt or response text, so nothing was summarised and no model was called |
| Not captured | No summarisation was ever attempted for this session |
| Unavailable | Generation was attempted and failed |
Summaries require an API key with the read:prompts capture level (or
read:full) and Claude Code's OpenTelemetry export configured. Without both,
every session shows No content. The captured text is sent to a model —
claude-haiku-4-5-20251001 — to produce the summary, not merely stored.
Filtering
- Date range — the same picker used across the dashboard.
- Branch — only populated if the plugin's
privacy.capture_git_branchis turned on. It is off by default, so this filter is usually empty. - Machine — the global machine filter. Each API key maps to one machine, so this filters by the key that ingested the session.
Session detail
Click a Started timestamp to open the detail view.
Cards
Summary, Duration, Events, Tools Used, Branch, and Total Cost. A session spawned by another shows a "Subagent session — spawned by" banner linking to its parent.
Cost breakdown
Total cost split by token type — input, output, cache-creation, cache-read. This is where an expensive session usually explains itself: cache-read tokens routinely dominate.
Cost is an estimate, not Claude Code's billed figure. Trenchcoat prices its
own reconstructed token counts against a community-maintained rate table
(LiteLLM). A model with no pricing row prices as -- rather than $0.00.
Outcome signals
Why the turn stopped, and whether the session hit context compaction. The stop
reason prefers Claude Code's own OpenTelemetry value and falls back to the
plugin's — the plugin's is structurally one turn behind and reads unknown on
most sessions.
Timeline
A chronological list of the session's events — tool calls, skill activations, subagent spawns — oldest first.
Subagent sessions and call graph
Subagent Sessions lists the agents spawned during the session with their type, model, duration, tool count and cost. Call graph renders the session as a directed graph: the session, its skills, agents and tools, with edges showing what invoked what. Node kinds are colour-coded and each node carries its own cost.
How events are matched to sessions
Every event sent to the API carries a session_id, set from the value Claude
Code supplies at hook invocation. The API upserts the session row from it and
associates the event.
The hook path and the OpenTelemetry path both report a session id, and they are
believed to agree for a live, non-resumed session — but they are stored in
separate tables with no join, and the agreement has never been verified at
scale. Claude Code mints a new OTel session.id on resume/continue; whether the
hook's id does the same is unresolved. Do not build on the assumption that it
does.