Getting Started

Install

npm install point-sdk-capacitor
npx cap sync

Important: Only iOS devices are supported currently.

Setting Up Point SDK

Before any feature can be used, you must initialize the SDK providing your credentials. It is recommended to do it at the start of your application.

setupSDK() {
    PointSDK.setup({
        clientId: "clientID",
        clientSecret: "clientSecret",
        environment: PointEnvironment.Development,
        verbose: true,
    });
}

Using verbose: true will make the SDK print logs in the debug console about internal operations, filters, dates, errors, warnings and much more. This is helpful during development/integration phase, but we recommend turning it off before releasing your app into production.

Setting User's Access Token

This section assumes you already have a user token. Refer to Registering Users for more details.

Set the user access token. It is recommended to do it as soon as possible, right after having requested user permissions.

async setUserToken() {
    await PointSDK.setUserToken({ userToken: token });
}

The setUserToken function automatically triggers a Latest Data sync and also Historical Data sync if it's the first usage during that session. Refer to Point Health Kit for more information about uploading data.

Collecting and uploading samples

Use one or more of our integrations to collect and upload health samples and basic user data to Point Database.

  • Check HealthKit Integration to know how to support Apple Watch and Health app. This is only available in iPhone devices.

  • Check Fitbit Integration to know how to support Fitbit devices. This is available regardless of device.

Retrieving user data and generated metrics

Use the Point Health Service functions to retrieve user data and generated metrics such as recommendations, trends, workouts, health metrics and more.

Download our App

Download the app on App Store

Connect with Us

Terms & Conditions | Privacy Policy © 2022 Point® (Key Point Technologies, Inc.)