Last Updated on : 2024-08-07 09:18:44download
Query the statistical trend data of various metrics of the specified device within a certain time range.
POST: /v1.0/m/energy/statistics/device/datadate
Description of body
Parameter name | Type | IN | Required | Description |
---|---|---|---|---|
dev_id | String | body | true | The device ID. |
indicator_code | String | body | true | The code of the specified metric. |
date_type | String | body | true | The statistical granularity. Valid values:
|
begin_date | String | body | true | The start time. |
end_date | String | body | true | The end time. |
aggregation_type | String | body | false | The aggregation type. Valid values: SUM , AVG , MAX , and MIN . |
options | String | body | false | The extension parameter. |
Parameter name | Type | Description |
---|---|---|
total | Float | The total number of returned entries. |
unit | String | The unit. |
indicator | String | The code of the specified metric. |
list | List | The time series data. |
Description of list
Parameter name | Type | Description |
---|---|---|
value | Float | The statistical value. |
date | String | The time. |
POST: /v1.0/m/energy/statistics/device/datadate?devId=vdevo168622064605772&indicatorCode=ele_usage&dateType=hour&beginDate=2021092315&endDate=2021092318
{
"result": {
"indicator": "ele_usage",
"list": [
{
"date": "202301",
"value": 0
},
{
"date": "202302",
"value": 0
},
{
"date": "202303",
"value": 0
},
{
"date": "202304",
"value": 0
},
{
"date": "202305",
"value": 0
},
{
"date": "202306",
"value": 3
}
],
"total": 3,
"unit": "kWh"
},
"success": true
}
For more information, see error code.
Is this page helpful?
YesFeedbackIs this page helpful?
YesFeedback