Human Connect Overview
The easiest way to connect your users' health data with your application or service.
Human Connect is an embeddable interface for applications to allow users to share their health data with your apps and services. After a user has successfully granted you access to their health data using Human Connect, you'll be able to query their data directly from Human API.
Each user from your app, additionally, will have a unique Human API user record, which will automatically synchronize all of the user's health data from their disparate data sources.
Authentication Overview
The Human Connect authentication flow consists of 6 steps:
-
Launch the Connect popup with two configuration parameters:
clientId
andclientUserId
. -
Once a user has connected their data sources and presses the "Done" button, you will receive a
sessionTokenObject
. -
Post this
sessionTokenObject
to your server. -
On your server, add your unique
clientSecret
to thesessionTokenObject
and POST it to Human API's servers. -
Human API will return:
humanId
,accessToken
, andpublicToken
. Save this data in your system with the appropriate user model. -
Update your app status. You can now start using Human API for querying data.
Key value descriptions
Key | Use |
---|---|
humanId * | User ID within Human API. |
accessToken * | Used to pull all data for a user. |
publicToken * | Used to open the Human Connect popup for existing users. |
clientId | Unique ID of your Human API app. Found on the app settings page of the Developer Portal. |
clientSecret | Unique client secret of your Human API app. Found on the app settings page of the Developer Portal. |
sessionTokenObject | Consists of a humanId , clientId , and sessionToken . |
Parameters with * should be stored securely with your local user model.
Modes
Finally, Connect has two modes "Create" and "Edit". Create mode is launched as described above for all user's on their first launch. Once a user connects a source you'll get a set of tokens back (step 5), one of which is the publicToken
. This token will have to be supplied to Connect on launch every subsequent time that user launches Connect to ensure proper security.
That's it! It's the same standard process regardless of the platform you launch Connect from.
Next Step: Launch Human Connect From Your Application
Now that you've got the basics down, pick your platform below for specifics on how to add this flow to your application:
Updated over 5 years ago