Namespaces

ovok.wearables

Configure wearable providers and connect, sync and disconnect a patient's accounts.

  • Stable unknown
  • Release candidate since 0.4.49-rc.4
  • Development since 0.4.49-dev.517+4645a0a

ovok.wearables has two halves. providers holds a project's provider settings and is for admins. connections is the patient app's side: connect a provider, sync its data and disconnect. Providers are oura, whoop, strava, withings, polar, suunto, garmin and ultrahuman.

Connect a provider

const { authorizationUrl } = await ovok.wearables.connections.authorize('oura');
  • authorize returns the provider's one-time consent page. Open authorizationUrl for the patient, who grants access there.
  • list shows the patient's current connections.

Sync data

const result = await ovok.wearables.connections.sync('oura');

console.log(result.created, result.syncedThrough);
  • It reports how many observations were created and the time the data was synced up to.

Disconnect

await ovok.wearables.connections.delete('oura');

Configure providers

const providers = await ovok.wearables.providers.list();

const oura = await ovok.wearables.providers.retrieve('oura');
  • create, patch and delete change a provider's settings for the project.
  • The calls go to v1/wearables/providers and v1/wearables/connections.

Reference

Last updated on

On this page