You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
@@ -605,8 +606,10 @@ Plugins import the singleton and consume it from `_grab_stats`:
605
606
```python
606
607
from glances.cpu_sampler_v5 import sampler
607
608
609
+
608
610
classPluginModel(GlancesPluginBase[dict]):
609
611
plugin_name ="cpu"
612
+
610
613
asyncdef_grab_stats(self) -> dict:
611
614
agg =await sampler.get_aggregate()
612
615
...
@@ -771,6 +774,8 @@ Routes live in `glances/routes_v5.py` as a single `APIRouter(prefix="/api/5")`,
771
774
|`/api/5/token`| POST | Basic (route-level) |`app.state.jwt_handler`| Exempt from the global Auth middleware (listed in `UNAUTH_PATHS`). Returns `{access_token, token_type:"bearer", expires_in}`. 404 if `[outputs] password` is unset. |
|`/api/5/all`| GET | per-config |`store.as_dict()`| Every plugin's payload in a single dict. Plugins that have never written are absent. |
777
+
|`/api/5/all/limits`| GET | per-config | per-plugin `get_limits()`| Effective thresholds for every registered plugin. Plugins with no watched field are omitted. |
778
+
|`/api/5/<plugin>/limits`| GET | per-config |`plugin.get_limits()`| Effective thresholds — config layered over `default_thresholds`. `200 {}` when the plugin has no watched field, or for the 6 plugins that override `_derived_parameters()` (`sensors`, `wifi`, `folders`, `raid`, `ports`, `amps`) even when thresholds are active; `404` if not registered. Never subject to cycle-0 `null`: thresholds come from config + schema. See `docs/superpowers/specs/2026-08-03-glances-v5-limits-routes-design.md`. |
774
779
|`/api/5/alert`| GET | per-config |`alerts.get_history()`| Returns the ring buffer. 404 if `alerts is None`. |
775
780
|`/api/5/config`| GET | per-config |`config.as_dict_secure()`| Redacted via `as_dict_secure()` — CVE-2026-32609 / 30928. |
776
781
|`/api/5/<plugin>`| GET | per-config |`store.get(plugin)`| Raw payload **with `_levels`**. `200 null` if the plugin is registered but has not yet published (scheduler cycle 0). `404` if the plugin is not registered. |
0 commit comments