Demo docs: examples are illustrative.
Referral API

Authentication

Use secret keys on your server and publishable keys in the browser.

Key typePrefixWhere to use itCan do
Secretsk_live_ / sk_test_Your server onlyEverything
Publishablepk_live_ / pk_test_Browser scriptRecord clicks
Restrictedrk_live_ / rk_test_Internal toolsOnly the scopes you pick

Send the key as a bearer token:

curl https://api.referralapi.example/v1/referrers \
  -H "Authorization: Bearer sk_live_51Hx..."

If a secret key leaks

Roll it immediately in Settings → API keys. The old key stops working after 24 hours, or right away if you choose Expire now.

How is this guide?