Supported webhook events:
- Repository – Push
- Pull request – Created
- Pull request – Updated
(While the above video showcases other integration, jump to 01:41 to see Webhook setup for Bitbucket Cloud.)
-
Configure webhook by logging in to your Bitbucket:
-
Open a project by clicking on it.
-
Click Repository Settings then under WORKFLOW, select Webhooks.
-
Click Add webhook to create a webhook for the repository. The Add new webhook screen appears.
-
Title – This is the title name for this webhook.
-
URL – This field accepts the webhook url from your Git Integration for Jira app > Webhooks setting.
-
Triggers – By default, the trigger for the webhook is a repository push. If you want different actions to trigger the webhook, click Choose from a full list of triggers. The list of all the webhook trigger event types is displayed.
Set the necessary scope depending on your organization access/usage rules. For this guide, choose the following triggers:
-
Repository – Push (required)
-
Pull Request (optional) – select these options to also include the pull request triggers:
- Created
- Updated
-
-
-
Switch to your Jira instance then navigate to Git > Manage repositories page and then open Webhooks.
-
Copy the complete Webhook URL by clicking the copy icon adjacent to the right of the URL field.
-
Switch back to Bitbucket (where you left off) and paste this information into the provided URL box.
-
Enter a meaningful Title name for this webhook.
-
For the Triggers, if your organization does not require pull request events, select Repository push. Otherwise, select Choose from a full list of triggers (recommended) and then tick Repository (Push) and Pull Request (Created, Updated).
-
Click Save to complete this setup.
Pull Request Webhooks
The Git Integration for Jira app supports pull request webhooks now.
For pull request triggers, you will need to have three (3) separate service hooks configuration for it to work properly. See step 9, second option for the webhook triggers.
More related articles about webhooks setup
Creating reindex triggers for a single repository
Webhooks GitHub Organization support
Adding webhooks for Azure DevOps Repos | VSTS
Adding webhooks for Azure DevOps Server | TFS
Adding webhooks for Bitbucket (this page)