Get top-level chain overview stats.
Reads the single-statement network-stats query (latest ledger row + ledgers 60s aggregate for TPS + deduped counts of accounts / contracts) and caches the assembled response keyed on the chain head (latest_ledger_sequence) in process memory — see network/cache.rs. See the task 0045 spec and network::queries::fetch_stats for the full data-source mapping.
Per request we first read the head cheaply (crate::common::head — SELECT max(sequence), a primary-key probe) and look up the cache under it: an unchanged head is a HIT (the new ledger has not landed), an advanced head is a MISS that recomputes once. So a new ledger is visible on the first request after it is written — there is no up-to-TTL window serving the previous head (task 0291).
Concurrent cold-cache requests deduplicate via moka::future::Cache::try_get_with — the first task runs the async DB query and the rest wait on its result instead of fanning out N round-trips.
Request
- The document declares no server URL.
- Auth: one of:
- API key in header x-api-key
- HTTP bearer
Response
Chain overview stats
Changes
No recorded changes to this operation across all 50 revisions of this API.