{
  "info": {
    "_postman_id": "aifitnessapi-polar",
    "name": "Polar AccessLink (aifitnessapi.com)",
    "description": "Polar AccessLink: OAuth 2.0 and Webhook samples requests built from the vendor documentation aifitnessapi.com quotes. Generated by scripts/build-collections.mjs; no secrets included. https://aifitnessapi.com/collections",
    "schema": "https://schema.getpostman.com/json/collection/v2.1.0/collection.json"
  },
  "item": [
    {
      "name": "OAuth 2.0",
      "description": "Polar AccessLink's authorization-code flow as its documentation describes it, read 2026-11-05. Fill client_id, redirect_uri and scope in an environment of your own and keep client_secret there, never in a shared collection. No refresh request: No refresh flow is documented: the token response lists no refresh_token, and the reference says access tokens do not expire unless revoked.\n\nThe same facts, with each source sentence, at https://aifitnessapi.com/integrate/polar-api and https://aifitnessapi.com/tools/oauth-playground.",
      "item": [
        {
          "name": "1. Authorization URL (open in a browser)",
          "request": {
            "method": "GET",
            "header": [],
            "url": {
              "raw": "https://flow.polar.com/oauth2/authorization?response_type=code&client_id={{client_id}}&redirect_uri={{redirect_uri}}&scope={{scope}}&state={{state}}",
              "protocol": "https",
              "host": [
                "flow",
                "polar",
                "com"
              ],
              "path": [
                "oauth2",
                "authorization"
              ],
              "query": [
                {
                  "key": "response_type",
                  "value": "code"
                },
                {
                  "key": "client_id",
                  "value": "{{client_id}}"
                },
                {
                  "key": "redirect_uri",
                  "value": "{{redirect_uri}}"
                },
                {
                  "key": "scope",
                  "value": "{{scope}}"
                },
                {
                  "key": "state",
                  "value": "{{state}}"
                }
              ]
            },
            "description": "https://flow.polar.com/oauth2/authorization. Authorization endpoint in Polar Flow. Open this URL in a browser (in Postman: copy it from the request bar); the user signs in and Polar AccessLink redirects to {{redirect_uri}} with ?code=… Put that value in the auth_code variable.\n\nSource: Polar AccessLink API v3, “Authentication”, https://www.polar.com/accesslink-api/\n\nScope: Optional: without it the user is asked to grant every scope linked to your client. Source: Polar AccessLink API v3, “Authentication”, https://www.polar.com/accesslink-api/\n\nDocumented scopes (joined with spaces):\n- accesslink.read_all: Access to the user's data\n\nPKCE: Not mentioned on the AccessLink reference."
          },
          "response": []
        },
        {
          "name": "2. Exchange the code for tokens",
          "request": {
            "method": "POST",
            "header": [
              {
                "key": "Content-Type",
                "value": "application/x-www-form-urlencoded",
                "type": "text"
              },
              {
                "key": "Accept",
                "value": "application/json;charset=UTF-8",
                "type": "text"
              }
            ],
            "url": {
              "raw": "https://polarremote.com/v2/oauth2/token",
              "protocol": "https",
              "host": [
                "polarremote",
                "com"
              ],
              "path": [
                "v2",
                "oauth2",
                "token"
              ]
            },
            "description": "https://polarremote.com/v2/oauth2/token. Token endpoint in Polar Remote, authenticated with HTTP Basic.\n\nSource: Polar AccessLink API v3, “Authentication”, https://www.polar.com/accesslink-api/\n\nClient credentials go as HTTP Basic: {{client_id}} as the user name, {{client_secret}} as the password.\n\nToken lifetime: expires_in is in seconds; Polar's example, 31535999, is about one year. Source: Polar AccessLink API v3, “Authentication”, https://www.polar.com/accesslink-api/\n\nNote: The code expires in 10 minutes and must be used once; reuse is denied and deletes every issued token. Source: Polar AccessLink API v3, “Authentication”, https://www.polar.com/accesslink-api/\n\nNote: redirect_uri goes to the token endpoint only if it was sent to the authorization endpoint. Source: Polar AccessLink API v3, “Authentication”, https://www.polar.com/accesslink-api/\n\nNote: After the exchange, register the user before reading their data. Source: Polar AccessLink API v3, “Authentication”, https://www.polar.com/accesslink-api/\n\nNote: The token request sends Content-Type application/x-www-form-urlencoded and Accept application/json;charset=UTF-8. Source: Polar AccessLink API v3, “Authentication”, https://www.polar.com/accesslink-api/",
            "auth": {
              "type": "basic",
              "basic": [
                {
                  "key": "username",
                  "value": "{{client_id}}",
                  "type": "string"
                },
                {
                  "key": "password",
                  "value": "{{client_secret}}",
                  "type": "string"
                }
              ]
            },
            "body": {
              "mode": "urlencoded",
              "urlencoded": [
                {
                  "key": "grant_type",
                  "value": "authorization_code",
                  "type": "text"
                },
                {
                  "key": "code",
                  "value": "{{auth_code}}",
                  "type": "text"
                },
                {
                  "key": "redirect_uri",
                  "value": "{{redirect_uri}}",
                  "type": "text"
                }
              ]
            }
          },
          "response": []
        }
      ]
    },
    {
      "name": "Webhook samples",
      "description": "Polar AccessLink's documented example notifications, sent to {{local_url}} (your local handler) unchanged. Signature: HMAC-SHA256 of the payload, keyed by the signature_secret_key returned once when you create the webhook, hex, in Polar-Webhook-Signature; the event type is in Polar-Webhook-Event. Source: Polar AccessLink API v3, “Accesslink webhooks” and data models, https://www.polar.com/accesslink-api/\n\nHeaders that carry a signature hold the placeholder Polar AccessLink prints, so a handler that verifies signatures will reject these: to send correctly signed requests, use https://aifitnessapi.com/webhooks/send-sample.mjs. Respond: Answer with 200. The PING sent when a webhook is created or its URL changes must get 200 OK, or the change is not made.\n\nPayload library with JSON Schemas: https://aifitnessapi.com/webhooks#polar.",
      "item": [
        {
          "name": "PING",
          "request": {
            "method": "POST",
            "header": [
              {
                "key": "Content-Type",
                "value": "application/json",
                "type": "text"
              },
              {
                "key": "Polar-Webhook-Event",
                "value": "PING",
                "type": "text",
                "description": "As in Polar AccessLink's example."
              }
            ],
            "url": {
              "raw": "{{local_url}}",
              "host": [
                "{{local_url}}"
              ]
            },
            "description": "Sent as an HTTP POST when a webhook is created or modified, to verify the URL.\n\nPolar's ping message. Source: Polar AccessLink API v3, “Accesslink webhooks” and data models, https://www.polar.com/accesslink-api/",
            "body": {
              "mode": "raw",
              "raw": "{\n  \"timestamp\": \"2018-05-15T14:22:24Z\",\n  \"event\": \"PING\"\n}",
              "options": {
                "raw": {
                  "language": "json"
                }
              }
            }
          },
          "response": []
        },
        {
          "name": "Exercise",
          "request": {
            "method": "POST",
            "header": [
              {
                "key": "Content-Type",
                "value": "application/json",
                "type": "text"
              },
              {
                "key": "Polar-Webhook-Event",
                "value": "EXERCISE",
                "type": "text",
                "description": "As in Polar AccessLink's example."
              }
            ],
            "url": {
              "raw": "{{local_url}}",
              "host": [
                "{{local_url}}"
              ]
            },
            "description": "This event is sent when new exercise data is available for the user.\n\nPolar's payload example for EXERCISE. Source: Polar AccessLink API v3, “Accesslink webhooks” and data models, https://www.polar.com/accesslink-api/",
            "body": {
              "mode": "raw",
              "raw": "{\n  \"event\": \"EXERCISE\",\n  \"user_id\": 475,\n  \"entity_id\": \"aQlC83\",\n  \"timestamp\": \"2018-05-15T14:22:24Z\",\n  \"url\": \"https://www.polaraccesslink.com/v3/exercises/aQlC83\"\n}",
              "options": {
                "raw": {
                  "language": "json"
                }
              }
            }
          },
          "response": []
        },
        {
          "name": "Sleep",
          "request": {
            "method": "POST",
            "header": [
              {
                "key": "Content-Type",
                "value": "application/json",
                "type": "text"
              },
              {
                "key": "Polar-Webhook-Event",
                "value": "SLEEP",
                "type": "text",
                "description": "As in Polar AccessLink's example."
              }
            ],
            "url": {
              "raw": "{{local_url}}",
              "host": [
                "{{local_url}}"
              ]
            },
            "description": "This event is sent when new sleep data is available for the user.\n\nPolar's payload example for SLEEP. Source: Polar AccessLink API v3, “Accesslink webhooks” and data models, https://www.polar.com/accesslink-api/",
            "body": {
              "mode": "raw",
              "raw": "{\n  \"event\": \"SLEEP\",\n  \"user_id\": 475,\n  \"date\": \"2019-12-31\",\n  \"timestamp\": \"2018-05-15T14:22:24Z\",\n  \"url\": \"https://www.polaraccesslink.com/v3/users/sleep/2019-12-31\"\n}",
              "options": {
                "raw": {
                  "language": "json"
                }
              }
            }
          },
          "response": []
        },
        {
          "name": "Continuous heart rate",
          "request": {
            "method": "POST",
            "header": [
              {
                "key": "Content-Type",
                "value": "application/json",
                "type": "text"
              },
              {
                "key": "Polar-Webhook-Event",
                "value": "CONTINUOUS_HEART_RATE",
                "type": "text",
                "description": "As in Polar AccessLink's example."
              }
            ],
            "url": {
              "raw": "{{local_url}}",
              "host": [
                "{{local_url}}"
              ]
            },
            "description": "This event is sent when new continuous heart rate data is available for the user.\n\nPolar's payload example for CONTINUOUS_HEART_RATE. Source: Polar AccessLink API v3, “Accesslink webhooks” and data models, https://www.polar.com/accesslink-api/",
            "body": {
              "mode": "raw",
              "raw": "{\n  \"event\": \"CONTINUOUS_HEART_RATE\",\n  \"user_id\": 475,\n  \"date\": \"2022-09-30\",\n  \"timestamp\": \"2018-05-15T14:22:24Z\",\n  \"url\": \"https://www.polaraccesslink.com/v3/users/continuous-heart-rate/2022-09-30\"\n}",
              "options": {
                "raw": {
                  "language": "json"
                }
              }
            }
          },
          "response": []
        },
        {
          "name": "SleepWise circadian bedtime",
          "request": {
            "method": "POST",
            "header": [
              {
                "key": "Content-Type",
                "value": "application/json",
                "type": "text"
              },
              {
                "key": "Polar-Webhook-Event",
                "value": "SLEEP_WISE_CIRCADIAN_BEDTIME",
                "type": "text",
                "description": "As in Polar AccessLink's example."
              }
            ],
            "url": {
              "raw": "{{local_url}}",
              "host": [
                "{{local_url}}"
              ]
            },
            "description": "This event is sent when new circadian bedtime data is available for the user.\n\nPolar's payload example for SLEEP_WISE_CIRCADIAN_BEDTIME. Source: Polar AccessLink API v3, “Accesslink webhooks” and data models, https://www.polar.com/accesslink-api/",
            "body": {
              "mode": "raw",
              "raw": "{\n  \"event\": \"SLEEP_WISE_CIRCADIAN_BEDTIME\",\n  \"user_id\": 475,\n  \"from\": \"2022-09-30\",\n  \"to\": \"2022-10-02\",\n  \"timestamp\": \"2022-10-02T14:22:24Z\",\n  \"url\": \"https://www.polaraccesslink.com/v3/users/sleepwise/circadian-bedtime/date?from=2022-09-30&to=2022-10-02\"\n}",
              "options": {
                "raw": {
                  "language": "json"
                }
              }
            }
          },
          "response": []
        },
        {
          "name": "SleepWise alertness",
          "request": {
            "method": "POST",
            "header": [
              {
                "key": "Content-Type",
                "value": "application/json",
                "type": "text"
              },
              {
                "key": "Polar-Webhook-Event",
                "value": "SLEEP_WISE_ALERTNESS",
                "type": "text",
                "description": "As in Polar AccessLink's example."
              }
            ],
            "url": {
              "raw": "{{local_url}}",
              "host": [
                "{{local_url}}"
              ]
            },
            "description": "This event is sent when new alertness data is available for the user.\n\nPolar's payload example for SLEEP_WISE_ALERTNESS. Source: Polar AccessLink API v3, “Accesslink webhooks” and data models, https://www.polar.com/accesslink-api/",
            "body": {
              "mode": "raw",
              "raw": "{\n  \"event\": \"SLEEP_WISE_ALERTNESS\",\n  \"user_id\": 475,\n  \"from\": \"2022-09-30\",\n  \"to\": \"2022-10-02\",\n  \"timestamp\": \"2022-10-02T14:22:24Z\",\n  \"url\": \"https://www.polaraccesslink.com/v3/users/sleepwise/alertness/date?from=2022-09-30&to=2022-10-02\"\n}",
              "options": {
                "raw": {
                  "language": "json"
                }
              }
            }
          },
          "response": []
        },
        {
          "name": "Activity summary",
          "request": {
            "method": "POST",
            "header": [
              {
                "key": "Content-Type",
                "value": "application/json",
                "type": "text"
              },
              {
                "key": "Polar-Webhook-Event",
                "value": "ACTIVITY_SUMMARY",
                "type": "text",
                "description": "As in Polar AccessLink's example."
              }
            ],
            "url": {
              "raw": "{{local_url}}",
              "host": [
                "{{local_url}}"
              ]
            },
            "description": "This event is sent when new activity summary data is available for the user.\n\nPolar's payload example for ACTIVITY_SUMMARY. Source: Polar AccessLink API v3, “Accesslink webhooks” and data models, https://www.polar.com/accesslink-api/",
            "body": {
              "mode": "raw",
              "raw": "{\n  \"event\": \"ACTIVITY_SUMMARY\",\n  \"user_id\": 475,\n  \"date\": \"2022-09-30\",\n  \"timestamp\": \"2022-10-02T14:22:24Z\",\n  \"url\": \"https://www.polaraccesslink.com/v3/users/activities/2022-09-30\"\n}",
              "options": {
                "raw": {
                  "language": "json"
                }
              }
            }
          },
          "response": []
        },
        {
          "name": "Physical information",
          "request": {
            "method": "POST",
            "header": [
              {
                "key": "Content-Type",
                "value": "application/json",
                "type": "text"
              },
              {
                "key": "Polar-Webhook-Event",
                "value": "PHYSICAL_INFORMATION",
                "type": "text",
                "description": "As in Polar AccessLink's example."
              }
            ],
            "url": {
              "raw": "{{local_url}}",
              "host": [
                "{{local_url}}"
              ]
            },
            "description": "This event is sent when new physical information data is available for the user.\n\nPolar's payload example for PHYSICAL_INFORMATION. Source: Polar AccessLink API v3, “Accesslink webhooks” and data models, https://www.polar.com/accesslink-api/",
            "body": {
              "mode": "raw",
              "raw": "{\n  \"event\": \"PHYSICAL_INFORMATION\",\n  \"user_id\": 475,\n  \"timestamp\": \"2025-12-31T14:22:24Z\",\n  \"url\": \"https://www.polaraccesslink.com/v3/users/physical-info\"\n}",
              "options": {
                "raw": {
                  "language": "json"
                }
              }
            }
          },
          "response": []
        }
      ]
    }
  ],
  "variable": [
    {
      "key": "client_id",
      "value": "",
      "type": "string",
      "description": "Your app's client ID, from the vendor's developer console."
    },
    {
      "key": "client_secret",
      "value": "",
      "type": "string",
      "description": "Keep it in a Postman or Bruno environment marked secret. This collection ships it empty."
    },
    {
      "key": "redirect_uri",
      "value": "",
      "type": "string",
      "description": "The redirect URI registered with the vendor."
    },
    {
      "key": "scope",
      "value": "",
      "type": "string",
      "description": "Scopes to request, joined as the vendor documents (see the authorization request)."
    },
    {
      "key": "state",
      "value": "",
      "type": "string",
      "description": "A random value you check on the redirect."
    },
    {
      "key": "auth_code",
      "value": "",
      "type": "string",
      "description": "The ?code= value from the redirect."
    },
    {
      "key": "local_url",
      "value": "http://localhost:3000/webhooks/polar",
      "type": "string",
      "description": "Where your webhook handler listens."
    }
  ]
}
