Skip to main content

Bitbucket Connection

The Bitbucket connection type enables automations to interact with Bitbucket repositories — reading branches and commits, managing pull requests, and triggering pipelines. It supports both Bitbucket Cloud and Bitbucket Data Center.

Connection Details

PropertyValue
Type IDBITBUCKET
CategoryVersion Control Systems
TestableYes

Friendly Example

What you enterExample
Connection nameBitbucket - App Repository
Used forReading branch status and pull request approvals before a deployment workflow
Main details to collectBitbucket username, app password, and workspace name
Best person to provide itRepository or workspace administrator

After it is saved, workflow builders select Bitbucket - App Repository in a node instead of entering these details again.

Mandatory Fields

FieldWhat It MeansExample
usernameThe Bitbucket account username (not email address) that owns the app password.jsmith
appPasswordA Bitbucket app password created for the account. Encrypted at rest. Regular account passwords are not accepted.ATBBxxxxxxxxxxxxxxxxxxxx
workspaceThe Bitbucket workspace slug — the short identifier that appears in repository URLs.acme-corp
info

Bitbucket Cloud uses app passwords, not your regular account password. App passwords are scoped credential tokens that can be revoked independently of your login password.

Advanced Fields

FieldWhat It MeansExample
baseUrlBase URL of the Bitbucket instance. Only set this for Bitbucket Data Center (self-hosted). Leave blank for Bitbucket Cloud.https://bitbucket.yourcompany.com

App Password Permission Reference

Permission AreaAccess LevelWhen You Need It
RepositoriesReadReading branches, commits, file contents
RepositoriesWriteCreating branches, pushing commits
Pull requestsReadReading PR details and approval status
Pull requestsWriteCreating or updating pull requests
WebhooksRead/WriteManaging webhook registrations via automation

Setup Instructions

  1. Sign in to Bitbucket Cloud and click your avatar in the bottom-left corner, then select Personal settings.

  2. In the left sidebar under Security, select App passwords, then click Create app password.

  3. Name the app password descriptively (e.g., qinfinite-automation) and select the permissions the automation requires:

    • Check Repositories — Read and Repositories — Write if the automation reads or modifies repository contents.
    • Check Pull requests — Read (and Write if needed).
  4. Click Create and copy the app password immediately. Bitbucket shows it only once.

  5. Identify your workspace slug — it is the short name that appears in Bitbucket repository URLs after bitbucket.org/ (for example, in bitbucket.org/acme-corp/my-repo, the workspace is acme-corp).

  6. Create the connection in the Global Configurator using the username, app password, and workspace slug. Test the connection to confirm that the credentials have the expected access.

caution

Do not use your Bitbucket account password in the appPassword field. Bitbucket Cloud rejects account passwords for API access. Always create a dedicated app password.

Troubleshooting

SymptomLikely Cause
401 UnauthorizedThe app password was entered incorrectly, has been revoked, or the username does not match the account that owns the app password
403 Forbidden on a repositoryThe app password does not have the required Repositories permission, or the workspace member does not have access to that repository
404 Not Found for a workspaceThe workspace slug is wrong — check the URL of any repository in that workspace
Connection test fails for Data CenterThe baseUrl is unreachable or the instance uses a self-signed TLS certificate