Configure Webhooks for Bitbucket

Modified on Wed, 8 Apr at 5:15 AM

Overview

Webhooks enable real-time communication between Bitbucket repositories and the Cubyts platform. Once configured, Cubyts can automatically analyze pull requests, commits, and review activity to generate actionable insights.


Prerequisites

Before setting up the webhook, ensure you have:

  • Admin access to the target Bitbucket repository.

  • Access to the Cubyts platform.

  • Generated Payload URL and Secret from the Cubyts Bitbucket integration page.


Step-by-Step Setup

Navigate to Webhook Settings:

  1. Open your Bitbucket repository.

  2. Go to Repository settings.

  3. Click on Webhooks.

  4. Select Add webhook.


Configure Webhook Details

Fill in the following fields:

Title

  • Provide a meaningful name (e.g., Cubyts Webhook).

URL

  • Paste the Payload URL generated from Cubyts.

  • Note: The payload URL will be available at the repository level in the Cubyts Bitbucket integration page.

Secret

  • Enter the Secret generated from Cubyts.

  • Note: The secret will be available at the repository level in the Cubyts Bitbucket integration page.


Select Trigger

Enable the following triggers:

  • Repository: push.

  • Pull request: created, Updated, Merged, Declined, Comment created, Comment updated, Comment resolved, Comment reopened.


Final Configuration

Ensure the following settings are correctly configured:

Setting

Value

URL

Cubyts Payload URL

Secret Token

Generated from Cubyts

Events

List mentioned earlier

Click Save (or Add webhook) to complete the setup.


Notes & Best Practices

  • A webhook must be configured per repository.

  • Keep your Secret secure and do not expose it publicly.

  • If you regenerate the secret in Cubyts, update it in Bitbucket immediately.

  • Avoid duplicate webhooks for the same repository.

Was this article helpful?

That’s Great!

Thank you for your feedback

Sorry! We couldn't be helpful

Thank you for your feedback

Let us know how can we improve this article!

Select at least one of the reasons

Feedback sent

We appreciate your effort and will try to fix the article