Overview
Connect WHOOP data to Sahha via the WHOOP API. You register an app with WHOOP, add it to Sahha as an integration, configure webhooks, then connect end users. The connection flow itself is shared across providers — see Integrations for the concepts and Connect a user for the full round-trip.
| Status | GA self sign-up |
| API slug | whoop |
| Device | Band |
| Connection | Cloud OAuth |
| Live sync | Pull (webhooks), plus scheduled polls |
| Backfill on connect | 30 days |
Before you start
Examples use the sandbox environment. Replace sandbox-api.sahha.ai with api.sahha.ai for production — see API Environments.
WHOOP uses self sign-up — you can create an app and start testing it without an approval step. WHOOP limits how many members can connect to each app, and you can request a higher limit (see Create the app and copy your credentials).
One app per environment
Create a separate WHOOP app for each Sahha environment you use: one for sandbox, another for production. To move an app you’ve tested in sandbox to production instead, see Sandbox and production.
Create a WHOOP account
The WHOOP Developer Dashboard uses the same credentials as your WHOOP account. If you don’t already have one, create it first.
Create your WHOOP account
- Download the WHOOP app — App Store or Google Play
- Open the app and tap Sign up
- Register with your email address and create a password
- Verify your email address to activate the account
You don't need a WHOOP device
The app’s onboarding is designed around setting up a physical WHOOP, but you don’t need one to register a developer app — your account is created at sign-up. Work through the onboarding screens, and when the app asks you to pair a device, skip that step or simply close the app. Your account stays active, and you can sign in to the developer dashboard with it.
With your WHOOP account created, you can sign in to the developer dashboard in the next step.
1. Register your WHOOP app
This gives Sahha the OAuth credentials it uses to request data on your users’ behalf.
Open the developer dashboard
Sign in to the WHOOP Developer Dashboard with your WHOOP account. The Your apps page lists any apps you’ve already created. Click Create New App to start a new one.
Fill in the application details
On the New App form, complete the fields. The name and logo are shown to your end users during the OAuth consent flow, so use values that represent your product.
| Field | What to enter |
|---|---|
| Name | The app name shown to users in the OAuth flow. |
| Logo | A .jpg or .png displayed at a 1:1 (square) ratio in the OAuth flow. |
| Contacts | One or more contact emails. WHOOP sends administrative communications about the app to these addresses — use Add for more than one. |
| Privacy Policy | Link to your privacy policy. Users are shown this link in the OAuth flow. |
Add the Sahha redirect URL
Under Redirect URLs, add the Sahha OAuth callback URL exactly as shown — WHOOP fails the OAuth flow if it doesn’t match. Use Add if you need more than one entry.
https://sandbox-api.sahha.ai/api/v1/integration/oauth/whoop/callback Select scopes
Under Scopes, tick the data types you want Sahha to ingest:
| Scope | Grants access to |
|---|---|
read:recovery | Recovery information, including score, heart rate variability, and resting heart rate. |
read:cycles | Cycles information, including day strain and average heart rate during a cycle. |
read:sleep | Sleep information, such as duration and start and end time. |
read:workout | Workout information, including activity type and accumulated strain. |
read:profile | Profile information. |
read:body_measurement | Body measurements, such as height, weight, and max heart rate. |
The offline scope is automatic
Sahha also requests the offline scope when a user connects, which returns a refresh token so data keeps syncing without the user re-authorizing. There’s no checkbox for this in the dashboard.
Add the webhook URL
Under Webhooks, add your Sahha integration’s webhook URL so WHOOP notifies Sahha when a sleep, a recovery or a workout is ready, and set the model version to V2. The Sahha Dashboard shows the URL before you create the integration: in the Add integration form, select WHOOP and copy the Webhook URL under Create your WHOOP app. Each webhook URL must start with https.
Create the app and copy your credentials
Click Create App to save your application. To view its credentials, open the app from the list under Your apps — its detail page shows your Client ID and Client Secret under Credentials, with the eye icon to reveal the secret. Copy both for the next step.
WHOOP sets your app's limits
Each WHOOP app has a member limit and rate limits, set by WHOOP. Sahha’s requests for your users go through your app and count toward its rate limits: when it hits one, Sahha waits for the limit to reset, so data arrives late. To raise either limit, request an increase from WHOOP on your app in the WHOOP Developer Dashboard. WHOOP’s App Approval and Rate Limiting docs give the current limits and how to ask.
2. Create the integration in Sahha
- Go to the Sahha Dashboard.
- Navigate to Direct integrations → Integrations in the sidebar.
- Click Add integration and select WHOOP as the provider.
- Under Add its details to Sahha, paste your WHOOP Client ID and Client secret.
- In Scopes, select the same scopes you enabled on your WHOOP app in step 1 — these are what Sahha requests when a user connects.
- Under Your app’s redirect URLs, add one or more URLs in your own app that Sahha may send users back to after they connect. The first is the default.
- Click Add integration.
Match your scopes
By default all provider-supported scopes are selected — not just the ones enabled on your app. Deselect any scopes your WHOOP app isn’t approved for so Sahha only requests scopes your app can actually access.
About redirect URLs
When you start the OAuth flow you may optionally pass a redirectUrl — it must match one of your redirect URLs exactly. If omitted, Sahha uses the default.
The integration’s page in the dashboard shows its Webhook URL after you save, too.
3. Configure WHOOP webhooks
WHOOP sends Sahha a webhook when a sleep, a recovery or a workout is ready, and Sahha fetches it from the WHOOP API in response. This step is required: without the webhook, Sahha gets a user’s sleeps, recoveries and workouts only from the 30-day backfill when they connect. Cycles and body measurements have no WHOOP webhook, so Sahha polls them, and they arrive either way (see Sync and history).
Sahha’s webhook URL must be on your application in the WHOOP Developer Dashboard — it isn’t configured automatically. If you added it in step 1, check it here; if not, add it now:
- In the WHOOP Developer Dashboard, open your application.
- Click Edit application and paste the webhook URL from your Sahha integration into the webhookUrl field. Make sure the model version is set to V2.
- Ensure the application’s scopes match the scopes you selected in the Sahha Dashboard (step 2).
- Save.
4. Connect a user
Start the OAuth flow with the user’s profile token. WHOOP’s slug is whoop:
curl -X GET "https://sandbox-api.sahha.ai/api/v1/integration/profile/oauth/whoop/authorize?redirectUrl=https://yourapp.com/integrations/callback" \
-H "Authorization: profile {your-profile-token}" {
"authorizationUrl": "https://api.prod.whoop.com/oauth/oauth2/auth?..."
} Redirect the user to authorizationUrl to complete authorization. For the full round-trip and how to handle the redirect back to your app, see Connect a user.
What data you get
Every WHOOP log has the source whoop and the deviceType strap. WHOOP scores cycles, sleeps, workouts and recoveries after the fact, and Sahha sends each one once WHOOP has scored it.
Cycles and workouts
A cycle is WHOOP’s day: the span from one sleep to the next.
| WHOOP data | Log type | Data type | Unit |
|---|---|---|---|
| Steps in a cycle | activity | steps_total | count |
| Energy burned in a cycle | energy | total_energy_burned | kcal |
| Average heart rate in a cycle | heart | heart_rate | bpm |
| Workout | exercise | exercise_session_{type} | minute |
The cycle’s strain is in the energy log’s additionalProperties, and its maximum heart rate in the heart rate log’s. A workout’s calories, distance, elevation gain, strain, average and maximum heart rate, and minutes in each heart rate zone are in its additionalProperties. A WHOOP sport with no Sahha type of its own is exercise_session_other, with WHOOP’s name for it in activity_type.
Steps
WHOOP counts steps per cycle, not per calendar day, so a cycle’s steps reach Sahha only after it ends. Once WHOOP has scored the cycle, Sahha sends its count at the next scheduled poll, as a steps_total log spanning the cycle. The count goes toward the daily steps biomarker for the local day the cycle ends, so a day’s WHOOP steps can differ from a midnight-to-midnight total: a cycle that ends just after midnight counts toward the new day, though most of its steps were taken the day before. A cycle has steps only when WHOOP has step data for it.
Sleep and recovery
| WHOOP data | Log type | Data type | Unit |
|---|---|---|---|
| Sleep | sleep | sleep_session | minute |
| Time in bed | sleep | sleep_stage_in_bed | minute |
| Light, deep, REM and awake time | sleep | sleep_stage_light_total, sleep_stage_deep_total, sleep_stage_rem_total, sleep_stage_awake_total | minute |
| Respiratory rate | oxygen | respiratory_rate | count/minute |
| Resting heart rate | heart | resting_heart_rate | bpm |
| HRV | heart | heart_rate_variability_rmssd | ms |
| SpO₂ | oxygen | oxygen_saturation | percent |
| Skin temperature | temperature | sleeping_wrist_temperature | degC |
WHOOP reports each sleep’s time in each stage rather than a timeline, so each stage is one log spanning the sleep. The session’s sleep performance, consistency and efficiency are in its additionalProperties as WHOOP’s own 0–100 values, with nap set for a nap. Resting heart rate, HRV, SpO₂ and skin temperature come from WHOOP’s recovery, with the recovery score in their additionalProperties. SpO₂ is sent as a fraction: 97% is 0.97.
Body
| WHOOP data | Log type | Data type | Unit |
|---|---|---|---|
| Height | body | height | cm |
| Weight | body | weight | kg |
Not collected
Maximum heart rate from the body measurement, sleep cycle counts, and the time WHOOP recorded no data.
Sync and history
- Live sync. WHOOP sends Sahha a webhook when a sleep, workout or recovery is ready, and Sahha fetches it from the WHOOP API.
- Scheduled polls. WHOOP has no webhook for cycles or body measurements, so Sahha fetches them on a schedule, whether or not the webhook is set up: cycles, with their energy, heart rate and steps, at 05:00 and 17:00 UTC, and body measurements daily at 11:30 UTC, when they’ve changed. Sahha spreads each round of polls over up to four hours, so polled data can arrive several hours after WHOOP records it.
- Backfill. When a user connects, and again whenever they reconnect, Sahha backfills the last 30 days of sleeps, recoveries, workouts and cycles, and fetches their current body measurements.
- Time zones. Cycles, sleeps and workouts keep WHOOP’s time zone offset. Recovery values are single readings in UTC, timed when WHOOP made the recovery.
- Deletions. Data a user deletes in WHOOP stays in Sahha.
Sandbox and production
Use a separate WHOOP app for each Sahha environment. WHOOP’s member and rate limits apply to the whole app, so with one app for both, your sandbox testing would count against your production limits.
Move an app from sandbox to production
To use an app you’ve tested in sandbox for production instead:
- Delete the sandbox integration first. Switch the Sahha Dashboard to Sandbox and delete the WHOOP integration. Sahha revokes each of its users’ access to your WHOOP app.
- Create the integration in production. Switch the dashboard to Production and create the integration with the app’s Client ID and Client secret. Then give the app production’s URLs in the WHOOP Developer Dashboard:
- add the production redirect URL,
https://api.sahha.ai/api/v1/integration/oauth/whoop/callback; - replace the webhook URL with the production integration’s, keeping the model version at V2.
- add the production redirect URL,
- Reconnect your users. Each user connects again in production, which backfills their last 30 days.
Why the sandbox integration goes first
When Sahha revokes a user’s access, WHOOP also stops sending your app’s webhooks for them. If you deleted the sandbox integration after users had reconnected in production, their production connections would stop receiving new sleeps, recoveries and workouts.
WHOOP-specific notes
- Redirect URI must match. WHOOP fails the OAuth flow unless the Sahha callback URL is registered in your app’s allowed redirect URIs (see Add the Sahha redirect URL).
- Webhooks are required. After a connection’s backfill, sleeps, recoveries and workouts arrive only by webhook, so set the webhook URL in step 3. Cycles and body measurements are polled, so they arrive either way.
For data freshness, the connection lifecycle, and disconnecting a user, see Managing connections on the Integrations page.
Support
Need help? Contact support@sahha.ai or join the Slack Community.