9 Apple Health Integration
CodeWithCJ edited this page 2026-03-14 12:32:43 -04:00
This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

Mobile App requires HTTPS. Though support for self-signed certificate has been added, not tested for every release.

Option1: Testflight

Option2

Download from App store. Due to apple approval process, it might have older version. If you require lates features, use the Tesflight version.

https://apps.apple.com/app/sparkyfitness/id6757314392

Option3: 📲 iPhone Shortcut Method - may not work with new releases

Use the link below to create the iOS Shortcut:

Create Shortcut


🔧 Configure Server URL and API Key

  1. Update the Shortcut with your server URL and API key. You can generate the API key from the apps Settings menu.
URL: https://your-domain.com/health-data
API Key: MyAPIKey123123123123123123123123123
  1. To generate an API key:
    • Go to the Settings screen.
    • Make sure you have configured an encryption key and passed it as an environment variable.
    • Refer to the provided .env.example file for guidance.

⚠️ You must set the encryption key before generating the API key.


🔐 Authorization Format

Use the following format in your request header:

Bearer Your_APIKey

Example:

Bearer MyAPIKey123123123123123123123123123

⚠️ Make sure there is a space between Bearer and the API key. Without it, the request will fail.

If you are using smartwatch or multiple device linked to your account, you will need to choose correct device using below steps. Otherwise Apple Shortcut could send duplicate step count from all your devices.

  • Click on "Add Filter"
  • Click on "Value" and choose "Source"
  • Select your Apple Device you want to sync with SparkyFitness. In below example, "Sparky Phone" is my iPhone
image