Webhooks

Prerequisites

  • Obtain a WEBHOOK ID that you wish to integrate with from a provider.
  • Obtain payload and filter information from a provider.
    • payload (Object) - When a webhook you integrated with is activated, a POST request will be sent to your url with payload data
    • filter (String) - Used when a webhook is activated to determine what registrations should be called.

Steps to Integrate With a Webhook

Step 1 – Register your application and obtain an APP ID

  • Method: POST
  • Endpoint: https://venuenext.prd.api.vnops.net/applications
  • Request Body: { name: String }
    • name (optional): Your application name
    • The api call returns an APP ID

Step 2 - Integrate your application with a webhook

  • Method: POST
  • Endpoint: https://venuenext.prd.api.vnops.net/webhooks/register
  • Request Body: { webhookId: String appId: String url: String filters: Array<String> }
    • webhookId (required) - A WEBHOOK ID obtained from a provider.
    • appId (required) - The APP ID of your application returned from the api call in Step 1.
    • url (required) - A url you wish to be called when the webhook is activated.
    • filters (optional) - Your url will be called only when the webhook is activated with a filter value that exists in your filters list. If you don’t provide anything for this field, your url will be called every time the webhook is activated.

Update Webhook Registration

  • Method: PUT
  • Endpoint: https://venuenext.prd.api.vnops.net/webhooks/<APP_ID>/<WEBHOOK_ID>
  • Request Body: { url: String filters: Array<String> }
    • url (optional)
    • filters (optional)

Delete Webhook Registration

  • Method: DELETE
  • Endpoint: https://venuenext.prd.api.vnops.net/webhooks/<APP_ID>/<WEBHOOK_ID>