cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

API to get ALL things and their latest snapshot of timeseries data

former_member69765
Contributor
0 Kudos
175

The requirement is to show the location of ALL vehicles on a map (ofcourse based on some filter criteria)

Is there an API that give a list of things along with their latest snapshot of the time series data.

I know of the APIs that give a list of things, and API to get latest time series data...
But with these 2 APIs - we have to loop over all things and call the 2nd API one after the other... this would be very bad for performance if there are 100+ vehicles...

Accepted Solutions (0)

Answers (3)

Answers (3)

former_member69765
Contributor
0 Kudos

Hi marcus.behrens

I went thrgough both links ... read them twice... did not find what I am looking for...

The APIs that give data for multiple things have time as mandatory parameter 😞 😞

Note that we cannot provide time as a filter / parameter because we dont know what time to provide !
We dont know when the last data was recieved !

I checked the following APIs:

  1. Read Single Measurement -- This required Thing and Time as parameter
  2. Read Multiple Measurements -- This one can return data of multiple Things... but here the time filter is mandatory.. We cant provide time as filter because we dont know when the last data was recieved
marcus_behrens1
Product and Topic Expert
Product and Topic Expert
0 Kudos

Are you aware of this overview? https://help.sap.com/viewer/080fabc6cae6423fb45fca7752adb61e/1908b/en-US/08969c3d26ed414ea50f4d76a3b...

The analytical odata api can return the "LAST" values for multiple things. See this tutorial on how to use this api: https://developers.sap.com/tutorials/iotae-comp-analyticalodata.html

fvviviani
Participant
0 Kudos

Hello Varun,

As far as I know, there is no chance to get a Snapshot for all things, as you have to provide the ThingId as a filter, and you cannot get Snapshots starting from /Things. The situation is therefore as you described saying:

But with these 2 APIs - we have to loop over all things and call the 2nd API one after the other

BR,

Federico