# JaviMaligno/mcp-server-bitbucket [Health: Active]

**Category:** 🔄 Version Control  
**Repository:** https://github.com/JaviMaligno/mcp-server-bitbucket  
**GitHub Stars:** 2  
**npm Downloads (last month):** 176  
**Views:** 3  
**Installs:** 0  
**Upvotes:** 0  
**Directory Page:** https://allmcps.com/mcp/javimaligno-mcp-server-bitbucket

## Description
Bitbucket MCP server with 58 tools for repository management, PRs, pipelines, branches, commits, deployments, webhooks, tags, branch restrictions, and source browsing.

## Tools
Capabilities this server exposes over MCP:

- **list_repositories** — List and search repositories
- **get_repository** — Get repository details
- **create_repository** — Create a new repository
- **delete_repository** — Delete a repository
- **update_repository** — Update repo settings
- **list_pull_requests** — List PRs
- **get_pull_request** — Get PR details
- **create_pull_request** — Create a new PR
- **merge_pull_request** — Merge a PR
- **approve_pr** — Approve a PR
- **unapprove_pr** — Remove approval
- **request_changes_pr** — Request changes
- **decline_pr** — Decline a PR
- **list_pr_comments** — List comments
- **add_pr_comment** — Add comment
- **get_pr_diff** — Get the diff
- **list_pipelines** — List recent runs
- **get_pipeline** — Get status
- **get_pipeline_logs** — View logs
- **trigger_pipeline** — Trigger a run (supports custom pipelines and commit triggers)
- **stop_pipeline** — Stop pipeline
- **list_pipeline_variables** — List variables
- **get_pipeline_variable** — Get variable
- **create_pipeline_variable** — Create variable
- **update_pipeline_variable** — Update variable
- **delete_pipeline_variable** — Delete variable

## Claude Desktop Quick Installation
Install path detected from listing signals. Uses `npx` (confidence: high):

```json
"mcpServers": {
  "mcp-server-bitbucket": {
    "command": "npx",
    "args": ["mcp-server-bitbucket"],
    "env": {
      "BITBUCKET_WORKSPACE": "",
      "BITBUCKET_EMAIL": "",
      "BITBUCKET_API_TOKEN": "",
      "BITBUCKET_OAUTH_TOKEN": "",
      "BITBUCKET_AUTH_TYPE": ""
    }
  }
}
```

**Requires environment variables:** `BITBUCKET_WORKSPACE`, `BITBUCKET_EMAIL`, `BITBUCKET_API_TOKEN`, `BITBUCKET_OAUTH_TOKEN`, `BITBUCKET_AUTH_TYPE` — the values above are empty placeholders; fill in real credentials before running (see the repository for what each one is for).

## Documentation

## What JaviMaligno/mcp-server-bitbucket does

JaviMaligno/mcp-server-bitbucket exposes Bitbucket Cloud API operations through the Model Context Protocol. Its 58 tools cover repository discovery and administration, pull requests, Pipelines, branches, commits, deployments, webhooks, tags, branch restrictions, permissions, and source browsing. Agents can read files and directory listings directly from Bitbucket rather than cloning a repository.

Pull request workflows include listing and inspecting requests, creating and merging them, approving or declining them, requesting changes, reading comments, adding comments, and retrieving diffs. Pipeline tools cover recent runs, status, logs, triggering, stopping, and pipeline variables. The package also provides MCP prompts for reusable workflows and MCP resources for browsable workspace data.

## How it works

The project contains TypeScript and Python implementations with matching functionality. The TypeScript package can be installed globally with npm or started with npx; the Python implementation can be installed with pipx. Both can run as local MCP servers and connect to clients such as Claude Code, Claude Desktop, and Cursor.

Bitbucket requests use one of two authentication modes. Personal Atlassian API tokens use Basic Auth with the account email and token. Workspace, project, or repository access tokens use Bearer Auth through `BITBUCKET_OAUTH_TOKEN`. The server can select the mode automatically or accept an explicit `BITBUCKET_AUTH_TYPE` value.

## Setup and configuration

Set `BITBUCKET_WORKSPACE` to the Bitbucket workspace slug. For Basic Auth, also set `BITBUCKET_EMAIL` and `BITBUCKET_API_TOKEN`. For a workspace-owned access token, use `BITBUCKET_OAUTH_TOKEN` instead of the email and Basic Auth combination. The TypeScript implementation requires Node.js 22 or newer in the supported patched releases, while the Python implementation requires Python 3.11 or newer.

Optional request controls include `API_TIMEOUT`, which defaults to 30 seconds, and `MAX_RETRIES`, which defaults to three attempts for rate-limited requests. A typical local installation uses `npm install -g mcp-server-bitbucket` or `pipx install mcp-server-bitbucket`. Claude Code and Cursor configurations pass the Bitbucket variables to the MCP process through their client settings.

Hosted deployments can protect the remote `/mcp` endpoint with an external OAuth authorization server. `MCP_OAUTH_ISSUER` and `MCP_OAUTH_AUDIENCE` enable this protection; related settings can define the signing-key URL, required scope, and public server URL. The health endpoint remains open, while authenticated requests are checked for JWT signature, issuer, audience, expiry, and scope. Bitbucket calls still use the server's configured credential.

## Tools and capabilities

- Manage repositories, including listing, searching, creating, deleting, and updating settings.
- Review pull requests, comments, and diffs, then create, approve, merge, decline, or request changes.
- Inspect, start, stop, and troubleshoot Bitbucket Pipelines through statuses and logs.
- Manage pipeline variables and access repository, branch, commit, deployment, webhook, tag, and restriction data.
- Browse source files and directories without a local clone.
- Use MCP prompts and resources for reusable workflows and workspace browsing.

## Limitations and notes

The server operates against Bitbucket using its configured credential, including when a remote deployment is protected by OAuth. Remote OAuth therefore controls access to the MCP endpoint but does not attribute individual Bitbucket actions to separate users. The TypeScript and Python versions are intended to provide the same functionality, while the TypeScript version is the deployment choice for Smithery.

_Full upstream README: https://allmcps.com/mcp/javimaligno-mcp-server-bitbucket/readme_

