Speedtest
- async OPNsenseClient.get_speedtest()
Return the latest and average Speedtest result summaries.
- Returns:
- Mapping with
availablepluslastand averagesections for download, upload, and latency. Latest results include server, date, and URL metadata; averages include min, max, sample count, and period bounds. Returns{"available": False}when show-log is absent (404 in either mode), or on 403/transient HTTP or transport failures withthrow_errorsoff. Those failures raiseOPNsenseErrorwhen enabled. Undecodable JSON returnsNonewhen errors are disabled and raisesOPNsenseErrorotherwise.
- Mapping with
- Return type:
- async OPNsenseClient.run_speedtest()
Start a Speedtest run and return the raw run response.
- Returns:
- Response mapping from the Speedtest
run endpoint, or an empty mapping when the availability check finds the endpoint absent (404 in either mode), or a 403/transient HTTP or transport failure with
throw_errorsoff. Those failures raiseOPNsenseErrorwhen enabled. The run request is ungated, so its HTTP/transport failures, including 404, raiseOPNsenseErrorwhen enabled and return an empty mapping otherwise. Non-mapping JSON also returns an empty mapping. Undecodable JSON returnsNonewhen errors are disabled and raisesOPNsenseErrorotherwise.
- Response mapping from the Speedtest
- Return type: