getDevicePowerInfo: Get device lock power information
getDevicePowerInfo: Get device lock power information
Function details
Obtain the power information of the door lock device.
Request address
https://openapi-[DataCenter].easy4ip.com/openapi/getDevicePowerInfo
Minimum permissions required for sub-account token request
"Permission":"Config" "Resource":"dev:serial number"
Incoming parameter description
| Parameter name | Parameter type | Required or not | Default value | Legal value | Parameter description |
|---|---|---|---|---|---|
| token | String | Yes | Administrator or sub-account accessToken | ||
| deviceId | String | Yes | Door lock device serial number |
Sample input
{
"system":{
"ver":"1.0",
"appId":"lcdxxxxxxxxx",
"sign":"85384489874412a2e9aa7ac3a8b08309",
"time":1603350639,
"nonce":"350f4c7a-a352-46cf-ae03-f4f526f5d99f"
},
"id":"b8f45dbb-79ad-4a7e-8b24-7eb618c5191f",
"params":{
"token":"At_00000ad9e6e87f0142eb92e207aec46a",
"deviceId":"TESTQWERXXXX"
}
}
Return data field description
| Field name | Field type | Field description | |
|---|---|---|---|
| electricitys | alkElec | String | Percentage of alkaline electricity, value range is 0~100 |
| litElec | String | Lithium battery power percentage, value range is 0~100 | |
| electric | String | Battery percentage, the device lock battery has two parts, so this field returns 0 by default | |
| type | String | Power supply type, battery: battery; adapter: adapter; batteryAdapter: battery + adapter | |
Sample output
{
"id":"b8f45dbb-79ad-4a7e-8b24-7eb618c5191f",
"result":{
"code":"0",
"msg":"The operation was successful",
"data": {
"electricitys":[
{
"alkElec": "90",
"litElec": "90",
"electric": "0",
"type": "battery"
}
]
}
}
}
