Source: https://sprinto-test.docs-staging.pageloop.ai/integrations/overview/bitbucket-integration

# Bitbucket Integration

Bitbucket is a cloud-based version control system used to host and manage source code repositories.

When you integrate Bitbucket with Sprinto, Sprinto:

- Syncs repository and workspace configurations
- Monitors change management settings
- Enables access review workflows
- Automates mapped controls and checks

The integration uses **OAuth** authentication.

#### Available Sprinto checks for Bitbucket

Following are the available Sprinto checks for Bitbucket:

| Sprinto check                                                 | Reference procedure                                                                                                       |
| ------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------- |
| Bitbucket user should have MFA enabled                        | [How to fix](/monitors/authentication-and-access-monitors/enabling-bitbucket-mfa)                                         |
| Merging of code changes should require passing status-checks  | [How to fix](/monitors/code-and-repository-monitors)                                                                      |
| Peer review should be enforced for code changes               | [How to fix](/monitors/code-and-repository-monitors/pr-reviewer-is-different-from-author)                                 |
| Branch Protection rules should be enforced for admins         | [How to fix](/monitors/code-and-repository-monitors/how-to-resolve-sprinto-check-for-enabling-branch-protection-rules)    |
| Code changes should be reviewed by peers before merging       | [How to fix](/monitors/code-and-repository-monitors/how-to-resolve-sprinto-check-for-enabling-branch-protection-rules)    |
| Code repo should be classified                                | [How to fix](/monitors/code-and-repository-monitors)                                                                      |
| Critical system access should be removed for offboarded users | [How to fix](/monitors/authentication-and-access-monitors/resolve-sprinto-check-for-removing-access-for-offboarded-users) |

### What Sprinto Monitors

After integration, Sprinto can automate controls and checks related to:

- Version control
- Peer review enforcement
- Branch protection rules
- Pull request controls
- Critical system access reviews
- Offboarding checks

Sprinto activates applicable checks based on your Bitbucket configuration.

---

### Before You Begin

Ensure:

