Configure Bitbucket Data Center authentication and repository webhooks for OpenHands Enterprise.
This guide explains how to connect Bitbucket Data Center to an OpenHands
Enterprise Replicated installation. The integration lets users sign in with
Bitbucket Data Center, open repositories, and invoke OpenHands from pull request
comments.
Prerequisites
A Bitbucket Data Center administrator who can create an OAuth 2.0 Application
Link.
A currently supported Bitbucket Data Center version with OAuth 2.0 Application
Links enabled. If the application link flow does not show
incoming OAuth 2.0 settings, verify your Bitbucket Data Center version and
application link settings.
Repository administrator access for users who will install repository
webhooks from OpenHands.
Network access from OpenHands to Bitbucket Data Center for API calls, and
from Bitbucket Data Center back to the OpenHands app URL for webhook delivery.
If Bitbucket Data Center uses an internal or self-signed certificate, upload
the issuing CA in the OpenHands Enterprise Admin Console under Additional
Trusted CA Certificates before deploying.
Create a Bitbucket OAuth Application Link
In Bitbucket Data Center, create an OAuth 2.0 Application Link for OpenHands.
The exact menu labels can vary by Bitbucket version, but this is usually under
Administration > Application Links.Use this callback URL, where <your-auth-hostname> is your installation’s
Authentication hostname (auth.<your-openhands-domain> by default):
OpenHands requests the REPO_ADMIN OAuth scope so it can list repositories and
install or refresh repository webhooks from the OpenHands UI. Copy the client ID
and client secret. You will paste them into the OpenHands Enterprise Admin
Console.
REPO_ADMIN is required so OpenHands can list repositories in the UI and
create or refresh the OpenHands Resolver repository webhook. OpenHands does
not perform other repository administration actions.
Create a Bot Token
This step is strongly recommended but technically optional. When a bot token is
configured, OpenHands posts comments and reactions as the bot account instead of
as the user.Create a dedicated Bitbucket Data Center user for OpenHands. For example, create
a user named openhands with an email address such as
openhands-bot@company.com. Grant this user access to all repositories where
OpenHands should post comments or reactions. Then create an HTTP access token
for that user with Repository permissions set to Repository write. Store
the token securely. You will need to paste the HTTP access token into the
OpenHands Enterprise Admin Console.
Configure the Admin Console
Open the Replicated Admin Console for your OpenHands Enterprise installation and
go to the application configuration page.In Bitbucket Data Center Authentication:
Enable Bitbucket Data Center Authentication.
Enter the Bitbucket Data Center Domain.
Enter the Bitbucket Data Center Client ID.
Enter the Bitbucket Data Center Client Secret.
Enter the Bitbucket Data Center Bot Token if you have one.
Save and deploy the updated configuration.
The Bitbucket Data Center Domain must be a bare hostname, for example
bitbucket.example.com. Do not include https://.
Sign In with Bitbucket Data Center
After the deployment is completed, users choose Sign in with Bitbucket Data
Center on your app’s login page.On first sign-in, users may be asked to accept OpenHands terms and complete an
offline access flow. After sign-in, OpenHands stores the user’s Bitbucket Data
Center token so it can list repositories and run resolver jobs as that user.
Install Repository Webhooks
To trigger OpenHands on Bitbucket repositories, repository administrators can
install the OpenHands bot onto a repository from Settings > Integrations
within the OpenHands app. For each repository that should support @openhands
pull request comments, click Install. If a webhook already exists, click
Reinstall to refresh it.OpenHands creates or updates a repository webhook named OpenHands Resolver.
The webhook URL is connection-specific:
OpenHands subscribes the webhook to repository and pull request events,
including pull request comment add, edit, and delete events. The signing secret
is generated and stored by OpenHands.
Trigger OpenHands from Bitbucket Data Center
Open a pull request and add a comment containing @openhands. Inline pull
request comments are also supported.OpenHands starts a resolver job when:
The repository webhook is installed and active.
The webhook delivery signature is valid.
The mentioning Bitbucket user has signed in to OpenHands with Bitbucket Data
Center.
The mentioning user has access to the repository.
The resolver context includes the pull request title, description, current
comments, and the triggering comment. OpenHands replies back to the pull request
when the job starts and when it completes.
Automations
The repository webhook also delivers pull request and repository events to
automations, for example to review every new pull request. Two extra steps are
needed for automations that @openhands mentions do not need:
Claim the Bitbucket project key (for example ENG) for your OpenHands team
organization under Organization Settings > Git Conversation Routing.
If your installation’s only team organization is its default organization,
it receives unclaimed events. Otherwise, unclaimed events are dropped.
Create the automation under that team organization, with Bitbucket Data
Center as the event source and a Bitbucket event key such as pr:opened, or
start from the Bitbucket Data Center code review template in Agent Canvas. GitHub-style
keys such as pull_request.opened never match Bitbucket events.
Setup for OpenHands Enterprise 0.103.0, event keys, and troubleshooting are described in
Data Center Event Automations.
Troubleshooting
Symptom
Check
The Bitbucket Data Center login option is not visible
Confirm Bitbucket Data Center Authentication is enabled in the Admin Console and the deployment has been applied.
OAuth redirects fail
Confirm the callback URL exactly matches https://<your-auth-hostname>/realms/allhands/broker/bitbucket_data_center/endpoint.
Login tries to reach an invalid https://https://... URL
Remove https:// from the Bitbucket Data Center Domain field in the Admin Console.
Repository webhook install fails
Confirm the user has repository admin access and the OAuth app grants REPO_ADMIN.
Webhook delivery reaches OpenHands but no job starts
Confirm the comment contains @openhands, the webhook is installed for that repository, and the mentioning Bitbucket user has signed in to OpenHands.
Webhook delivery reaches OpenHands but an automation does not run
Check the organization routing above, confirm the automation is enabled, and send a new event after changing a claim. See Data Center Event Automations.
OpenHands cannot list Bitbucket repositories or install webhooks
Confirm the OpenHands cluster can reach the Bitbucket Data Center URL.
Bitbucket webhook deliveries do not reach OpenHands
Confirm the Bitbucket Data Center network can reach the OpenHands app URL.
Bitbucket API calls fail with TLS errors
Upload the Bitbucket Data Center CA certificate in Additional Trusted CA Certificates and redeploy.
Was this page helpful?
{"docsConfig":{"theme":"mint","$schema":"https://mintlify.com/docs.json","name":"OpenHands Docs","colors":{"primary":"#99873c","light":"#ffe165","dark":"#ffe165"},"logo":{"light":"https://mintcdn.com/allhandsai/DjhqLcIy_hW6pRTg/logo/light.png?fit=max\u0026auto=format\u0026n=DjhqLcIy_hW6pRTg\u0026q=85\u0026s=49b636402b03f7279ca5e1afefeec1d2","dark":"https://mintcdn.com/allhandsai/DjhqLcIy_hW6pRTg/logo/dark.png?fit=max\u0026auto=format\u0026n=DjhqLcIy_hW6pRTg\u0026q=85\u0026s=e0c4017631cebc3a289798438e2c0d7a"},"favicon":"https://mintcdn.com/allhandsai/DjhqLcIy_hW6pRTg/openhands/logo-square.png?fit=max\u0026auto=format\u0026n=DjhqLcIy_hW6pRTg\u0026q=85\u0026s=6ef1bab575660ae6e2d44fcc57bc675f","appearance":{"default":"light"},"background":{"color":{"light":"#f7f3ee","dark":"#0B0D0E"}},"navbar":{"links":[],"primary":{"type":"github","href":"https://github.com/OpenHands/OpenHands"}},"footer":{"socials":{"slack":"https://openhands.dev/joinslack","github":"https://github.com/OpenHands"},"links":[{"header":"Links","items":[{"label":"Company","href":"https://openhands.dev/"},{"label":"Blog","href":"https://openhands.dev/blog"},{"label":"Cloud","href":"https://app.all-hands.dev"},{"label":"Enterprise","href":"https://openhands.dev/enterprise"}]}]},"seo":{"indexing":"navigable"},"integrations":{"gtm":{"tagId":"GTM-M9S7V5BQ"}},"contextual":{"options":["copy","view","download-spec","chatgpt","claude"],"display":"header"},"styling":{"latex":false},"navigation":{"pages":[]}},"deployment":{"deploymentMetadataValue":{"subdomain":"allhandsai","hasAudioNarration":false,"actualSubdomain":"allhandsai","customDomains":["docs.openhands.dev"],"gitSource":{"type":"github","owner":"openhands","repo":"docs","deployBranch":"main","contentDirectory":"","isPrivate":true,"mountPath":"","label":""},"feedback":{"thumbs":true},"entitlements":{"AI_CHAT":{"status":"ENABLED"},"WEB_MCP":{"status":"ENABLED"},"NARRATION":{"status":"ENABLED"}},"buildId":"6afd9eb7921026410dbb2c59","clientVersion":"0.0.4177","searchFilterCounts":[{"language":"default","tag":"Cloud","count":197},{"language":"default","tag":"Cloud API","count":188},{"language":"default","tag":"REST API Reference","count":186},{"language":"default","tag":"SDK","count":128},{"language":"default","tag":"Guides","count":105},{"language":"default","tag":"API Reference","count":95},{"language":"default","tag":"Enterprise","count":76},{"language":"default","tag":"Agent Canvas","count":66},{"language":"default","tag":"Home","count":58},{"language":"default","tag":"Remote Agent Server","count":55}]},"assistantConfig":{"deflection":{"enabled":true,"email":"contact@openhands.dev","showHelpButton":true}},"basePath":"","hasChatPermissions":true,"hasWebMcpPermissions":true,"toggles":[{"name":"kill-isr","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"custom-rbac-roles","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"agent-mintlify-slack","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"agent-integrations-settings","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"rbac-expansion","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automations-pr-grouping","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"custom-prefix","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"analytics-v7","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"user-flows-analytics","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"no-publish-flow","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-onboarding","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"snapshot-serving-live","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"stripTemperatureMiddleware","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"support-platform-pylon-zendesk","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"snapshot-serving","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"instant-rollback","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"granular-notifications-server","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"granular-notifications","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automations-fable","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"fixed-ai-action-pricing","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automation-resolve-merge-conflict","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"scoped-publishing","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"mintql","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"page-level-analytics","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"editor-version-history-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"billing-page-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"full-page-search","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workspace-projects","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"assistant-v5","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"fork-pr-previews","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"revalidation-jwt","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-sso-scim","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"hobby-abuse-scan","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"dashboard-inbox","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-signup","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"turbopuffer-dual-write","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-enabled","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"approve-review-flow","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"editor-metadata","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"sso-setup-deadline-banner","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"turbopuffer-serve","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"live-agents","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"starter-pricing","enabled":true,"variant":{"name":"treatment","enabled":true,"payload":{"type":"string","value":"treatment"},"feature_enabled":true},"impressionData":false},{"name":"llms-txt-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"wildcard-email-auth","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false}],"googleFontsInlined":false},"customCss":[{"filePath":"style.css","content":"#banner *{color:rgb(67, 66, 64)}.oh-arch{--oh-arch-bg: #fbf9f6;--oh-arch-surface: #f2ede5;--oh-arch-card: #ffffff;--oh-arch-line: #e2dbd0;--oh-arch-text: #1c1b19;--oh-arch-text-secondary: #6b675f;--oh-arch-text-tertiary: #a39e93;--oh-arch-accent: #ffe165;--oh-arch-hover: #99873c;margin:1.5rem 0;border:1px solid var(--oh-arch-line);border-radius:12px;background:var(--oh-arch-bg);color:var(--oh-arch-text);overflow:hidden}.dark .oh-arch{--oh-arch-bg: #111416;--oh-arch-surface: #171b1e;--oh-arch-card: #1c2124;--oh-arch-line: #2d3337;--oh-arch-text: #f1efe9;--oh-arch-text-secondary: #a3a19a;--oh-arch-text-tertiary: #6f726f;--oh-arch-hover: #ffe165}.oh-arch-header{padding:18px 20px 0}.oh-arch-eyebrow,.oh-arch-label{font-family:ui-monospace, SFMono-Regular, Menlo, monospace;font-size:10px;font-weight:500;letter-spacing:0.08em;color:var(--oh-arch-text-secondary);fill:var(--oh-arch-text-secondary)}.oh-arch-eyebrow{text-transform:uppercase}.oh-arch-scroll{overflow-x:auto;scrollbar-width:thin}.oh-arch-diagram{display:block;width:100%;min-width:640px;height:auto}.oh-arch-boundary{fill:var(--oh-arch-surface);stroke:var(--oh-arch-line);stroke-dasharray:5 5}.oh-arch-card{fill:var(--oh-arch-card);stroke:var(--oh-arch-line);transition:stroke 150ms ease}.oh-arch-service:hover .oh-arch-card,.oh-arch-service:focus-visible .oh-arch-card{stroke:var(--oh-arch-hover);stroke-width:2}.oh-arch-service:focus-visible{outline:none}.oh-arch-icon{color:var(--oh-arch-text-secondary)}.oh-arch-name{fill:var(--oh-arch-text);font-size:15px;font-weight:600;letter-spacing:-0.025em}.oh-arch-detail{fill:var(--oh-arch-text-secondary);font-size:12px}.oh-arch-accent{fill:var(--oh-arch-accent)}.oh-arch-app-paths,.oh-arch-worker-paths,.oh-arch-external-paths,.oh-arch-arrows{fill:none;stroke-width:1.5;stroke-linecap:round;stroke-linejoin:round}.oh-arch-app-paths{stroke:var(--oh-arch-text)}.oh-arch-worker-paths,.oh-arch-external-paths,.oh-arch-arrows{stroke:var(--oh-arch-text-tertiary)}.oh-arch-external-paths{stroke-dasharray:4 6}.oh-arch-caption{border-top:1px solid var(--oh-arch-line);padding:16px 20px;font-size:12px;line-height:1.6;color:var(--oh-arch-text-secondary)}.oh-arch-legend{display:flex;flex-wrap:wrap;gap:8px 20px}.oh-arch-legend span{display:flex;align-items:center;gap:8px}.oh-arch-legend i{display:inline-block;width:18px;border-top:2px solid}.oh-arch-key-app{color:var(--oh-arch-text)}.oh-arch-key-worker,.oh-arch-key-external{color:var(--oh-arch-text-tertiary)}.oh-arch-legend .oh-arch-key-external{border-top-style:dashed}.oh-arch-caption p{margin:8px 0 0}@media (prefers-reduced-motion: reduce){.oh-arch-card{transition:none}}"}],"page":{"pagePath":"enterprise/integrations/bitbucket-data-center","slug":"/enterprise/integrations/bitbucket-data-center","pageMetadata":{"title":"Bitbucket Data Center","description":"Configure Bitbucket Data Center authentication and repository webhooks for OpenHands Enterprise.","icon":"code-branch","href":"/enterprise/integrations/bitbucket-data-center"},"description":{"compiledSource":"\"use strict\";\nconst {jsx: _jsx} = arguments[0];\nconst {useMDXComponents: _provideComponents} = arguments[0];\nfunction _createMdxContent(props) {\n const _components = {\n p: \"p\",\n ..._provideComponents(),\n ...props.components\n };\n return _jsx(_components.p, {\n children: \"Configure Bitbucket Data Center authentication and repository webhooks for OpenHands Enterprise.\"\n });\n}\nfunction MDXContent(props = {}) {\n const {wrapper: MDXLayout} = {\n ..._provideComponents(),\n ...props.components\n };\n return MDXLayout ? _jsx(MDXLayout, {\n ...props,\n children: _jsx(_createMdxContent, {\n ...props\n })\n }) : _createMdxContent(props);\n}\nreturn {\n default: MDXContent\n};\n","frontmatter":{},"scope":{}},"pageType":"default","mdx":{"mdxSource":{"compiledSource":"\"use strict\";const{Fragment:_Fragment,jsx:_jsx,jsxs:_jsxs}=arguments[0];const{useMDXComponents:_provideComponents}=arguments[0];function _createMdxContent(props){const _components={a:`a`,code:`code`,li:`li`,ol:`ol`,p:`p`,pre:`pre`,span:`span`,strong:`strong`,tbody:`tbody`,td:`td`,th:`th`,thead:`thead`,tr:`tr`,ul:`ul`,..._provideComponents(),...props.components},{CodeBlock,Heading,Note,OptimizedImage,Table,Warning}=_components;if(!CodeBlock)_missingMdxReference(`CodeBlock`,true);if(!Heading)_missingMdxReference(`Heading`,true);if(!Note)_missingMdxReference(`Note`,true);if(!OptimizedImage)_missingMdxReference(`OptimizedImage`,true);if(!Table)_missingMdxReference(`Table`,true);if(!Warning)_missingMdxReference(`Warning`,true);return _jsxs(_Fragment,{children:[_jsx(_components.p,{children:`This guide explains how to connect Bitbucket Data Center to an OpenHands\nEnterprise Replicated installation. The integration lets users sign in with\nBitbucket Data Center, open repositories, and invoke OpenHands from pull request\ncomments.`}),`\n`,_jsx(Heading,{level:`2`,id:`prerequisites`,children:`Prerequisites`}),`\n`,_jsxs(_components.ul,{children:[`\n`,_jsx(_components.li,{children:`A Bitbucket Data Center administrator who can create an OAuth 2.0 Application\nLink.`}),`\n`,_jsx(_components.li,{children:`A currently supported Bitbucket Data Center version with OAuth 2.0 Application\nLinks enabled. If the application link flow does not show\nincoming OAuth 2.0 settings, verify your Bitbucket Data Center version and\napplication link settings.`}),`\n`,_jsx(_components.li,{children:`Repository administrator access for users who will install repository\nwebhooks from OpenHands.`}),`\n`,_jsx(_components.li,{children:`Network access from OpenHands to Bitbucket Data Center for API calls, and\nfrom Bitbucket Data Center back to the OpenHands app URL for webhook delivery.`}),`\n`,_jsxs(_components.li,{children:[`If Bitbucket Data Center uses an internal or self-signed certificate, upload\nthe issuing CA in the OpenHands Enterprise Admin Console under `,_jsx(_components.strong,{children:`Additional\nTrusted CA Certificates`}),` before deploying.`]}),`\n`]}),`\n`,_jsx(Heading,{level:`2`,id:`create-a-bitbucket-oauth-application-link`,children:`Create a Bitbucket OAuth Application Link`}),`\n`,_jsxs(_components.p,{children:[`In Bitbucket Data Center, create an OAuth 2.0 Application Link for OpenHands.\nThe exact menu labels can vary by Bitbucket version, but this is usually under\n`,_jsx(_components.strong,{children:`Administration > Application Links`}),`.`]}),`\n`,_jsx(OptimizedImage,{src:`https://mintcdn.com/allhandsai/E09zD4bTMinv0C3d/enterprise/images/bitbucket-data-center-application-links.png?fit=max\u0026auto=format\u0026n=E09zD4bTMinv0C3d\u0026q=85\u0026s=84329a6bd7279b26a36c483a1bc1782c`,alt:`Bitbucket Data Center Application Links settings`,\"data-og-width\":`1800`,width:`1800`,\"data-og-height\":`1650`,height:`1650`,\"data-path\":`enterprise/images/bitbucket-data-center-application-links.png`,\"data-optimize\":`true`,\"data-opv\":`3`,srcset:`https://mintcdn.com/allhandsai/E09zD4bTMinv0C3d/enterprise/images/bitbucket-data-center-application-links.png?w=280\u0026fit=max\u0026auto=format\u0026n=E09zD4bTMinv0C3d\u0026q=85\u0026s=2dc23e7a23c8657527a0dce926363673 280w, https://mintcdn.com/allhandsai/E09zD4bTMinv0C3d/enterprise/images/bitbucket-data-center-application-links.png?w=560\u0026fit=max\u0026auto=format\u0026n=E09zD4bTMinv0C3d\u0026q=85\u0026s=3ebaaec349fbbdce3779f319371f93ee 560w, https://mintcdn.com/allhandsai/E09zD4bTMinv0C3d/enterprise/images/bitbucket-data-center-application-links.png?w=840\u0026fit=max\u0026auto=format\u0026n=E09zD4bTMinv0C3d\u0026q=85\u0026s=36cab2196613dae224907dc0b9a3dd58 840w, https://mintcdn.com/allhandsai/E09zD4bTMinv0C3d/enterprise/images/bitbucket-data-center-application-links.png?w=1100\u0026fit=max\u0026auto=format\u0026n=E09zD4bTMinv0C3d\u0026q=85\u0026s=55177819aac972fa559e0f2780fa7493 1100w, https://mintcdn.com/allhandsai/E09zD4bTMinv0C3d/enterprise/images/bitbucket-data-center-application-links.png?w=1650\u0026fit=max\u0026auto=format\u0026n=E09zD4bTMinv0C3d\u0026q=85\u0026s=1169a5b5b0c9e29e6c4b627dd5a70821 1650w, https://mintcdn.com/allhandsai/E09zD4bTMinv0C3d/enterprise/images/bitbucket-data-center-application-links.png?w=2500\u0026fit=max\u0026auto=format\u0026n=E09zD4bTMinv0C3d\u0026q=85\u0026s=9f8b1ebdac87d8801a01353693e8c039 2500w`}),`\n`,_jsxs(_components.p,{children:[`Use this callback URL, where `,_jsx(_components.code,{children:`\u003cyour-auth-hostname>`}),` is your installation’s\nAuthentication hostname (`,_jsx(_components.code,{children:`auth.\u003cyour-openhands-domain>`}),` by default):`]}),`\n`,_jsx(CodeBlock,{filename:``,numberOfLines:`2`,language:`text`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`text`,children:_jsxs(_components.code,{language:`text`,numberOfLines:`2`,children:[_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{children:`https://\u003cyour-auth-hostname>/realms/allhands/broker/bitbucket_data_center/endpoint`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{})})]})})}),`\n`,_jsx(_components.p,{children:`Replace only the hostname. Leave the rest of the path unchanged, for example:`}),`\n`,_jsx(CodeBlock,{filename:``,numberOfLines:`2`,language:`text`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`text`,children:_jsxs(_components.code,{language:`text`,numberOfLines:`2`,children:[_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{children:`https://auth.openhands.example.com/realms/allhands/broker/bitbucket_data_center/endpoint`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{})})]})})}),`\n`,_jsxs(_components.p,{children:[`OpenHands requests the `,_jsx(_components.code,{children:`REPO_ADMIN`}),` OAuth scope so it can list repositories and\ninstall or refresh repository webhooks from the OpenHands UI. Copy the client ID\nand client secret. You will paste them into the OpenHands Enterprise Admin\nConsole.`]}),`\n`,_jsx(Note,{children:_jsxs(_components.p,{children:[_jsx(_components.code,{children:`REPO_ADMIN`}),` is required so OpenHands can list repositories in the UI and\ncreate or refresh the `,_jsx(_components.code,{children:`OpenHands Resolver`}),` repository webhook. OpenHands does\nnot perform other repository administration actions.`]})}),`\n`,_jsx(OptimizedImage,{src:`https://mintcdn.com/allhandsai/E09zD4bTMinv0C3d/enterprise/images/bitbucket-data-center-incoming-link.png?fit=max\u0026auto=format\u0026n=E09zD4bTMinv0C3d\u0026q=85\u0026s=6df9550b9b1941b34eed7791d6b5d6af`,alt:`Bitbucket Data Center incoming OAuth link form`,\"data-og-width\":`1429`,width:`1429`,\"data-og-height\":`1800`,height:`1800`,\"data-path\":`enterprise/images/bitbucket-data-center-incoming-link.png`,\"data-optimize\":`true`,\"data-opv\":`3`,srcset:`https://mintcdn.com/allhandsai/E09zD4bTMinv0C3d/enterprise/images/bitbucket-data-center-incoming-link.png?w=280\u0026fit=max\u0026auto=format\u0026n=E09zD4bTMinv0C3d\u0026q=85\u0026s=53dbe65e0c9a56a475237b25f402171e 280w, https://mintcdn.com/allhandsai/E09zD4bTMinv0C3d/enterprise/images/bitbucket-data-center-incoming-link.png?w=560\u0026fit=max\u0026auto=format\u0026n=E09zD4bTMinv0C3d\u0026q=85\u0026s=7d5c3fc47e948e936349cfc45e42f5f3 560w, https://mintcdn.com/allhandsai/E09zD4bTMinv0C3d/enterprise/images/bitbucket-data-center-incoming-link.png?w=840\u0026fit=max\u0026auto=format\u0026n=E09zD4bTMinv0C3d\u0026q=85\u0026s=c0b9dd37ff3513f19a5a68f1ff87881a 840w, https://mintcdn.com/allhandsai/E09zD4bTMinv0C3d/enterprise/images/bitbucket-data-center-incoming-link.png?w=1100\u0026fit=max\u0026auto=format\u0026n=E09zD4bTMinv0C3d\u0026q=85\u0026s=cbea137c16393f16510f56c818db90a1 1100w, https://mintcdn.com/allhandsai/E09zD4bTMinv0C3d/enterprise/images/bitbucket-data-center-incoming-link.png?w=1650\u0026fit=max\u0026auto=format\u0026n=E09zD4bTMinv0C3d\u0026q=85\u0026s=0abab8bff0b1bff0108b89f141d1b5e1 1650w, https://mintcdn.com/allhandsai/E09zD4bTMinv0C3d/enterprise/images/bitbucket-data-center-incoming-link.png?w=2500\u0026fit=max\u0026auto=format\u0026n=E09zD4bTMinv0C3d\u0026q=85\u0026s=7c4c96f12fed090d71aaf0b7d8752607 2500w`}),`\n`,_jsx(Heading,{level:`2`,id:`create-a-bot-token`,children:`Create a Bot Token`}),`\n`,_jsx(_components.p,{children:`This step is strongly recommended but technically optional. When a bot token is\nconfigured, OpenHands posts comments and reactions as the bot account instead of\nas the user.`}),`\n`,_jsxs(_components.p,{children:[`Create a dedicated Bitbucket Data Center user for OpenHands. For example, create\na user named `,_jsx(_components.code,{children:`openhands`}),` with an email address such as\n`,_jsx(_components.code,{children:`openhands-bot@company.com`}),`. Grant this user access to all repositories where\nOpenHands should post comments or reactions. Then create an HTTP access token\nfor that user with `,_jsx(_components.strong,{children:`Repository permissions`}),` set to `,_jsx(_components.strong,{children:`Repository write`}),`. Store\nthe token securely. You will need to paste the HTTP access token into the\nOpenHands Enterprise Admin Console.`]}),`\n`,_jsx(OptimizedImage,{src:`https://mintcdn.com/allhandsai/E09zD4bTMinv0C3d/enterprise/images/bitbucket-data-center-bot-token.png?fit=max\u0026auto=format\u0026n=E09zD4bTMinv0C3d\u0026q=85\u0026s=246967f74ad051b9a527d99c39552fe6`,alt:`Bitbucket Data Center HTTP access token setup`,\"data-og-width\":`1026`,width:`1026`,\"data-og-height\":`780`,height:`780`,\"data-path\":`enterprise/images/bitbucket-data-center-bot-token.png`,\"data-optimize\":`true`,\"data-opv\":`3`,srcset:`https://mintcdn.com/allhandsai/E09zD4bTMinv0C3d/enterprise/images/bitbucket-data-center-bot-token.png?w=280\u0026fit=max\u0026auto=format\u0026n=E09zD4bTMinv0C3d\u0026q=85\u0026s=dd0fd64de88f3c6a2c75bdb149bee2e2 280w, https://mintcdn.com/allhandsai/E09zD4bTMinv0C3d/enterprise/images/bitbucket-data-center-bot-token.png?w=560\u0026fit=max\u0026auto=format\u0026n=E09zD4bTMinv0C3d\u0026q=85\u0026s=fa46e6bbfcc51ba9e7ca34c322280ead 560w, https://mintcdn.com/allhandsai/E09zD4bTMinv0C3d/enterprise/images/bitbucket-data-center-bot-token.png?w=840\u0026fit=max\u0026auto=format\u0026n=E09zD4bTMinv0C3d\u0026q=85\u0026s=d9897557acccbab3a30707ca1bbcd20e 840w, https://mintcdn.com/allhandsai/E09zD4bTMinv0C3d/enterprise/images/bitbucket-data-center-bot-token.png?w=1100\u0026fit=max\u0026auto=format\u0026n=E09zD4bTMinv0C3d\u0026q=85\u0026s=b42921ad6dc72d57086a3c0b57e955b3 1100w, https://mintcdn.com/allhandsai/E09zD4bTMinv0C3d/enterprise/images/bitbucket-data-center-bot-token.png?w=1650\u0026fit=max\u0026auto=format\u0026n=E09zD4bTMinv0C3d\u0026q=85\u0026s=b31f5a1657e543eaa8130cb5f769b55e 1650w, https://mintcdn.com/allhandsai/E09zD4bTMinv0C3d/enterprise/images/bitbucket-data-center-bot-token.png?w=2500\u0026fit=max\u0026auto=format\u0026n=E09zD4bTMinv0C3d\u0026q=85\u0026s=c130de64bb1f688331eb1209c7281f8e 2500w`}),`\n`,_jsx(Heading,{level:`2`,id:`configure-the-admin-console`,children:`Configure the Admin Console`}),`\n`,_jsx(_components.p,{children:`Open the Replicated Admin Console for your OpenHands Enterprise installation and\ngo to the application configuration page.`}),`\n`,_jsxs(_components.p,{children:[`In `,_jsx(_components.strong,{children:`Bitbucket Data Center Authentication`}),`:`]}),`\n`,_jsxs(_components.ol,{children:[`\n`,_jsxs(_components.li,{children:[`Enable `,_jsx(_components.strong,{children:`Bitbucket Data Center Authentication`}),`.`]}),`\n`,_jsxs(_components.li,{children:[`Enter the `,_jsx(_components.strong,{children:`Bitbucket Data Center Domain`}),`.`]}),`\n`,_jsxs(_components.li,{children:[`Enter the `,_jsx(_components.strong,{children:`Bitbucket Data Center Client ID`}),`.`]}),`\n`,_jsxs(_components.li,{children:[`Enter the `,_jsx(_components.strong,{children:`Bitbucket Data Center Client Secret`}),`.`]}),`\n`,_jsxs(_components.li,{children:[`Enter the `,_jsx(_components.strong,{children:`Bitbucket Data Center Bot Token`}),` if you have one.`]}),`\n`,_jsx(_components.li,{children:`Save and deploy the updated configuration.`}),`\n`]}),`\n`,_jsx(Warning,{children:_jsxs(_components.p,{children:[`The Bitbucket Data Center Domain must be a bare hostname, for example\n`,_jsx(_components.code,{children:`bitbucket.example.com`}),`. Do not include `,_jsx(_components.code,{children:`https://`}),`.`]})}),`\n`,_jsx(Heading,{level:`2`,id:`sign-in-with-bitbucket-data-center`,children:`Sign In with Bitbucket Data Center`}),`\n`,_jsxs(_components.p,{children:[`After the deployment is completed, users choose `,_jsx(_components.strong,{children:`Sign in with Bitbucket Data\nCenter`}),` on your app’s login page.`]}),`\n`,_jsx(_components.p,{children:`On first sign-in, users may be asked to accept OpenHands terms and complete an\noffline access flow. After sign-in, OpenHands stores the user’s Bitbucket Data\nCenter token so it can list repositories and run resolver jobs as that user.`}),`\n`,_jsx(Heading,{level:`2`,id:`install-repository-webhooks`,children:`Install Repository Webhooks`}),`\n`,_jsxs(_components.p,{children:[`To trigger OpenHands on Bitbucket repositories, repository administrators can\ninstall the OpenHands bot onto a repository from `,_jsx(_components.strong,{children:`Settings > Integrations`}),`\nwithin the OpenHands app. For each repository that should support `,_jsx(_components.code,{children:`@openhands`}),`\npull request comments, click `,_jsx(_components.strong,{children:`Install`}),`. If a webhook already exists, click\n`,_jsx(_components.strong,{children:`Reinstall`}),` to refresh it.`]}),`\n`,_jsxs(_components.p,{children:[`OpenHands creates or updates a repository webhook named `,_jsx(_components.code,{children:`OpenHands Resolver`}),`.\nThe webhook URL is connection-specific:`]}),`\n`,_jsx(CodeBlock,{filename:``,numberOfLines:`2`,language:`text`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`text`,children:_jsxs(_components.code,{language:`text`,numberOfLines:`2`,children:[_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{children:`https://app.\u003cyour-openhands-domain>/integration/bitbucket-dc/connections/\u003cconnection-id>/events`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{})})]})})}),`\n`,_jsx(_components.p,{children:`OpenHands subscribes the webhook to repository and pull request events,\nincluding pull request comment add, edit, and delete events. The signing secret\nis generated and stored by OpenHands.`}),`\n`,_jsx(Heading,{level:`2`,id:`trigger-openhands-from-bitbucket-data-center`,children:`Trigger OpenHands from Bitbucket Data Center`}),`\n`,_jsxs(_components.p,{children:[`Open a pull request and add a comment containing `,_jsx(_components.code,{children:`@openhands`}),`. Inline pull\nrequest comments are also supported.`]}),`\n`,_jsx(_components.p,{children:`OpenHands starts a resolver job when:`}),`\n`,_jsxs(_components.ul,{children:[`\n`,_jsx(_components.li,{children:`The repository webhook is installed and active.`}),`\n`,_jsx(_components.li,{children:`The webhook delivery signature is valid.`}),`\n`,_jsx(_components.li,{children:`The mentioning Bitbucket user has signed in to OpenHands with Bitbucket Data\nCenter.`}),`\n`,_jsx(_components.li,{children:`The mentioning user has access to the repository.`}),`\n`]}),`\n`,_jsx(_components.p,{children:`The resolver context includes the pull request title, description, current\ncomments, and the triggering comment. OpenHands replies back to the pull request\nwhen the job starts and when it completes.`}),`\n`,_jsx(Heading,{level:`2`,id:`automations`,children:`Automations`}),`\n`,_jsxs(_components.p,{children:[`The repository webhook also delivers pull request and repository events to\nautomations, for example to review every new pull request. Two extra steps are\nneeded for automations that `,_jsx(_components.code,{children:`@openhands`}),` mentions do not need:`]}),`\n`,_jsxs(_components.ol,{children:[`\n`,_jsxs(_components.li,{children:[`Claim the Bitbucket project key (for example `,_jsx(_components.code,{children:`ENG`}),`) for your OpenHands team\norganization under `,_jsx(_components.strong,{children:`Organization Settings > Git Conversation Routing`}),`.\nIf your installation’s only team organization is its default organization,\nit receives unclaimed events. Otherwise, unclaimed events are dropped.`]}),`\n`,_jsxs(_components.li,{children:[`Create the automation under that team organization, with `,_jsx(_components.strong,{children:`Bitbucket Data\nCenter`}),` as the event source and a Bitbucket event key such as `,_jsx(_components.code,{children:`pr:opened`}),`, or\nstart from the `,_jsx(_components.strong,{children:`Bitbucket Data Center code review`}),` template in Agent Canvas. GitHub-style\nkeys such as `,_jsx(_components.code,{children:`pull_request.opened`}),` never match Bitbucket events.`]}),`\n`]}),`\n`,_jsxs(_components.p,{children:[`Setup for OpenHands Enterprise 0.103.0, event keys, and troubleshooting are described in\n`,_jsx(_components.a,{href:`/enterprise/automations/data-center-events`,children:`Data Center Event Automations`}),`.`]}),`\n`,_jsx(Heading,{level:`2`,id:`troubleshooting`,children:`Troubleshooting`}),`\n`,_jsxs(Table,{children:[_jsx(_components.thead,{children:_jsxs(_components.tr,{children:[_jsx(_components.th,{children:`Symptom`}),_jsx(_components.th,{children:`Check`})]})}),_jsxs(_components.tbody,{children:[_jsxs(_components.tr,{children:[_jsx(_components.td,{children:`The Bitbucket Data Center login option is not visible`}),_jsx(_components.td,{children:`Confirm Bitbucket Data Center Authentication is enabled in the Admin Console and the deployment has been applied.`})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{children:`OAuth redirects fail`}),_jsxs(_components.td,{children:[`Confirm the callback URL exactly matches `,_jsx(_components.code,{children:`https://\u003cyour-auth-hostname>/realms/allhands/broker/bitbucket_data_center/endpoint`}),`.`]})]}),_jsxs(_components.tr,{children:[_jsxs(_components.td,{children:[`Login tries to reach an invalid `,_jsx(_components.code,{children:`https://https://...`}),` URL`]}),_jsxs(_components.td,{children:[`Remove `,_jsx(_components.code,{children:`https://`}),` from the Bitbucket Data Center Domain field in the Admin Console.`]})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{children:`Repository webhook install fails`}),_jsxs(_components.td,{children:[`Confirm the user has repository admin access and the OAuth app grants `,_jsx(_components.code,{children:`REPO_ADMIN`}),`.`]})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{children:`Webhook delivery reaches OpenHands but no job starts`}),_jsxs(_components.td,{children:[`Confirm the comment contains `,_jsx(_components.code,{children:`@openhands`}),`, the webhook is installed for that repository, and the mentioning Bitbucket user has signed in to OpenHands.`]})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{children:`Webhook delivery reaches OpenHands but an automation does not run`}),_jsxs(_components.td,{children:[`Check the organization routing above, confirm the automation is enabled, and send a new event after changing a claim. See `,_jsx(_components.a,{href:`/enterprise/automations/data-center-events#troubleshooting`,children:`Data Center Event Automations`}),`.`]})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{children:`OpenHands cannot list Bitbucket repositories or install webhooks`}),_jsx(_components.td,{children:`Confirm the OpenHands cluster can reach the Bitbucket Data Center URL.`})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{children:`Bitbucket webhook deliveries do not reach OpenHands`}),_jsx(_components.td,{children:`Confirm the Bitbucket Data Center network can reach the OpenHands app URL.`})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{children:`Bitbucket API calls fail with TLS errors`}),_jsxs(_components.td,{children:[`Upload the Bitbucket Data Center CA certificate in `,_jsx(_components.strong,{children:`Additional Trusted CA Certificates`}),` and redeploy.`]})]})]})]})]})}function MDXContent(props={}){const{wrapper:MDXLayout}={..._provideComponents(),...props.components};return MDXLayout?_jsx(MDXLayout,{...props,children:_jsx(_createMdxContent,{...props})}):_createMdxContent(props)}return{default:MDXContent};function _missingMdxReference(id,component){throw new Error(`Expected `+(component?`component`:`object`)+\" `\"+id+\"` to be defined: you likely forgot to import, pass, or provide it.\")}","frontmatter":{},"scope":{"config":{},"pageMetadata":{"title":"Bitbucket Data Center","description":"Configure Bitbucket Data Center authentication and repository webhooks for OpenHands Enterprise.","icon":"code-branch","href":"/enterprise/integrations/bitbucket-data-center"}}},"mdxSourceWithNoJs":null},"mdxExtracts":{"tableOfContents":[{"title":"Prerequisites","slug":"prerequisites","depth":2,"children":[]},{"title":"Create a Bitbucket OAuth Application Link","slug":"create-a-bitbucket-oauth-application-link","depth":2,"children":[]},{"title":"Create a Bot Token","slug":"create-a-bot-token","depth":2,"children":[]},{"title":"Configure the Admin Console","slug":"configure-the-admin-console","depth":2,"children":[]},{"title":"Sign In with Bitbucket Data Center","slug":"sign-in-with-bitbucket-data-center","depth":2,"children":[]},{"title":"Install Repository Webhooks","slug":"install-repository-webhooks","depth":2,"children":[]},{"title":"Trigger OpenHands from Bitbucket Data Center","slug":"trigger-openhands-from-bitbucket-data-center","depth":2,"children":[]},{"title":"Automations","slug":"automations","depth":2,"children":[]},{"title":"Troubleshooting","slug":"troubleshooting","depth":2,"children":[]}],"codeExamples":{}},"jsLinks":["/_mintlify/custom/allhandsai/dddab338317a519d/openhands/reo-init.js","/_mintlify/custom/allhandsai/ae719f15d762e1fe/openhands/posthog-init.js","/_mintlify/custom/allhandsai/b35f7f3c3c83fb4c/openhands/canvas-handoff.js","/_mintlify/custom/allhandsai/771d6371c43b73b7/openhands/linkedin-copy-tracking.js","/_mintlify/custom/allhandsai/46724455a27ebfc6/openhands/copy-click-tracking.js"],"subdomain":"allhandsai","siteName":"OpenHands Docs","title":"Bitbucket Data Center - OpenHands Docs","navMaps":{"firstHrefInVersion":{},"firstHrefInLanguage":{}},"lastModified":"2026-11-17T14:54:42.169Z","originalFileLocation":"enterprise/integrations/bitbucket-data-center.mdx"},"headHtml":"\u003cscript data-mint-head>(function(){var d=document.documentElement,p=null;if(!p){try{p=localStorage.getItem(\"isDarkMode\")}catch(e){}if(p==='true')p='dark';else if(p==='false')p='light';if(p!=='light'\u0026\u0026p!=='dark'\u0026\u0026p!=='system')p=\"light\"}var r=p==='system'?(matchMedia(\"(prefers-color-scheme: dark)\").matches?'dark':'light'):p;d.classList.remove(r==='dark'?'light':'dark');d.classList.add(r);d.setAttribute(\"data-theme-preference\",p)})();\u003c/script>\u003cmeta data-mint-head name=\"description\" content=\"Configure Bitbucket Data Center authentication and repository webhooks for OpenHands Enterprise.\">\u003cmeta data-mint-head name=\"application-name\" content=\"OpenHands Docs\">\u003cmeta data-mint-head name=\"generator\" content=\"Mintlify\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"192x192\" href=\"/mintlify-assets/_mintlify/favicons/allhandsai/NJyVpY-OoVetrcKF/_generated/favicon/android-chrome-192x192.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"apple-touch-icon\" type=\"image/png\" sizes=\"180x180\" href=\"/mintlify-assets/_mintlify/favicons/allhandsai/NJyVpY-OoVetrcKF/_generated/favicon/apple-touch-icon.png\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"16x16\" href=\"/mintlify-assets/_mintlify/favicons/allhandsai/NJyVpY-OoVetrcKF/_generated/favicon/favicon-16x16.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"32x32\" href=\"/mintlify-assets/_mintlify/favicons/allhandsai/NJyVpY-OoVetrcKF/_generated/favicon/favicon-32x32.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"shortcut icon\" type=\"image/x-icon\" href=\"/mintlify-assets/_mintlify/favicons/allhandsai/NJyVpY-OoVetrcKF/_generated/favicon/favicon.ico\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"192x192\" href=\"/mintlify-assets/_mintlify/favicons/allhandsai/NJyVpY-OoVetrcKF/_generated/favicon-dark/android-chrome-192x192.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"16x16\" href=\"/mintlify-assets/_mintlify/favicons/allhandsai/NJyVpY-OoVetrcKF/_generated/favicon-dark/favicon-16x16.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"32x32\" href=\"/mintlify-assets/_mintlify/favicons/allhandsai/NJyVpY-OoVetrcKF/_generated/favicon-dark/favicon-32x32.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"shortcut icon\" type=\"image/x-icon\" href=\"/mintlify-assets/_mintlify/favicons/allhandsai/NJyVpY-OoVetrcKF/_generated/favicon-dark/favicon.ico\" media=\"(prefers-color-scheme: dark)\">\u003cmeta data-mint-head property=\"og:title\" content=\"Bitbucket Data Center - OpenHands Docs\">\u003cmeta data-mint-head property=\"og:description\" content=\"Configure Bitbucket Data Center authentication and repository webhooks for OpenHands Enterprise.\">\u003cmeta data-mint-head property=\"og:site_name\" content=\"OpenHands Docs\">\u003cmeta data-mint-head property=\"og:url\" content=\"https://docs.openhands.dev/enterprise/integrations/bitbucket-data-center\">\u003cmeta data-mint-head property=\"og:type\" content=\"website\">\u003cmeta data-mint-head property=\"og:image\" content=\"https://allhandsai.mintlify.site/_mintlify/api/og/v2?division=Source+Control\u0026amp;title=Bitbucket+Data+Center\u0026amp;description=Configure+Bitbucket+Data+Center+authentication+and+repository+webhooks+for+OpenHands+Enterprise.\u0026amp;theme=2eb43b0b1453a2072ec6e8c0\u0026amp;signature=d827fd244b11aa2dc225971d4ff9aabe0f54c5ca5dc7f6fa4c5fbd699bc3e217\">\u003cmeta data-mint-head property=\"og:image:width\" content=\"1200\">\u003cmeta data-mint-head property=\"og:image:height\" content=\"630\">\u003cmeta data-mint-head name=\"twitter:card\" content=\"summary_large_image\">\u003cmeta data-mint-head name=\"twitter:title\" content=\"Bitbucket Data Center - OpenHands Docs\">\u003cmeta data-mint-head name=\"twitter:description\" content=\"Configure Bitbucket Data Center authentication and repository webhooks for OpenHands Enterprise.\">\u003cmeta data-mint-head name=\"twitter:image\" content=\"https://allhandsai.mintlify.site/_mintlify/api/og/v2?division=Source+Control\u0026amp;title=Bitbucket+Data+Center\u0026amp;description=Configure+Bitbucket+Data+Center+authentication+and+repository+webhooks+for+OpenHands+Enterprise.\u0026amp;theme=2eb43b0b1453a2072ec6e8c0\u0026amp;signature=d827fd244b11aa2dc225971d4ff9aabe0f54c5ca5dc7f6fa4c5fbd699bc3e217\">\u003cmeta data-mint-head name=\"twitter:image:width\" content=\"1200\">\u003cmeta data-mint-head name=\"twitter:image:height\" content=\"630\">\u003cmeta data-mint-head name=\"msapplication-config\" content=\"/mintlify-assets/_mintlify/favicons/allhandsai/NJyVpY-OoVetrcKF/_generated/favicon/browserconfig.xml\">\u003cmeta data-mint-head name=\"apple-mobile-web-app-title\" content=\"OpenHands Docs\">\u003cmeta data-mint-head name=\"msapplication-TileColor\" content=\"#99873c\">\u003clink data-mint-head rel=\"canonical\" href=\"https://docs.openhands.dev/enterprise/integrations/bitbucket-data-center\">\u003clink data-mint-head rel=\"alternate\" type=\"application/xml\" href=\"/sitemap.xml\">\u003clink data-mint-head rel=\"alternate\" type=\"text/markdown\" href=\"/enterprise/integrations/bitbucket-data-center.md\">\u003cscript data-mint-head type=\"application/ld+json\">{\"@context\":\"https://schema.org\",\"@graph\":[{\"@type\":\"Organization\",\"@id\":\"https://docs.openhands.dev/#organization\",\"name\":\"OpenHands Docs\",\"url\":\"https://docs.openhands.dev\",\"logo\":{\"@type\":\"ImageObject\",\"url\":\"https://mintcdn.com/allhandsai/DjhqLcIy_hW6pRTg/logo/light.png?fit=max\u0026auto=format\u0026n=DjhqLcIy_hW6pRTg\u0026q=85\u0026s=49b636402b03f7279ca5e1afefeec1d2\"}},{\"@type\":\"WebSite\",\"@id\":\"https://docs.openhands.dev#website\",\"name\":\"OpenHands Docs\",\"url\":\"https://docs.openhands.dev\",\"publisher\":{\"@id\":\"https://docs.openhands.dev/#organization\"}},{\"@type\":\"WebPage\",\"@id\":\"https://docs.openhands.dev/enterprise/integrations/bitbucket-data-center#webpage\",\"url\":\"https://docs.openhands.dev/enterprise/integrations/bitbucket-data-center\",\"name\":\"Bitbucket Data Center\",\"description\":\"Configure Bitbucket Data Center authentication and repository webhooks for OpenHands Enterprise.\",\"dateModified\":\"2026-11-17T14:54:42.169Z\",\"isPartOf\":{\"@id\":\"https://docs.openhands.dev#website\"},\"breadcrumb\":{\"@id\":\"https://docs.openhands.dev/enterprise/integrations/bitbucket-data-center#breadcrumb\"}},{\"@type\":\"BreadcrumbList\",\"@id\":\"https://docs.openhands.dev/enterprise/integrations/bitbucket-data-center#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Integrations\",\"item\":\"https://docs.openhands.dev/enterprise/integrations/overview\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Source Control\",\"item\":\"https://docs.openhands.dev/enterprise/integrations/github\"},{\"@type\":\"ListItem\",\"position\":3,\"name\":\"Bitbucket Data Center\",\"item\":\"https://docs.openhands.dev/enterprise/integrations/bitbucket-data-center\"}]},{\"@type\":[\"Article\",\"TechArticle\"],\"@id\":\"https://docs.openhands.dev/enterprise/integrations/bitbucket-data-center#article\",\"headline\":\"Bitbucket Data Center\",\"name\":\"Bitbucket Data Center\",\"description\":\"Configure Bitbucket Data Center authentication and repository webhooks for OpenHands Enterprise.\",\"url\":\"https://docs.openhands.dev/enterprise/integrations/bitbucket-data-center\",\"mainEntityOfPage\":{\"@id\":\"https://docs.openhands.dev/enterprise/integrations/bitbucket-data-center#webpage\"},\"dateModified\":\"2026-11-17T14:54:42.169Z\",\"publisher\":{\"@id\":\"https://docs.openhands.dev/#organization\"},\"isPartOf\":{\"@id\":\"https://docs.openhands.dev#website\"}}]}\u003c/script>\u003cscript data-mint-head type=\"application/ld+json\">{\"@context\":\"https://schema.org\",\"@type\":\"WebSite\",\"name\":\"OpenHands Docs\",\"publisher\":{\"@type\":\"Organization\",\"name\":\"OpenHands Docs\"},\"provider\":{\"@type\":\"Organization\",\"name\":\"Mintlify\",\"url\":\"https://mintlify.com\"}}\u003c/script>","agentPointerHref":"/enterprise/integrations/bitbucket-data-center.md","siteName":"OpenHands Docs","nav":{"global":null,"tabs":[{"tab":"Home","pages":[{"title":"Home","href":"/overview/introduction"}]},{"tab":"Agent Canvas","pages":[{"title":"Agent Canvas","href":"/openhands/usage/agent-canvas/overview"}]},{"tab":"SDK","pages":[{"title":"SDK","href":"/sdk"}]},{"tab":"Cloud","pages":[{"title":"Cloud","href":"/openhands/usage/cloud/openhands-cloud"}]},{"tab":"Enterprise","pages":[{"group":"Get Started","pages":[{"title":"Overview","icon":"map","href":"/enterprise/overview"},{"group":"Why Enterprise","icon":"building","root":{"title":"OpenHands Enterprise","icon":"building","href":"/enterprise/index"},"pages":[{"title":"Enterprise vs. Open Source","sidebarTitle":"Enterprise vs. OSS","icon":"scale-balanced","href":"/enterprise/enterprise-vs-oss"}]},{"title":"Architecture","icon":"sitemap","href":"/enterprise/architecture"}]},{"group":"Deployment","pages":[{"group":"Compose","icon":"docker","root":{"title":"Docker Compose","icon":"docker","href":"/enterprise/docker-compose"},"pages":[{"title":"Run on a VM with HTTPS","sidebarTitle":"VM with HTTPS","icon":"lock","href":"/enterprise/docker-compose/https"},{"title":"Serve with ngrok","sidebarTitle":"ngrok","icon":"globe","href":"/enterprise/docker-compose/ngrok"}]},{"group":"Kubernetes","icon":"dharmachakra","root":{"title":"Kubernetes Installation","icon":"dharmachakra","href":"/enterprise/k8s-install/index"},"pages":[{"group":"Cloud Providers","icon":"cloud","pages":[{"title":"Amazon EKS","icon":"aws","href":"/enterprise/k8s-install/eks"},{"title":"Azure AKS","icon":"https://mintlify.s3.us-west-1.amazonaws.com/allhandsai/enterprise/images/azure-logo.svg","href":"/enterprise/k8s-install/aks"},{"title":"Google GKE","icon":"cloud","href":"/enterprise/k8s-install/gke"}]},{"title":"Installing Sysbox","sidebarTitle":"Sysbox","icon":"cube","href":"/enterprise/k8s-install/sysbox"},{"title":"DNS and TLS","icon":"lock","href":"/enterprise/k8s-install/dns-and-tls"},{"title":"Install with Helm","sidebarTitle":"Install with Helm","icon":"ship","href":"/enterprise/k8s-install/installation"},{"title":"Resource Limits","icon":"gauge-high","href":"/enterprise/k8s-install/resource-limits"},{"title":"Enable Automations with Helm","sidebarTitle":"Automations","icon":"clock","href":"/enterprise/k8s-install/automations"},{"title":"Upgrade Guidance","icon":"circle-up","href":"/enterprise/k8s-install/upgrade-guidance"}]},{"group":"VM Install","icon":"server","pages":[{"title":"Generic VM Quick Start","sidebarTitle":"Generic VM","icon":"server","href":"/enterprise/vm-install/generic-vm"},{"title":"AWS Quick Start","sidebarTitle":"AWS","icon":"aws","href":"/enterprise/vm-install/aws"},{"title":"Google Cloud Quick Start","sidebarTitle":"Google Cloud","icon":"google","href":"/enterprise/vm-install/google"},{"title":"Azure Quick Start","sidebarTitle":"Azure","icon":"microsoft","href":"/enterprise/vm-install/azure"},{"title":"Admin Console Configuration","sidebarTitle":"Admin Console","icon":"sliders","href":"/enterprise/vm-install/admin-console-configuration"},{"title":"Log Collection","icon":"file-lines","href":"/enterprise/vm-install/log-collection"},{"title":"Scaling the Cluster","sidebarTitle":"Scaling","icon":"server","href":"/enterprise/vm-install/scaling"}]},{"title":"Sizing Guide","icon":"ruler","href":"/enterprise/sizing-guide"}]},{"group":"Configuration","pages":[{"title":"Environment Variables","icon":"sliders","href":"/enterprise/environment-variables"},{"group":"Authentication (SSO)","icon":"shield-check","pages":[{"title":"SAML SSO","icon":"user-shield","href":"/enterprise/integrations/saml-sso"},{"title":"Authentik","icon":"key","href":"/enterprise/integrations/saml-providers/authentik"}]},{"group":"LLM Gateways","icon":"route","root":{"title":"External LLM Gateways","icon":"network-wired","href":"/enterprise/integrations/external-llm-gateways"},"pages":[{"title":"Azure LLM Gateway","sidebarTitle":"Azure","icon":"https://mintlify.s3.us-west-1.amazonaws.com/allhandsai/enterprise/images/azure-logo.svg","href":"/enterprise/integrations/azure-llm-gateway"},{"title":"AWS Bedrock LLM Gateway","sidebarTitle":"AWS Bedrock","icon":"cloud","href":"/enterprise/integrations/aws-bedrock-llm-gateway"},{"title":"Google LLM Gateway","sidebarTitle":"Google","icon":"google","href":"/enterprise/integrations/google-llm-gateway"}]},{"group":"Custom Sandbox Images","icon":"box","root":{"title":"Custom Sandbox Images","icon":"box","href":"/enterprise/custom-sandbox-images/index"},"pages":[{"title":"Building a Custom Sandbox Image","sidebarTitle":"Building Images","icon":"docker","href":"/enterprise/custom-sandbox-images/building-custom-images"},{"title":"Configuring Custom Sandbox Images","sidebarTitle":"Multiple Images","icon":"layer-group","href":"/enterprise/custom-sandbox-images/multiple-images-warm-pools"},{"title":"Single Image via Admin Console","sidebarTitle":"Admin Console","icon":"triangle-exclamation","href":"/enterprise/custom-sandbox-images/single-image-admin-console"},{"title":"Using Custom Images","sidebarTitle":"Using Images","icon":"play","href":"/enterprise/custom-sandbox-images/using-custom-images"}]},{"title":"Running Docker in the Agent Sandbox","sidebarTitle":"Docker in the Sandbox","icon":"docker","href":"/enterprise/docker-in-sandbox"},{"title":"External PostgreSQL","icon":"database","href":"/enterprise/external-postgres"},{"group":"Observability","icon":"chart-line","pages":[{"title":"Analytics","icon":"rocket","href":"/enterprise/analytics"},{"title":"External Observability Platforms","sidebarTitle":"External Platforms","icon":"chart-line","href":"/enterprise/integrations/observability-platforms"}]}]},{"group":"Integrations","pages":[{"title":"Integrations Overview","sidebarTitle":"Overview","icon":"puzzle-piece","href":"/enterprise/integrations/overview"},{"group":"Source Control","icon":"code-branch","pages":[{"title":"GitHub","icon":"github","href":"/enterprise/integrations/github"},{"title":"GitLab","icon":"code-branch","href":"/enterprise/integrations/gitlab"},{"title":"Azure DevOps","description":"Configure Azure DevOps authentication and automation triggers for OpenHands Enterprise.","icon":"code-branch","href":"/enterprise/integrations/azure-devops"},{"title":"Bitbucket Data Center","icon":"code-branch","href":"/enterprise/integrations/bitbucket-data-center"}]},{"group":"Project Management","icon":"list-check","pages":[{"title":"Jira Cloud","description":"Configure Jira Cloud for OpenHands Enterprise.","icon":"cloud","href":"/enterprise/integrations/jira-cloud"},{"title":"Jira Data Center","icon":"building","href":"/enterprise/integrations/jira-data-center"}]},{"title":"Slack","icon":"slack","href":"/enterprise/integrations/slack"}]},{"group":"Features","pages":[{"title":"Conversations And Sandboxes","sidebarTitle":"Conversations","icon":"boxes-stacked","href":"/enterprise/conversations-and-sandboxes"},{"group":"Automations","icon":"bolt","root":{"title":"Automations","icon":"bolt","href":"/enterprise/automations"},"pages":[{"title":"Service Accounts","icon":"robot","href":"/enterprise/automations/service-accounts"},{"title":"GitHub Event Automations","icon":"github","href":"/enterprise/automations/github-events"},{"title":"Jira and Bitbucket Data Center Event Automations","icon":"building","href":"/enterprise/automations/data-center-events"}]},{"title":"Secrets Management","icon":"key","href":"/enterprise/secrets-management"},{"title":"Skills and Plugins","icon":"puzzle-piece","href":"/enterprise/skills-and-plugins"},{"title":"Plugin Marketplace","icon":"store","href":"/enterprise/plugin-marketplace"},{"group":"Organizations","icon":"building","pages":[{"title":"Organizations Overview","sidebarTitle":"Overview","href":"/openhands/usage/cloud/organizations/overview"},{"title":"Configuring Organizations","sidebarTitle":"Configuration","href":"/openhands/usage/cloud/organizations/configuring-organizations"},{"title":"Managing Members","sidebarTitle":"Members","href":"/openhands/usage/cloud/organizations/managing-members"},{"title":"Roles and Permissions","href":"/openhands/usage/cloud/organizations/roles-permissions"},{"title":"Organization Settings","sidebarTitle":"Settings","href":"/openhands/usage/cloud/organizations/settings"},{"title":"Budgets and Usage","sidebarTitle":"Budgets and Usage","href":"/openhands/usage/cloud/organizations/budgets"}]}]},{"group":"Administration","pages":[{"title":"Super Admin Dashboard","sidebarTitle":"Super Admin","icon":"user-shield","href":"/enterprise/super-admin"},{"title":"Troubleshooting","icon":"life-ring","href":"/enterprise/troubleshooting"},{"group":"Release Notes","icon":"rocket","pages":[{"title":"OpenHands Enterprise 0.110.0","href":"/enterprise/release-notes/0.110.0"},{"title":"OpenHands Enterprise 0.105.0","href":"/enterprise/release-notes/0.105.0"},{"title":"OpenHands Enterprise 0.103.0","href":"/enterprise/release-notes/0.103.0"},{"title":"OpenHands Enterprise 0.90.1","href":"/enterprise/release-notes/0.90.1"},{"title":"OpenHands Enterprise 0.81.0","href":"/enterprise/release-notes/0.81.0"},{"title":"OpenHands Enterprise 0.76.0","href":"/enterprise/release-notes/0.76.0"},{"title":"OpenHands Enterprise 0.74.0","href":"/enterprise/release-notes/0.74.0"},{"title":"OpenHands Enterprise 0.71.1","href":"/enterprise/release-notes/0.71.1"},{"title":"OpenHands Enterprise 0.70.0","href":"/enterprise/release-notes/0.70.0"},{"title":"OpenHands Enterprise 0.64.0","href":"/enterprise/release-notes/0.64.0"},{"title":"OpenHands Enterprise 0.55.0","href":"/enterprise/release-notes/0.55.0"},{"title":"OpenHands Enterprise 0.45.0","href":"/enterprise/release-notes/0.45.0"},{"title":"OpenHands Enterprise 0.41.0","href":"/enterprise/release-notes/0.41.0"},{"title":"OpenHands Enterprise 0.36.1","href":"/enterprise/release-notes/0.36.1"},{"title":"OpenHands Enterprise 0.36.0","href":"/enterprise/release-notes/0.36.0"},{"title":"OpenHands Enterprise 0.28.0","href":"/enterprise/release-notes/0.28.0"},{"title":"OpenHands Enterprise 0.24.0","href":"/enterprise/release-notes/0.24.0"}]}]}]},{"tab":"Enterprise Cookbook","pages":[{"title":"Enterprise Cookbook","href":"/cookbook"}]}]},"basePath":"","title":"Bitbucket Data Center - OpenHands Docs","deploymentId":"dpl_HhUetB7eHHDAmK9T1Teip38TgFx9","buildId":"dpl_HhUetB7eHHDAmK9T1Teip38TgFx9","dynamics":["a74be98ba7"],"chunks":["zoom-image-lightbox-DQG3o8Eu.js","lightbox-handle-r17bVUz3.js"]}