apache / apache/magpie

feat(tools/bitbucket): Bitbucket forge + tracker bridge (Atlassian)

Open
#606 4 comments 0 reactions 0 assignees View on GitHub
capability:platform enhancement family:tools good first issue source control system
Dominant language
Python
Stars
92
Forks
92
Avg merge
1d 12h
Merged PRs (30d)
104

Description

Add `tools/bitbucket/` as a forge + tracker bridge for **Bitbucket** (Atlassian Cloud and self-hosted Data Center), analogous to `tools/github/` and the `tools/gitlab/` bridge (#305). Bitbucket is a major Git forge with no coverage today, and it has deep **Jira** integration — pairing naturally with the existing `tools/jira/` tracker bridge.

**Capabilities to provide** (mirror the GitHub bridge):

- Issue read/write (Bitbucket issues *and* linked Jira, via `tools/jira/`)
- Pull-request read/write: view/list, create/edit/merge, comment, review/approve
- Repo metadata, branch permissions
- Pipelines read for CI status checks
- Bitbucket Cloud REST API + Data Center REST API (note: the two API flavours differ — abstract behind one bridge)

**Why:** Bitbucket is the default forge across the **Atlassian enterprise ecosystem** and a large share of corporate OSS. It historically hosted **Mercurial** too (dropped in 2020), which is part of why Hg projects scattered — so a Bitbucket bridge plus the Mercurial bridge together recover that displaced population. With Jira already bridged, Bitbucket closes the loop on the full Atlassian adopter stack.

**Reference:**

- Bitbucket Cloud REST API: https://developer.atlassian.com/cloud/bitbucket/rest/
- Bitbucket Data Center REST API: https://developer.atlassian.com/server/bitbucket/rest/
- Existing forge bridges to mirror: [`tools/github/`](../tree/main/tools/github/), `tools/gitlab/` (#305); pairs with [`tools/jira/`](../tree/main/tools/jira/)

Contributor guide

Open the contributing guide

Research direction

Compare the existing tools/github/ and tools/gitlab/ bridges, then review tools/jira/ for the linked tracker integration. Start by checking how forge and tracker capabilities are abstracted across those bridges and how Cloud and Data Center API differences could fit one interface. Done means tools/bitbucket/ provides the listed issue, pull-request, repository, branch-permission, and pipeline capabilities for both Bitbucket API variants.

Written by the indexing model from the issue text.

Assessment

Tech stack
python
Domain
backend-api-design, tooling
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Quiet
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.