From 439273cce6f48e4bea88040245919798a113d9e3 Mon Sep 17 00:00:00 2001 From: Mike Degatano Date: Mon, 29 Aug 2022 14:30:19 -0400 Subject: [PATCH] Document new suggestions for issue api (#1444) --- docs/api/supervisor/endpoints.md | 31 ++++++++++++++++++++++++++++++- docs/api/supervisor/models.md | 5 +++-- 2 files changed, 33 insertions(+), 3 deletions(-) diff --git a/docs/api/supervisor/endpoints.md b/docs/api/supervisor/endpoints.md index d5db6949..ceb460a4 100644 --- a/docs/api/supervisor/endpoints.md +++ b/docs/api/supervisor/endpoints.md @@ -1969,7 +1969,8 @@ Move datadisk to a new location, **This will also reboot the device!** "uuid": "B9923620C9A11EBBDC3C403FC2CA371", "type": "clear_backups", "context": "system", - "reference": null + "reference": null, + "auto": false } ], "checks": [ @@ -1995,6 +1996,34 @@ Dismiss a suggested action + + +Get suggestions that would fix an issue if applied. + +**Returned data:** + +| key | type | description | +| ----------- | ---------- | -------------------------------------------------------------------------- | +| suggestions | list | A list of [Suggestion models](api/supervisor/models.md#suggestion) actions | + +**Example response:** + +```json +{ + "suggestions": [ + { + "uuid": "B9923620C9A11EBBDC3C403FC2CA371", + "type": "clear_backups", + "context": "system", + "reference": null, + "auto": false + } + ] +} +``` + + + Dismiss an issue diff --git a/docs/api/supervisor/models.md b/docs/api/supervisor/models.md index 9fa31a2f..06d72cf7 100644 --- a/docs/api/supervisor/models.md +++ b/docs/api/supervisor/models.md @@ -222,7 +222,7 @@ The `content` key of a backup object contains the following keys: | ----------| ----------- | --------------------------------------------------- | | uuid | str | A generated uuid as issue ID | | type | str | Type of the issue | -| context | str | In which context the issue occorse | +| context | str | In which context the issue occurs | | reference | str or null | Depend on the Context, a reference to another Model | ## Suggestion @@ -231,8 +231,9 @@ The `content` key of a backup object contains the following keys: | ----------| ----------- | --------------------------------------------------- | | uuid | str | A generated uuid as suggestion ID | | type | str | Type of the suggestion | -| context | str | In which context the suggestion occorse | +| context | str | In which context the suggestion occurs | | reference | str or null | Depend on the Context, a reference to another Model | +| auto | bool | True if the suggested fix will be auto-applied | ## Check