ioshealthkitwearables

Can data of third-party apps synced to Apple Health be retreived via HealthKit


I am researching the feasibility of an iOS app that can collect data from multiple brands of wearable devices. I am only interested in devices that have apps that are able to sync with Apple Health. Does Apple Health uses HealthKit store to store the data it synced from third-party apps so that I can access it from my iOS app?


Solution

  • Any third-party app can save data to Apple Health using the HealthKit APIs, but it's also possible for an app to ignore HealthKit entirely and keep their wearable device data in their own proprietary system. Apple doesn't automatically ingest all third-party health/wearable data into HealthKit.

    It's up to the third-party apps to save their data to HealthKit (and for the user to grant permission to these apps to save the data). Your own iOS app will be able to fetch any data that other apps do save to HealthKit (again, assuming the user grants your own app permission to read data). Each HealthKit sample contains a sourceRevision property that describes the app/device that generated the sample, and you can display that information to your user, filter your queries by that source, etc.