Consuming data via the API
Most users of the Ardexa platform want to analyse the data they collect using their own internal tools. To facilitate this, the Ardexa Hub offers a search function which is an easy way to poll for new events. However, until recently (before August 2024), API users were required to keep track of every device's online status so that they could backfill events when the device eventually came back online hours, days or even weeks later.
The latest version of the Ardexa Hub (August 2024) now offers a significantly more convenient way to track all events as they arrive in the cloud, regardless of how long a node has been offline, via two new fields available in all tables:
store_time
: The time a record was written to the Hub's data store
msg_id
(message ID): a per-device event counter
By using these fields in combination, it is now easier than ever to monitor the API for all new events and consume a complete, de-duplicated data stream!
PLEASE NOTE: Events are added to the data store in batches, meaning there might be a delay of up to 40 seconds before data is available via the Search API.
Below is the pseudo code describing the recommended polling procedure:
Last updated