get-update-state
Use the interface to obtain the current firmware information and update status with administrative rights.
HTTP Request
GET http://ip/mwapi?method=get-update-state
| Parameter | Description | 
| method | get-update-state | 
Response Body
Idle
{
 "status": 0,
 "state": "idle",
 "cur-ver": "1.1.72"
}
Updating
{
 "status": 0,
 "state": "updating",
 "cur-ver": "1.1.72",
 "update-to-ver": "1.1.72",
 "num-steps": 4,
 "step-id": 2,
 "step-name": "Erasing image",
 "step-percent": 28
}
Failed
{
 "status": 0,
 "state": "failed",
 "cur-ver": "1.1.72",
 "error-status": 16
}
| Name | Description | 
| status | 0 indicates that the request was accepted successfully. Refer to API Status Codes to find specific description for other values. | 
| state | Indicates the current update state, including idle, updating, completed, failed. | 
| cur-ver | Indicates the current firmware version. | 
| update-to-ver | Indicates the latest version. | 
| num-steps | Indicates the total number of steps for updating, only available in the updating state. | 
| step-id | Indicates the current step id, only available in the updating state. | 
| step-name | Indicates the current step name, only available in the updating state. | 
| step-percent | Indicates the current update process, only available in the updating state. | 
| error-status | Indicates the error code, only available in the failed state. |