To fetch the data for specific time frames, you should use the time series api and specify the startTS and the endTS. In the case of the first activation and NOW date, specify the startTS and endTS accordingly.
Bear in mind, that the Device might have some gaps in between, where it was deactivated. It is advised, that you conduct one request per activation (with startTs and endTS). Additionally you should be aware that startTs and endTs is set in milliseconds (1/1,000 second), for example: 1657786694000.
API Documentation
- API Documentation
- What is the maximum number of data points I can fetch per call?
- Cital Insights API Entity Relationship and UML Diagramms
- How can I fetch the entity view (device) data starting from the first activation date until NOW date?
- Are entity views the entity used to attach data to the devices (sensors)?