> For the complete documentation index, see [llms.txt](https://docs.walnutai.ai/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.walnutai.ai/getting-started/projects/create-a-new-project/external-data-and-connections/how-to-integrate-bitbucket-with-walnutai.md).

# How to Integrate Bitbucket with WalnutAI?

**Steps to Generate a Bitbucket API Token**

* Log in to your Bitbucket account.
* Click your profile avatar (top right).
* Select Account settings.

<figure><img src="https://295337183-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F9aroNmDWVJAmMjkdy0hx%2Fuploads%2FuldmORcaWpAYO99oEpI4%2Funknown.png?alt=media&amp;token=1375bf9b-6740-48fb-9b37-cd5992682b3f" alt=""><figcaption></figcaption></figure>

* Navigate to Security → Create and manage API tokens.

<figure><img src="https://295337183-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F9aroNmDWVJAmMjkdy0hx%2Fuploads%2FNgnJEbXGC3XTdenpA92X%2Funknown.png?alt=media&amp;token=0a76e2d4-13b7-4e51-8441-3ca2d1e3795a" alt=""><figcaption></figcaption></figure>

* Click Create API token.
* Configure the required permissions.
* Click Create and copy the API token

<figure><img src="https://295337183-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F9aroNmDWVJAmMjkdy0hx%2Fuploads%2FJ25uX9eqxfDFX645H4Y1%2Funknown.png?alt=media&amp;token=477f9607-026c-4bb7-9fe8-f90c164c7a64" alt=""><figcaption></figcaption></figure>

#### Connect Bitbucket to WalnutAI

* Log in to WalnutAI.
* Go to Integrations and select Bitbucket.

<figure><img src="https://295337183-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F9aroNmDWVJAmMjkdy0hx%2Fuploads%2FXHdE7PlU5WlXuMInWhuk%2Funknown.png?alt=media&amp;token=c776baf5-8fe4-44e4-88da-08431701ace1" alt=""><figcaption></figcaption></figure>

* Paste the copied Token, then enter the email ID and username associated with your account.
* Click Validate and Fetch to verify the token and retrieve repository details.

<figure><img src="https://295337183-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F9aroNmDWVJAmMjkdy0hx%2Fuploads%2FR82qocoIr6qNuL547r0W%2Funknown.png?alt=media&amp;token=56d07579-dc2e-4b8c-bac2-34c80f142ad7" alt=""><figcaption></figcaption></figure>

* Select the required repositories and relevant branches.
* Click Connect to complete the integration.
