7 years ago
API - Device Data Aggregation
On the Get Device Data endpoint we'd like to be able to aggregate the data that comes back in some sort of time window. There is currently the ability to pass the period parameter in order to specify how far back you'd like to pull data from. But we would like to have two extra parameters. One to specify the type of aggregation(SUM, AVG, MIN) and another to specify the time window that we'd like that aggregation to roll up on(1min, 60min). So if we were to request data with a period of 2(hours), an aggregation of AVG, and roll_up_window of 1(min) then we'd expect to get back 120 rows, each representing the average of the values for each minute.