I installed ThingsBoard (TB) 3.3.2 at Rasperry Pi, added a device and sent some temperature values to it. Those values can be seen at my TB dashboard.
The problem is, when I try to request those data by TB telemetry API, I can only received one value (i.e. 'data point') - which is the most recent one.
For instance: when I send this API call (I have hidden my IPv4 address)...
curl -v -X GET "http://x.x.x.x:8080/api/plugins/telemetry/DEVICE/$ENTITYID/values/timeseries?keys=temperature&startTs=1639458000&interval=60000&limit=100&agg=AVG"
--header "Content-Type:application/json"
--header "X-Authorization:Bearer $JWT_TOKEN"
...I just receive only this single data point - and not all of the existing ones:
{"temperature":[{"ts":1639670432016,"value":"25.8"}]}
When I send an other temperature value to the device of TB, let's say 26.3, and repeat the curl command above, then I get the new value but not the other ones, even not the one I have seen before (25.8):
{"temperature":[{"ts":1639673228689,"value":"26.3"}]}
I tried it with some different URL-line params, e.g. with and without the tags 'agg', 'limit', and 'startTs'. But it didn't result in providing more than only one data point.
Does anybody know how to get all historical data points within the range as definde by startTs(/endTs) and not only the most recent one?
Any help is highly appreciated! Thanks!
ThingsBoard dashboard showing my historical data points
BTW: If I use endTs (e.g.: ...keys=temperature&startTs=1639458000&endTs=1640037600&interval=60000...) TB simply returns: "{}". But that seems to be a different issue?