Connecting Wearable Devices
Connect Fitbit or Apple HealthKit so InsideTracker can use wearable and physiologic data in personalized health insights.
Connecting Wearable Devices
Wearable connections add activity, sleep, heart rate, and related physiologic context to a User's InsideTracker experience.
InsideTracker supports two wearable integration paths:
- Fitbit registration, where your application registers the User's Fitbit connection and InsideTracker handles data ingest after registration.
- Apple HealthKit submission, where your mobile application collects permitted HealthKit data from the User's device and submits it to InsideTracker.
Register the User's Fitbit connection. InsideTracker handles ingest after registration.
Connect an Apple HealthKit profile, collect permitted on-device data, and submit raw records.
Where This Fits
Use this page when a User with a linked InsideTracker customer record is ready to share wearable or physiologic data with InsideTracker.
This page covers connection and ingestion. To retrieve aggregated wearable-derived values later, use the physio data retrieval endpoints for physio markers, activity, and sleep.
Before You Begin
| Requirement | Why you need it |
|---|---|
| Customer-level access token | Required for User-specific wearable connection and Apple HealthKit submission endpoints. |
| Linked InsideTracker customer record | Required before wearable data can be associated with the correct User. |
| Provider-specific User consent | Required before connecting a wearable provider or collecting on-device HealthKit data. |
| Fitbit registration flow | Required when the User connects Fitbit. |
| Mobile app HealthKit permissions | Required when your application submits Apple HealthKit data from the User's device. |
| Disconnect experience | Required so Users can revoke wearable data access. |
User-specific wearable endpoints use customer-level authentication:
Authorization: Bearer {customer_token}Supported Provider Paths
| Provider path | Your application does | InsideTracker does |
|---|---|---|
| Fitbit | Registers the User's Fitbit connection through the Fitbit registration flow configured for your integration. | Handles Fitbit ingest after registration. |
| Apple HealthKit | Requests HealthKit permissions on the User's device, connects an Apple HealthKit provider profile, and submits raw HealthKit records. | Accepts submitted records and aggregates them into physio data that can be queried later. |
Choose The Connection Flow
Use the provider path to decide what your application needs to do.
| If the User connects... | Use this flow |
|---|---|
| Fitbit | Register the Fitbit connection for the User. Do not submit raw Fitbit data through the Apple HealthKit endpoints. |
| Apple HealthKit | Create an APPLE_HK provider profile, collect permitted HealthKit data on device, and submit raw records with that profile ID. |
Keep provider-specific UI and copy separate. Fitbit and Apple HealthKit have different implementation responsibilities, even when the downstream data supports similar personalization use cases.
Fitbit Registration
Fitbit is a released wearable connection path. In the current model, your application registers the User's Fitbit connection and InsideTracker handles data ingest after registration.
At a workflow level:
- Start the Fitbit registration flow configured for your integration.
- Complete the User's Fitbit connection.
- Allow time for InsideTracker to ingest and process wearable data.
- Retrieve downstream physio marker, activity, or sleep data when available.
- Provide a User-facing way to disconnect the Fitbit connection.
Fitbit data availability depends on the User's connected account, provider permissions, sync timing, and the types of data available from Fitbit for that User.
Apple HealthKit Submission
Apple HealthKit data is stored on the User's device. Your mobile application is responsible for requesting HealthKit permissions, collecting permitted records locally, and submitting supported records to InsideTracker.
Create an Apple HealthKit provider profile:
POST /wearables/customer/v1/provider/direct/APPLE_HK
Authorization: Bearer {customer_token}The response includes the provider profile identifier used for subsequent Apple HealthKit data submissions:
{
"providerProfileId": "550e8400-e29b-41d4-a716-446655440000"
}Submit Apple HealthKit records for the connected profile:
POST /apple/v1/healthKitData
Content-Type: application/json
Authorization: Bearer {customer_token}The submission request includes:
| Field | Use |
|---|---|
profiles | Connected Apple HealthKit provider profile IDs associated with the submitted data. |
data | HealthKit sample records collected from the User's device. |
activitySummaries | Apple activity summary records, when available and permitted. |
steps | Step count records, when available and permitted. |
Requests should stay under 128 kB. Larger payloads may be rejected.
InsideTracker ingests accepted Apple HealthKit records and aggregates them into physio data that can later be queried through the physio data APIs.
Apple HealthKit Status And Deletion
Use the Apple HealthKit status endpoint to check whether a connected profile is still active:
GET /apple/v1/healthKitData/profile/{profileId}/status
Authorization: Bearer {customer_token}A failed status means the connection is no longer active. Data for that profile is no longer accepted.
If your application needs to delete submitted Apple HealthKit records, use:
DELETE /apple/v1/healthKitData
Content-Type: application/json
Authorization: Bearer {customer_token}Deletion requests identify the connected profiles and the submitted record IDs to remove.
Connected Providers
Use the connected providers endpoint to retrieve the User's wearable provider state:
GET /wearables/customer/v1/provider
Authorization: Bearer {customer_token}The response can include:
| Field | Use |
|---|---|
tag | Provider tag, such as APPLE_HK. |
connectionDateTime | When the provider was connected. |
latestSyncDateTime | The latest known sync time for the provider, when available. |
Use connection and sync timestamps to help Users understand whether wearable-derived data may still be pending.
Disconnect A Provider
Use the provider disconnect endpoint for provider paths supported by the public API:
DELETE /wearables/customer/v1/provider/{providerTag}
Authorization: Bearer {customer_token}For Apple HealthKit:
DELETE /wearables/customer/v1/provider/APPLE_HK
Authorization: Bearer {customer_token}After disconnecting a provider, design your application to stop collecting or submitting data for that connection.
Best Practices
Implementation checklist
- You have a customer-level token for the User's linked InsideTracker customer record.
- You present only provider paths supported for your integration.
- You keep Fitbit registration separate from Apple HealthKit raw data submission.
- You request Apple HealthKit permissions clearly before collecting on-device data.
- You store the Apple HealthKit
providerProfileIdreturned by the connect endpoint. - You keep Apple HealthKit submissions under the documented payload size limit.
- You show connection and latest sync state when it helps explain missing or delayed data.
- You provide a clear disconnect action for supported provider paths.
Related API Reference
| Area | Endpoint |
|---|---|
| Apple HealthKit provider connection | POST /wearables/customer/v1/provider/direct/APPLE_HK |
| Connected providers | GET /wearables/customer/v1/provider |
| Disconnect provider | DELETE /wearables/customer/v1/provider/{providerTag} |
| Submit Apple HealthKit data | POST /apple/v1/healthKitData |
| Delete Apple HealthKit data | DELETE /apple/v1/healthKitData |
| Apple HealthKit connection status | GET /apple/v1/healthKitData/profile/{profileId}/status |
| Retrieve physio marker data | GET /wearables/customer/v1/physio-markers |
| Retrieve activity data | GET /wearables/customer/v1/activities |
| Retrieve sleep data | GET /wearables/customer/v1/sleeps |
Updated 27 days ago