vnStat
- async OPNsenseClient.get_vnstat_metrics(period)
Return parsed vnStat traffic rows for one supported reporting period.
- Parameters:
period (str) – Requested vnStat period identifier. Supported values are
hourly,daily,monthly, andyearly.- Returns:
- Parsed vnStat payload containing the selected
periodand aninterfacesmapping of interface names to traffic rows. Returns an empty mapping for unsupported periods or when no interface rows are available.
- Return type:
- async OPNsenseClient.get_vnstat()
Collect summarized vnStat usage data across available interfaces.
- Returns:
- Mapping with
interfaceskeyed by interface name and
interface_count. Each interface contains parsedhourly,daily, andmonthlyrows plus convenience byte counters for today, this month, yesterday, last month, and the last complete hour.
- Mapping with
- Return type:
MutableMapping[str, Any]