Webhook Integration Guide

Webhook Integration

Webhooks are user defined HTTP callbacks. They are usually triggered by some event, and when that event occurs, the source site makes an HTTP request to the URI configured for the webhook.

How Webhook users benefit from PagerTree

Webhooks are versatile user-defined callbacks that many applications support. PagerTree acts as the dispatcher for these callbacks, determining the right people to notify based on on-call schedules. PagerTree notifies them via email, sms, voice, and/or push notifications until the incident is acknowledged or closed.

Functionality of Integration

The Webhook integration is one-way, meaning:

  • When an incident is created (event_type == "create") in Webhook, an incident is created in PagerTree automatically.
  • When an incident is created (event_type == "acknowledge") in Webhook, an incident is acknowledged in PagerTree automatically.
  • When a incident is resolved (event_type == "resolve") in Webhook, the incident is resolved in PagerTree automatically.

Tutorial Overview

In this integration tutorial we will show you how to send a Webhook into PagerTree. The estimated time for this integration is 10 minutes. We assume that you already have a PagerTree account setup.

In PagerTree

  1. Click the team you wish to add the integration to. Select Team
  2. On the team page, click the “Integrations” tab. Click Integrations Tab
  3. On the “Integrations” tab, click the “+ Integration” button. Click Plus Integration Button
  4. In the “Create Integration” box, fill out the following:
    1. Name of the Integration,
    2. Select the Integration Type to Webhook
    3. Select an appropriate urgency for when this integration is triggered
    4. Select the team member the incident will be created by (example: manager or team lead)
    5. Select the team this incident will be assigned to Click Create
  5. Click “Create”
  6. Copy the WebHook URL Copy Webhook URL

Configure the Webhook

The calling application must send a PUT request with a Content-Type: application/json. The body of the request should have the following values.

Field Type Valid Values
event_type string create/acknowledge/resolve
Id string a unique id
Title string (non-empty)
Description string (non-empty)
Example Request
PUT /integration/15/b965aee0-38b7-11e7-b537-ff479bbed3d0/b965aee1-39a7-11e7-b537-ff479bbed3d0 HTTP/1.1
Host: api.pagertree.com
Content-Type: application/json

{
	"event_type": "create",
	"Id": "example-id-123",
	"Title": "Example Incident Title",
	"Description": "Example Incident Description"
}

You have successfully completed the Webhook Integration. Now when a webhook is triggered, PagerTree will create an incident and route it to the correct team member that is on-call. If you have any questions please contact support@pagertree.com