rest api - humanapi_description
Post on 06-Jan-2016
89 Views
Preview:
DESCRIPTION
TRANSCRIPT
7/17/2019 REST API - HumanAPI_Description
http://slidepdf.com/reader/full/rest-api-humanapidescription 1/2
A More Detailed Explanation REST APIs using humanAPI as the Example
To gain a high level understanding of this approach we’ll use a simple example of obtaining
blood pressure readings for a particular patient from humanAPI, a site that aggregates patient
generated data and makes it available using REST. There are three available REST GET
commands as shown here:
To support privacy humanAPI provides a service called Human Connect to authenticate users'
and allow them to authorize sharing from their health data from all available sources. This
ultimately r esults in an “access token” that can be used to obtain the desired data, as shown
here to obtain a list of blood pressure readings for a user:
https://api.humanapi.co /v1/human/blood_pressure/readings?access_token=a99f3b377fb7b2f
b0cb362ce7affd7f2d51e864a
Even a non-technical reader should be able to figure out that this command is for a patient’s
glucose pressure readings. Each entry in the list of results would look something like this:
{"id":"53d2b2ced651ab7719003aa3","userId":"52e20cb2fff56aac62000001","timestamp":"2014-
07-
25T21:22:30.000Z","systolic":122,"diastolic":76,"unit":"mmHg","heartRate":81 ,"source":"ih
ealth","createdAt":"2014-07-25T19:41:02.637Z","updatedAt":"2014-07-25T19:41:02.637Z"}
Again, even a non-technical reader should be able to determine that this reading is 122/76 with
a pulse of 81.
Here’s the format for the entire string of results shown above:
7/17/2019 REST API - HumanAPI_Description
http://slidepdf.com/reader/full/rest-api-humanapidescription 2/2
Property Type Description
id String The id of the blood glucose reading
userId String The global Id of the user
timestamp Date The original date and time of the measurement
source String The source service for the measurement, where it was created
value Number The value of the measurement in the unit specified
unit String The unit of the measurement value
createdAt Date The time the measurement was created on the Human API server
updatedAt Date The time the measurement was updated on the Human API server
Note that the results identify the source of the data. In this case it is iHealth, an iPhone based
blood pressure device shown here.
top related