GetPointGroupsSplit Documentation
GetPointGroupsSplit
Draft documentation version
Documentation is partial and not validated !
Description
Method applyed by operation group by period.
Remark
Example: you have one year of datas with a 10 minutes sampling, these represent 52560 Point (6 * 24 * 365).
Of course, you can not (and do not need if you want to render in a chart per exemple) request all these points.
Instead, you can pass split by 1000: operation return 1000 PointGroup and each group is based on about 52 Point (52560 / 1000).
WIT-1View Grapher is using this operation to display one PointGroup per pixel (number of displayed pixels is calculed on client side).
You can NOT request more than 2000 PointGroup
Version | V1 |
---|---|
Require User context | |
Authorization | |
Errors |
Request
Route
Parameters
Parameter | Required | Sample | Description |
---|---|---|---|
DataID | 34 | ID of Data | |
Split | 1000 | Number of returned PointGroup: time between From and To parameters is splited with this parameter | |
WAC | WAC123456789012 | Code of BusinessAccount | |
From | 2014-09-15T13:59:20.0000000Z | From Date | |
To | 2014-09-20T13:59:20.0000000Z | To Date |
Remarks
- To override Content-type in your clients HTTP Accept Header, append the
.json
suffix or?format=json
- To embed the response in a jsonp callback, append
?callback=myCallback
Post Data sample
From=2014-09-15T13:59:20.0000000Z&To=2014-09-20T13:59:20.0000000Z&
cURL command sample
curl -k -H "Authorization: Bearer [YOUR_ACCESS_TOKEN]" -H "Content-Type:application/json" https://api.wit-datacenter.com/WAC123456789012/PointGroup/Split/34?From=2014-09-15T13%3a59%3a20.0000000Z&To=2014-09-20T13%3a59%3a20.0000000Z
Response
Returned Entity
Array of PointGroupJSON Sample
HTTP/1.1 200 OK Content-Type: application/json Content-Length: length [{"wType":"PointGroup","T":"0001-01-01T00:00:00.0000000Z","L":0,"U":0,"I":0,"O":0,"A":0,"P":0,"D":0}]