🗄️REST server

Fetch data points directly from Kligo's embedded REST server.

In Kligo future releases, this REST Server will expose datapoint as FHIR Observation.

Get Data

GET http://localhost:63336/v0/data

This method returns every data points stored in Kligo local's database.

Path Parameters

Name
Type
Description

offset

number

The API is now paginated and shows 50 results per request. Use the offset parameter to get the piece of cake you desire, for instance if you want to get results starting by the 50th you would GET http://localhost:63336 /v0/data?offset=50

[{
  "id": "123abc",
  "timestamp": 1483228800000,
  "deviceId": "5868387abcdef123456",
  "deviceType": "blood pressure monitor",
  "type": "heart_rate"
  "unit": "beats/min",
  "value": 75,
  "archived": false
},
{
  "id": "456def",
  "timestamp": 1483228800001,
  "deviceId": "5868387123456abcdef",
  "deviceType": "weight scale",
  "type": "body_weight"
  "unit": "kg",
  "value": 70,
  "archived": false
}]
fetch('https://api.medeo.io/v0/data/', {
// you can also fetch in prod by hitting http://localhost:63336/v0/data/
  method: 'GET',
  headers: {
    'Accept': 'application/json',
    'Content-Type': 'application/json; charset=utf-8',
    'x-api-key': '<YOUR_KEY>'
  }
}).then( response => {
//do what you want
});

Last updated

Was this helpful?