Last Updated on : 2023-06-21 07:13:04download
Query energy statistics data under assets or under custom dimensions within a specified time range, including the usage, generation, or dump statistics with respect to water, electricity, and natural gas.
GET: /v1.0/iot-03/energy/{energy_type}/statistics
Parameter name | Type | IN | Required | Description |
---|---|---|---|---|
energy_type | String | uri | true | The energy type. Set the value to electricity . |
energy_action | String | query | true | The energy behavior. Set the value to consume , representing energy consumption. |
dimension_code | String | query | true | The code of a specified dimension. Valid value: asset or other custom dimension. |
node_ids | String | query | true | The IDs of the specified dimension nodes. Maximum value: 10 . |
statistics_type | String | query | true | The statistical type. Valid values:
|
start_time | String | query | true | The start time. |
end_time | String | query | true | The end time. |
Parameter name | Type | Description |
---|---|---|
result | List | The returned result. |
Description of result
Parameter name | Type | Description |
---|---|---|
node_id | String | The ID of a specified dimension node. |
items | List |
The time trend of the energy data. |
Description of items
Parameter name | Type | Description |
---|---|---|
time | String | The time. |
value | Float | The energy data. |
GET: /v1.0/iot-03/energy/electricity/statistics?energy_action=consume&dimension_code=asset&node_ids=138803317715****&statistics_type=hour&start_time=2021080422&end_time=2021080423
{
"result": [
{
"items": [
{
"time": "2021080400",
"value": 10
},
{
"time": "2021080401",
"value": 20
}
],
"node_id": "123432"
},
{
"items": [
{
"time": "2021080400",
"value": 10
},
{
"time": "2021080401",
"value": 20
}
],
"node_id": "2423232"
}
],
"t": 1624525873263,
"success": true
}
For more information, see error code.
Is this page helpful?
YesFeedbackIs this page helpful?
YesFeedback