Configure a Webhook in GitHub

A. Create a Webhook API Token from ARM

Follow the instructions below to create a webhook API token from ARM.

  1. Log in to ARM.

  2. Click on the Admin section, then select 'API Token.'

  3. Click on 'Create API Token.'

  1. Enter the token name.

  2. Select Type as "webhook."

  3. Enter a description if required.

  4. Click on 'Create Option.'

  1. Your new API token is created.


B. Create Webhook with Authentication on GitHub

Webhooks allow external services to be notified when certain events happen. When the specified events happen, we’ll send a POST request to each of the URLs you provide.

  1. Go to https://github.com/login and sign in to GitHub with your username and password.

  1. Select the related repository you own.

  1. Click on 'Settings' on the right panel.

  1. Then click on 'Webhooks & Services' on the left panel. Click on the 'Add WebHook' Button.

  1. In the URL form field, paste the copied URL or enter the payload URL manually. The payload URL is the URL of the server that will receive the webhook POST requests. Payload URL: <instance_url>/api/webhook/v2/<orgname>/trigger-scm-push-request For example, using instance: https://login.autorabit.com Payload URL: https://login.autorabit.com/autorabitrest/webhook/triggerSCMPushrequest

  1. Enter the Secret Key generated in ARM as an API token.

  1. Select 'application/json' as the content type. The application/json content type will deliver the JSON payload directly as the body of the POST request.

  1. Select 'Just the push events.' Events are at the core of webhooks. These webhooks fire whenever a certain action is taken on the repository, which your server's payload URL intercepts and acts upon.

  2. Click Add Webhook.

  1. However, to trigger the webhook using pull request, you need to select 'Let me select individual events' and select the Pull requests checkbox.

  1. Click on Add webhook to save the webhook.


Smart Commits

In this section, you can select the pattern used to read the comment in a revision associated with your ALM story. For example, 'git commit m [project123] # add README file into the project.'

If you want to configure a webhook in your repository, select the ‘Enable auto update on webhook’ checkbox to reveal the URL required for the webhook settings. For more information on how to configure a webhook in different repositories, refer HERE. You can also choose to sync external smart commits.

For Enterprise Customers

/api/webhook/v2/<orgname>/enterprise/trigger-scm-push-request

/api/webhook/v2/<orgname>/enterprise/sync-alm-commits

Last updated

<