Why might ngrok be needed for the OAuth flow? Because Garmin’s OAuth callback requires HTTPS. Other currently supported cloud providers work with HTTP, so localhost is fine.
Quick Start
Install ngrok
Download from ngrok.com or use a package manager:
Use the public URL
ngrok will display a public URL like:Use this HTTPS URL for:
- Garmin OAuth (requires HTTPS)
- Webhook endpoints
- Mobile SDK webhook (e.g. Apple Health sync endpoint)
Common Use Cases
OAuth Flow Testing
OAuth Flow Testing
Garmin (requires HTTPS):Garmin OAuth requires HTTPS, so you need ngrok:Polar & Suunto (HTTP works):These providers don’t require HTTPS, so you can test locally without ngrok:
- Start ngrok:
ngrok http 8000 - Copy the HTTPS URL (e.g.,
https://abc123.ngrok-free.app) - Use it as the
redirect_uriparameter:
Webhook Testing
Webhook Testing
For testing webhook endpoints (e.g., Garmin data push):
- Expose your backend:
ngrok http 8000 - Configure the webhook URL in your provider settings:
- Garmin: Use
https://abc123.ngrok-free.app/api/v1/garmin/webhooks/push - Other providers: Similar pattern
- Garmin: Use
Mobile SDK Integration
Mobile SDK Integration
When testing Apple Health SDK or mobile app integrations:
- Start ngrok:
ngrok http 8000 - Configure your mobile app to use the ngrok URL:
- Update API base URL to
https://abc123.ngrok-free.app - Same approach
- Update API base URL to
Tips
Related Guides
- Backend E2E Integration - Complete integration walkthrough
- Provider Setup - Configure OAuth credentials

