Tracertrak | How do I integrate Tracertrak data into another system? (NGC)

Access Last Known Location data via the Tracertrak Last Known Location API.

The Last Known Locations API allows authorised users to access a secure API URL which defaults to providing the last known location for device groups accessible by that authorised user. It is possible to customise this URL to only include data for specific device groups that the authorised user has access to. Only users who belong to a role that has the right to Search Historical Locations will be able to access the API URL.

The API URL is located under the My Settings section beneath the Avatar in the top right-hand corner of any page.

The URL is made up of the following parts:

  1. API Source & Data Format The address and format used for the Last Known Location API. This will be the same for every API URL. eg. https://console.tracertrak.com/spview/locations/v1/GeoJSON?
  2. Group Specification Specifies the device groups to restrict the API URL call to. Multiple groups can be listed, such as group=red&group=blue. Specifying a group to be included will include all devices currently in the group and also any devices added to that group in the future. Not using any Group specification will default to all devices visible to the user being included. Individual devices can be referenced by adding them to a new group for the purpose of exporting them through the API. eg. group=not%20grouped
  3. Authorisation Key The unique API Authentication Key associated with that user account and used to validate the API request. eg. auth=K1cpEiNXhYUcv2w7RuVqPuYv1N

If the permission to view location history is removed from the role assigned to the authenticating user, any API calls created under that users account WILL continue to work.

Removal of the user account voids the use of that users Authentication Key and will cause any existing API URL’s created with that key to fail.

If group permissions are removed from a users account, any API calls for that user that includes those removed groups WILLNOT work.

GeoJSON Data Format

The Last Known Location API provides GeoJSON formatted data.

An example of the GeoJSON format is shown below:

{"type":"FeatureCollection","features":[ {"type":"Feature","geometry":{"coordinates":["-32.576475","51.616004"],"type":"Point"},"properties": {"deviceID":"0-8394103","msgTimestamp":"2019-02-07T05:36:04Z","payload":"somepayload","name":"three","cause":"TRACK"," type":"standard"}},{"type":"Feature","geometry":{"coordinates":["-12.678221","-33.760289"],"type":"Point"},"properties": {"deviceID":"0-419585","device_input_2_state":"0","cause":"REPLACEBATTERY","type":"standard","msgTimestamp":"2018-07- 26T07:30:08Z","payload":"generated payload","name":"Dubbo","device_input_1_state":"0","inMotion":"0","networkType":"SAT","GPSFix":"0"}}]}

The data included in the GeoJSON message includes:

The Last Known Location API provides GeoJSON formatted data.

An example of the GeoJSON format is shown below:

{"type":"FeatureCollection","features":[ {"type":"Feature","geometry":{"coordinates":["-32.576475","51.616004"],"type":"Point"},"properties": {"deviceID":"0-8394103","msgTimestamp":"2019-02-07T05:36:04Z","payload":"somepayload","name":"three","cause":"TRACK"," type":"standard"}},{"type":"Feature","geometry":{"coordinates":["-12.678221","-33.760289"],"type":"Point"},"properties": {"deviceID":"0-419585","device_input_2_state":"0","cause":"REPLACEBATTERY","type":"standard","msgTimestamp":"2018-07- 26T07:30:08Z","payload":"generated payload","name":"Dubbo","device_input_1_state":"0","inMotion":"0","networkType":"SAT","GPSFix":"0"}}]}

  • Date/Time (ISO 8601)
  • Longitude, Latitude (WGS84)
  • Device ID (as per Tracertrak)
  • Device Specific Broadcast Content (any additional data associated with that broadcast event such as digital inputs, temperature, battery level etc.)
Categories: History & Reports