> For the complete documentation index, see [llms.txt](https://docs.tryterra.co/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.tryterra.co/help-center/help-topics/something-else/custom-subdomains-ssl-and-security/custom-subdomain-redirect-webhook-setup.md).

# What redirect and webhook URLs do I use for a custom WHOOP subdomain?

For a custom-credential provider connection, the redirect URI registered with the provider must be a subdomain on your own domain (for example whoop.yourdomain.com), not Terra's API URL.

For a custom-credential provider connection, the redirect URI registered with the provider must be a **subdomain on your own domain** (for example `whoop.yourdomain.com`), not Terra's API URL.

For Whoop:

* Redirect URL: `https://whoop.yourdomain.com/auth/whoop/oauth2`
* Webhook URL: `https://whoop.yourdomain.com/hooks/whoop/push`

For Dexcom, the redirect URL is `https://dexcom.yourdomain.com/auth/dexcom/oauth2` (or `/auth/dexcom_eu/oauth2` for the EU variant).

**Set up the subdomain from the provider's connection settings on the Connections page.** The dashboard gives you one DNS record to add, issues the certificate, then shows these URLs ready to copy. Paste them into the provider's developer portal, not into a Terra destination. For WHOOP, also set the webhook model to v2 and tick every scope. See the [WHOOP setup guide](https://docs.tryterra.co/unified-api/whoop).

The redirect URL saved with your credentials is filled in from the live subdomain, so it always matches. The URL whitelisted in the provider portal must match it exactly, or OAuth fails with a redirect mismatch error.

If your domain changes, choose **Change** next to the custom domain in the connection settings, set up the new subdomain, then update the redirect and webhook URLs in the provider's developer portal.
