> For the complete documentation index, see [llms.txt](https://docs.threatrix.io/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.threatrix.io/integrations/scm-integrations/bitbucket.md).

# Bitbucket

## Prepare for SCM Integration Setup

* Within Threat Center, navigate to Admin-> Settings->Integrations->SCM Integrations.
* Take note of your Redirect URL as you'll need it in the next step.&#x20;

## Create Group Bitbucket OAuth Application

Login to GitLab with a user that has permission to create an application

* Login to your Atlassian or Bitbucket account with a user who has permission to create an application

* If necessary, switch to Bitbucket from the top left Atlassian menu.

* Select the **Settings** cog on the top navigation bar.

* Select **Workspace settings** under **Bitbucket Administration** from the **Settings** dropdown menu.\
  If you're giving access to a workspace, make sure you have administrative access.

* Select **OAuth consumers** under **Apps and Features** on the left navigation sidebar.

* Select **Add consumer**. The **Add OAuth consumer** page appears.

* Enter Name "Threatrix"

* Enter the `Redirect URIfrom the Threatrix dashboard`

* &#x20;Select permissions as shown below

*

```
<figure><img src="/files/zZvDywUGYITD1GcNeACW" alt=""><figcaption></figcaption></figure>
```

* Click "Save"

Copy your application ID and Secret as you'll need them for the next step.&#x20;

<figure><img src="/files/pT9km2CqIABv0qXK9d89" alt=""><figcaption></figcaption></figure>

## Complete SCM Integration

In Threat Center, SCM Integration,  complete the following fields&#x20;

* Name: Use a unique name that employees will recognize, like your team, group or division. If necessary, add the SCM type if there are more than one in the same group.
* Provider Type: Select BITBUCKET from the&#x20;
* Base URL: This is the URL of your SCM server
* Token URL: The Token URL of your server
* Authorization URL: The authorization URL of your server
* Client ID / Application ID: This is the Application ID or Client ID provided to you when you created your application in your SCM
* Client Secret / Secret: This is the secret provided to you when you created your application in your SCM.

<figure><img src="/files/z6mwzagJ4LU5A1zaD6yX" alt=""><figcaption></figcaption></figure>
