API Webhook

With the API webhook, it is possible to receive notifications on your own URL whenever an object is changed within OnlineAfspraken. At the time of writing, notifications can be received for: Appointments, Consumers.

To use the webhook, it must be enabled per account. In the OnlineAfspraken backend, go to Settings -> Additional Features -> API Data. On this screen, you can enable the webhook and specify for which objects you want to receive notifications.

As soon as an object of this type is changed (created, edited, deleted), your own URL will be called with some anonymous data. You can then retrieve the object itself again via the API using the secure API method.

Note: your own URL must be accessible externally. It is possible to whitelist our web server, but this is a process that does not go through OA.

The only requirement for the webhook URL is to return a status 200 code within 10 seconds. If this fails, for technical reasons such as a temporary outage, the push will be retried after 5 minutes, and then after an hour. A push occurs only once until successful or up to 3 attempts.

The webhook URL is called with the following GET parameters:

- entity (the type of object, such as appointment or consumer)

- id ( id of the object )

- apiKey (API key of the account. For multiple accounts, e.g., on a private OA subdomain, this allows distinguishing between accounts on the same webhook URL)