BitBucket Cloud setup

Tags: Flow

Below is a step-by-step guide on how to integrate with BitBucket Cloud. You can connect your account via OAuth or username and password.

Important: Use a service account to create this integration. Learn more about creating a service account.

Who can use this?

 Core
Plus
 
  


Git host permission requirements

Flow only requires read access to your repositories. Flow needs this permission process the metadata used to generate our reports.

The account used to connect Flow to BitBucket must have these read scopes:

  • Repository
  • Issue
  • Pull Request
  • Account

Note: In order to use all services, repos, PRs, tickets, and webhooks when integrating with Flow, the service account needs to be an admin in BitBucket.

back to top


Connect via OAuth

Connecting via OAuth is the fastest and easiest method to connect your repos and import your data, including pull requests and tickets.

  1. From your Flow homepage, go to the top navigation bar and click Settings. Using the left hand navigation under Integrations, click Integrations.
  2. Click the Add Integration button in the top right hand corner of the Integrations page.
  3. On the following page, select BitBucket from the integration provider list.
  4. Under the OAuth tab, click Connect to BitBucket.
  5. If you're already logged into your BitBucket account, a pop-up will appear prompting you to confirm access.

    Note: If you're not already logged in, you'll be prompted to log in and authorize the connection.

  6. If the connection was successful you'll see the following message:
  7. Once you have successfully connected, proceed to the Finishing up section of this article to complete the integration process.

back to top


Connect via username and password

To connect via your BitBucket username and password, follow these steps:

  1. Input your username and password, then click Test connection.
  2. If the connection was successful, you'll see the following message:

Two-factor authentication

Currently, two factor authentication is not supported via username and password logins.

If you try and connect via two factor authentication, you'll see the following message:

If your account has two-factor authentication enabled, you'll need to use an app password as your password.

To set up an app password for your service account:

  1. Navigate to your BitBucket settings
  2. Click app passwords
  3. Select the following permissions:
    • Account: Read
    • Repositories: Read
    • Pull requests: Read
    • Issues: Read

These permissions allow Flow to use all services and webhooks.

Once complete, click Create. You may now use the newly created app password in the Password field in Flow.

back to top


Finishing up

Once you have a successful connection, you can finalize your integration and begin importing repos as outlined below:

  1. Click Next from the BitBucket Authentication Method screen.
  2. On the next screen, select the services you want turned on. Then click Next. Leaving all three services on allows Flow to ingest ticket data, pull request data, and repo data. You can turn services on and off at any time.
  3. Name your integration so you can identify the connected account. Then click Create.
  4. Once you've successfully created a new BitBucket cloud integration, you'll see the below message.
  5. If you see all the appropriate groups and projects under the Repos tab, Flow has the correct access to any repos associated with these projects. To begin importing repos, click the repo import page link.

To learn more about managing your new integration settings, see Managing integrations.

back to top


If you need help, please contact Pluralsight Support.