Skip to main content

Get device raw data

info

For historical reasons, raw data is referred to as "preprocessed data" in the API. We apologize for any confusion this may cause.

The raw data is provided in JSON format and typically looks like this in WS:

{
"gnss": {
"timestamp": [
XXXXXXX689597,
XXXXXXX689697,
XXXXXXX689797,
XXXXXXX689897,
XXXXXXX689997,
XXXXXXX690097,
XXXXXXX690197,
XXXXXXX690297,
XXXXXXX690397,
XXXXXXX690497
],
"longitude": [
XX.XXX2507,
XX.XXX2424,
XX.XXX2346,
XX.XXX2262,
XX.XXX2181,
XX.XXX2103,
XX.XXX2026,
XX.XXX1948,
XX.XXX1877,
XX.XXX181
],
"latitude": [
XX.XXX452,
XX.XXX4512,
XX.XXX451,
XX.XXX4511,
XX.XXX4516,
XX.XXX4526,
XX.XXX4539,
XX.XXX4557,
XX.XXX4578,
XX.XXX4602
],
"speed": [
6.068,
6.162,
5.688,
6.185,
5.943,
5.803,
5.782,
6.059,
5.707,
5.56
],
"altitude": [
51.537,
51.537,
51.537,
51.537,
51.537,
51.537,
51.537,
51.537,
51.537,
51.537
]
},
"ecg": {
"timestamp": XXXXXXX689597,
"hr": 159
},
"pwr": {
"timestamp": XXXXXXX689597,
"pwr_cadence": 0,
"pwr_instantpower": 0
},
"device": {
"timestamp": XXXXXXX689597,
"standstill": 0,
"Bat_lvl": 90
}
}

There may be additional data fields in the future, so ensure your backend implementation can handle new fields without breaking.

info

You will need to access the various HTTP API endpoints via the device_id path parameter.

Refer to this section for instructions on retrieving the device_id from the device's serial number.

Intense

WS endpoint

This is the preferred and simplest way to retrieve live data from the device to your server.

The WS endpoint is located at: wss://api.insiders.live/v1/ws/preprocessed-data/{device_id}/

The diagram below illustrates the initial message exchanges on a newly established WebSocket connection, where the client provides its access token to the server:

Authorization

info

The authentication message containing the access token must be sent by the client within the first 3 seconds; otherwise, the connection will be closed.

You will need an access token for the manager account that owns the device. The message format is as follows:

{
"token": "YourAccessToken",
}

HTTP endpoint

This is the same endpoint as for the Inspirit device, please check this section for details.

This endpoint is useful when you lose the WS connection from your server and need to pull data back.

caution

You should not however:

  • poll this endpoint in order to get live data: use WS endpoint instead
  • use our API as your database: you should set up your own database to persist device data

Inspirit

.asi bulk upload

The data is stored in a .asi file, which needs to be extracted from the Inspirit device.

You may find one of these guides helpful for downloading the .asi file:

Once you have the .asi file, use the bulk upload endpoint to upload it and temporarily store the raw data on our server.

HTTP endpoint

You can get raw data between two timestamps using the get preprocessed data endpoint.

If you don’t know the exact time of the session, you can use this endpoint to find out when data is available.

caution

Device raw data is temporarily stored up to 1 month and it will be reduced to 1 week in the future.

We do not provide Database as a Service and you should persist data in your own database. Please check this recommendation section.