Webhooks can be used to notify your application when certain events occur in Swivle.
Example: You may want to alert and respond in your remote application when file metadata is updated or when a Share Link is created.
When a defined event occurs, a HTTP POST with the event payload as JSON body is sent to the URL that is configured in the Webhook.
Subscribing to events using a Webhook means that your application does not have to periodically poll the Swivle API to determine whether changes have occurred. A webhook delivers data to other applications as it happens, meaning you get data immediately.
Webhooks can be configured through the Management Console. There you will find which events you can receive and detailed samples of the payloads that are delivered.
Consuming a Webhook
You will need to set up a URL in your app that’s accessible from the public web that can receive the HTTP POST of the webhook. In some cases you may want to build this yourself, but you can also use integration platforms like Zapier to receive webhooks and trigger automated actions.
Playing around and testing webhooks
There are many free tools available to capture and inspect webhook events for testing purposes, such as:
We will retry anytime we do not receive what we consider a successful response from the destination server. Below is a list of HTTP status codes that we consider as successes/failures.
When 5 seconds
In total, we will try to invoke the webhook destination 3 times when it keeps failing, so max 2 retries.
Securing your webhooks
We recommend that you validate that webhook requests are coming from Swivle. Read about how to do this in the article: Securing Webhooks
To make use of webhooks, you need to have a Swivle API subscription or a subscription plan that includes the API. You can buy your API subscription on the Subscriptions page in the Management Console.
When your API subscription expires, all webhooks will be disabled until you activate a new API subscription.