Files
cc-switch/tests
Jason 31e5ae3f6a feat(sessions): show total tokens and API-price cost in the reader header
The reader toolbar now ends with the session's total tokens and its cost
at API prices, using the same totals and formatting as the usage
dashboard; hovering shows requests and the input / output / cache split.

The new get_session_usage_summary command sums only rows imported from
session logs: they carry the client's own session ID and are imported
whether or not the request went through the router, while proxy rows
carry an inferred ID and would double count. Sessions with no detail
rows (scanning off, or older than the 30-day rollup) show nothing.

The shared row-to-UsageSummary mapping is extracted so the dashboard
summary and the per-session query use one implementation.
2026-10-03 23:29:00 +08:00
..