Webhooks

Create new webhook.

When creating webhook the AccessLink sends a ping message to the url in request body. The ping message must be answered with 200 OK or otherwise the webhook is not created.

Created webhook is by default in activated state and will send push notifications about subscribed events. Webhook will be automatically deactivated if push notifications have not been successful for a period of seven (7) days. Note! Save the signature_secret_key from response since this is the only chance to get it.

post/v3/webhooks

Request

Request body

eventsWebhookType[] required

Type of events to subscribe.

urlstring uri required

Url where the webhook notification is sent.

Example request

{
  "events": [
    "EXERCISE"
  ],
  "url": "https://myapp.example.com/acl_webhook"
}

Response

Created webhook.

Example response

{
  "data": {
    "id": "abdf33",
    "events": [
      "EXERCISE"
    ],
    "url": "https://myapp.example.com/acl_webhook",
    "signature_secret_key": "abe1f3ae-fd33-11e8-8eb2-f2801f1b9fd1"
  }
}

Changes

    • breaking

      removed the enum value EXERCISE SLEEP CONTINUOUS_HEART_RATE SLEEP_WISE_CIRCADIAN_BEDTIME SLEEP_WISE_ALERTNESS ACTIVITY_SUMMARY of the request property /

    • warning

      added the new ACTIVITY_SUMMARY enum value to the // response property for the response status

    • warning

      added the new CONTINUOUS_HEART_RATE enum value to the // response property for the response status

    • warning

      added the new EXERCISE enum value to the // response property for the response status

    • warning

      added the new PHYSICAL_INFORMATION enum value to the // response property for the response status

    • warning

      added the new SLEEP enum value to the // response property for the response status

    • warning

      added the new SLEEP_WISE_ALERTNESS enum value to the // response property for the response status

    • warning

      added the new SLEEP_WISE_CIRCADIAN_BEDTIME enum value to the // response property for the response status

    • info

      added the new ACTIVITY_SUMMARY enum value to the request property /

    • info

      added the new CONTINUOUS_HEART_RATE enum value to the request property /

    • info

      added the new EXERCISE enum value to the request property /

    • info

      added the new PHYSICAL_INFORMATION enum value to the request property /

    • info

      added the new SLEEP enum value to the request property /

    • info

      added the new SLEEP_WISE_ALERTNESS enum value to the request property /

    • info

      added the new SLEEP_WISE_CIRCADIAN_BEDTIME enum value to the request property /

    • info

      removed the EXERCISE SLEEP CONTINUOUS_HEART_RATE SLEEP_WISE_CIRCADIAN_BEDTIME SLEEP_WISE_ALERTNESS ACTIVITY_SUMMARY enum value from the // response property for the response status

    • breaking

      removed the enum value EXERCISE SLEEP CONTINUOUS_HEART_RATE SLEEP_WISE_CIRCADIAN_BEDTIME SLEEP_WISE_ALERTNESS of the request property /

    • warning

      added the new EXERCISE SLEEP CONTINUOUS_HEART_RATE SLEEP_WISE_CIRCADIAN_BEDTIME SLEEP_WISE_ALERTNESS ACTIVITY_SUMMARY enum value to the // response property for the response status

    • info

      added the new EXERCISE SLEEP CONTINUOUS_HEART_RATE SLEEP_WISE_CIRCADIAN_BEDTIME SLEEP_WISE_ALERTNESS ACTIVITY_SUMMARY enum value to the request property /

    • info

      removed the EXERCISE SLEEP CONTINUOUS_HEART_RATE SLEEP_WISE_CIRCADIAN_BEDTIME SLEEP_WISE_ALERTNESS enum value from the // response property for the response status