Document new suggestions for issue api (#1444)

This commit is contained in:
Mike Degatano 2022-08-29 14:30:19 -04:00 committed by GitHub
parent 39ac658f8b
commit 439273cce6
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 33 additions and 3 deletions

View File

@ -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
</ApiEndpoint>
<ApiEndpoint path="/resolution/issue/<uuid>/suggestions" method="get">
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
}
]
}
```
</ApiEndpoint>
<ApiEndpoint path="/resolution/issue/<uuid>" method="delete">
Dismiss an issue

View File

@ -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