Here is a structured outline for the Webhooks section of your Periskope API documentation. This guide includes all necessary instructions and screenshots to assist users in setting up and managing webhooks for real-time data processing.


Webhooks on Periskope provides a powerful mechanism to allow your applications to receive real-time notifications of events happening within the Periskope platform. Unlike typical APIs where you would need to poll for data frequently, webhooks provide the data as it happens, greatly enhancing efficiency.

Periskope utilizes webhooks to allow real-time updates to external services whenever significant actions occur within the WhatsApp client management platform.

Prerequisites

  1. A Periskope account: To use the Periskope API, you need to have a Periskope account. If you don’t have one, you can sign up for a free trial here.
  2. POST / Endpoint: Prepare your server to start receiving POST requests. Your server should have an endpoint ready to catch data sent by Periskope when events are sent.

In order to start receiving webhooks, you need to have a server that can handle incoming HTTP POST requests. The POST request endpoint needs to be open and publicly accessible without any authentication.

Setting up webhooks on Periskope πŸ”§

You can access the webhook configuration through your Periskope settings or click here to visit. Here, you can manage and set up new webhooks.

1

Add webhook πŸ”Œ

Click on the Add Webhook button. This opens a modal where you can enter the URL that will receive the webhook POST requests.

Add webhook

2

Choose events 🏁

Choose the events you want to subscribe to from the list below. Each event corresponds to different actions or changes in Periskope and whatsapp that you can receive notifications for.

3

Done βœ…

After configuring the URL and selecting the desired events, save your settings to activate the webhook.

Result πŸš€

Webhooks are now setted up on your Periskope account. Your endpoint will now receive HTTP POST requests whenever the subscribed events occur on the Periskope platform.

You can test your webhook by triggering any selected event from the Periskope platform.

Event structure πŸ“¦

You’ll be receiving the data in the following format:

{
  "event": "<event-type>",
  "data": "<event-data>", // complete data object as mentioned in Objects section
  "org_id": "<your-organisation-id>",
  "previous_attributes": "<previous-attributes>", // attributes changes in new object. In case of an update event.
  "timestamp": "<timestamp>" // timestamp of the event creation
}