Configure the webhook in GitHub

Configure webhook endpoints so that GitHub can use the endpoint to communicate with Incident Response.

Before you begin

Role required: Administrator

About this task

The webhook REST APIs enable you to manage repository, organization, and app webhooks. There are three types of webhooks in GitHub:
  • Repository Webhook: Allows you to receive HTTP POST payloads whenever certain events happen in a repository.
  • Organization Webhook: Allows you to set up a single webhook to receive events from all of your organization's repositories.
  • GitHub App Webhook: Allows you to receive HTTP POST payloads whenever certain events happen for an app.
Note: While this integration with a third-party product is supported, the documentation here is based upon information provided by that third-party. More current information about the operation of that third-party’s system may be available from them directly.

Procedure

  1. Log in to your GitHub application console.
  2. To configure Repository Webhook, perform the following steps:
    1. Click your profile icon and then select Your repositories.

      The Profile menu

    2. Select the repository for which you want to configure the webhook and then select the Settings tab.

      The Settings tab

    3. From the left navigation pane, select Webhooks.

      Add webhook option

    4. Click Add webhook.

      Webhok form

    5. In the Payload URL field, enter the webhook URL that you copied from Incident Response. For more information, see Create a webhook endpoint for GitHub.
    6. In the Content type field, select application/json.
    7. Under Which events would you like to trigger this webhook?, select Let me select individual events and then select the events for which the webhook must trigger.

      Events for which the webhook must trigger

    8. Ensure that the Active check box is selected.
    9. Click Add webhook. The webhook is saved.
  3. To configure Organization Webhook, perform the following steps:
    1. Click your profile icon and then select Your organizations.

    2. Select the organization for which you want to configure the webhook and then select the Settings tab.

    3. From the left navigation pane, select Webhooks.
    4. Click Add webhook.

    5. In the Payload URL field, enter the webhook URL that you copied from Incident Response. For more information, see Create a webhook endpoint for GitHub.
    6. In the Content type field, select application/json.
    7. Under Which events would you like to trigger this webhook?, select Let me select individual events and then select the events for which the webhook must trigger.
    8. Ensure that the Active check box is selected.
    9. Click Add webhook. The webhook is saved.
  4. To configure GitHub App Webhook, perform the following steps:
    1. Click your profile icon and then select Settings.

    2. On the left navigation pane, select Developer settings.

    3. Select the GitHub app for which you want to configure the webhook.
    4. Under the Webhook section, perform the following steps:

      1. Ensure that the Active check box is selected.
      2. In the Webhook URL field, enter the webhook URL that you copied from Incident Response. For more information, see Create a webhook endpoint for GitHub.
    5. Under the Subscribe to events section, select the events for which the webhook must trigger.

    6. Click Save. The webhook is saved.