- You have **Admin access** to the Bitbucket account you are integrating.
- Pop-ups are enabled in your browser.
- You are logged in as a Sprinto Admin.
- Understand the permissions required for BitBucket [here](/data-library/understand-sprinto-permissions-and-resource-access#bitbucket).

---

## Integrate Bitbucket with Sprinto

### Step 1: Navigate to Bitbucket Integration

1. Log in to the Sprinto dashboard.
2. Go to **Settings**.
3. Select **Integrations**.
4. Under the **All** tab, search for **Bitbucket**.
5. Click **Connect** next to Bitbucket.

![](/assets/da0f454a8aae-screenshot-2026-02-26-at-12.39.21.png)

---

### Step 2: Review Permissions and Data Usage

A drawer opens displaying:

- Controls and checks automated
- Permissions required
- Data accessed by Sprinto

#### Permissions required

Sprinto requests the following permissions:

- **Team** – Read-only
- **Pull request** – Read-only
- **Repository** – Read-only
- **Repository (Admin)** – Required to administer repositories

#### Data used by Sprinto

Sprinto may access:

- Workspace IDs and names
- Pull requests
- Repository settings
- Group names
- Repository branches
- Dependency vulnerability reports

Review the details and click **Next**.

![](/assets/687c111a7a70-screenshot-2026-02-26-at-12.44.25.png)

---

### Step 3: Authorise via OAuth

You will see the **Setup Bitbucket Integration** drawer:

- **Connection type:** OAuth
- **Prerequisite:** Admin access to your Bitbucket account

Click **Connect**.

![](/assets/c61497d89d3d-screenshot-2026-02-26-at-12.44.46.png)

You are redirected to the Bitbucket login page.

---

### Step 4: Log in to Bitbucket

1. Enter your email and click **Continue**,\
   or log in using SSO (Google, Microsoft, Apple, Slack).

![](/assets/cbc7af368fd2-bitbuck1.png)

2. Review the access request screen.
3. Click **Grant access** to authorise Sprinto.

![](/assets/fddc849717ae-bitbuck2.png)

Once authorisation is successful, you are redirected back to Sprinto.

The integration is now complete.

---

## Post-Connection Flow

After Bitbucket is successfully connected, configure it based on your use case.

---

## Configure Bitbucket as a Change Management System

Use this if Bitbucket is your change management tool.

#### Steps

1. Go to **Data Library** → **Change management**.
2. Click **Add system**.
3. Select **Bitbucket**.
4. Review the workspaces to be monitored.
5. If required, click **Add another workspace**.
6. Click **Add as a change management system**.

Sprinto will now monitor:

- Product code repositories
- Branch protection enforcement
- Peer-reviewed code changes

---

## Configure Bitbucket as a Critical Access System

Use this if Bitbucket access must be reviewed periodically.

#### Steps

1. Go to **Data Library** → **Access**.
2. Click **Add a critical system**.
3. Select **Bitbucket** and click **Add System**.
4. Open Bitbucket from the Access Overview page.
5. Click **Configure now** under the Summary tab.

#### Configure Access Validity

1. Click **Configure** next to **Access validity**.
2. Choose one of the following:
   - All users
   - Role-based
   - Ticket-based

#### Assign a Critical System Owner (Optional)

You can assign a critical system owner other than the default assignee for work delegation.

Contact Sprinto Support if your current plan does not support custom owner assignment.

---

### Data Sync and Check Computation

Once configured:

- Sprinto starts syncing Bitbucket data.
- Sprinto computes applicable controls and checks.
- Status updates appear in the Bitbucket system page.

Wait for the initial sync to complete before reviewing control results.

---

## Troubleshooting

### Bitbucket login window does not open

**Possible cause:** Browser pop-ups are blocked.

**Resolution:**

- Enable pop-ups for the Sprinto application in your browser.
- Retry the integration from **Settings → Integrations → Bitbucket**.

---

### “Insufficient permissions” error during connection

**Possible cause:** You do not have Admin access to the Bitbucket workspace.

**Resolution:**

- Ensure you are logged in as a **Workspace Admin** in Bitbucket.
- Ask your Bitbucket administrator to grant you admin access.
- Retry the integration.

---

### “Grant access” button does not complete authorisation

**Possible causes:**

- Session timeout
- Network interruption
- Revoked or restricted permissions

**Resolution:**

1. Log out of Bitbucket.
2. Log back in and restart the integration process.
3. Ensure you click **Grant access** on the Bitbucket authorisation screen.
4. Confirm that the required repository admin permissions are enabled.

---

### Bitbucket does not appear under Change Management or Access

**Possible cause:** Integration was not completed successfully.

**Resolution:**

- Go to **Settings → Integrations** and verify Bitbucket shows as connected.
- If not connected, repeat the integration steps.
- If already connected, refresh the page and try again.

---

### Workspaces are missing after integration

**Possible cause:** The connected account does not have access to all workspaces.

**Resolution:**

- Verify that the Bitbucket account used during OAuth has access to the required workspaces.
- Ensure the account has appropriate workspace-level permissions.
- Reconnect Bitbucket if permissions were updated after initial integration.

---

### Controls are not computed after integration

**Possible cause:** Initial data sync is still in progress.

**Resolution:**

- Wait for the first sync cycle to complete.
- Refresh the Bitbucket system page.
- Check the status under **Data Library → Change mgmt** or **Access**.

If checks are still not computed after sync completion, contact Sprinto Support.

---

### Need Further Assistance?

If the issue persists:

- Disconnect Bitbucket from **Settings → Integrations**.
- Reconnect using an Admin account.
- Contact Sprinto Support with:
  - Workspace name
  - Error message (if any)
  - Screenshot of the failure screen

Once the Bitbucket account is configured, Sprinto starts the data syncing process and computes the Sprinto checks. Wait until Sprinto completes the data syncing.

Contact [Sprinto support](mailto:www.support@sprinto.com) if you have any queries related to the integration or need any assistance.
