Bitbucket MCP
Provides tools for managing pull requests, branches, and repositories in Bitbucket Cloud via its REST API, including creating, updating, merging, declining PRs, commenting, reviewing, listing branches, and managing default reviewers.
Click on "Deploy Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@Bitbucket MCP what are my open pull requests?"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
Bitbucket MCP
An MCP server for Bitbucket Cloud. Use it from any MCP-capable client (Cursor, Claude Desktop, Codex, and others) to manage pull requests, branches, and repositories in natural language.
It targets the Bitbucket Cloud REST API at https://api.bitbucket.org/2.0 by default. You can point it at a Bitbucket Server / Data Center instance with BITBUCKET_BASE_URL, but only endpoints that match the Cloud API shape are guaranteed to work.
Prerequisites
Node.js 24 or newer
A Bitbucket Cloud account with access to the workspace you want to use
Related MCP server: Bitbucket MCP Server
Installation
Run the published package directly with npx (recommended — no install step):
npx -y @inconcept-labs/bitbucket-mcpOr install globally and run the bitbucket-mcp binary:
npm install -g @inconcept-labs/bitbucket-mcp
bitbucket-mcpThe server speaks MCP over stdio and is meant to be launched by an MCP client, not run by hand.
Setup
1. Create an Atlassian API token
This server authenticates with a scoped Atlassian API token. (Bitbucket Cloud app passwords are deprecated — new ones can no longer be created since 2025-09-09, and any remaining ones stop working on 2026-06-09.)
Sign in to Bitbucket, click your avatar (top-right) → Account settings.
Open the Security tab → Create and manage API tokens → Create API token with scopes.
Give the token a name and an expiry date, then select Bitbucket as the app.
Select these scopes:
read:repository:bitbucketwrite:repository:bitbucketread:pullrequest:bitbucketwrite:pullrequest:bitbucketadmin:repository:bitbucket
Click Create token and copy the value immediately — Atlassian only displays it once.
2. Find your workspace slug and Atlassian email
Workspace slug: the path segment in your Bitbucket URL — e.g. for
https://bitbucket.org/acme-inc/some-repo, the slug isacme-inc. Use the slug, not the workspace display name.Atlassian email: the email address you sign in to Atlassian with. API tokens authenticate as
email:token— your Bitbucket username will not work.
3. Environment variables
Variable | Required | Description |
| Yes | Your Atlassian account email (used as the Basic-auth username paired with the API token). |
| Yes | Your Atlassian API token from step 1. The variable is named |
| Yes | Workspace slug from your Bitbucket URL. |
| No | API base URL. Defaults to |
| No | Set to |
4. MCP client configuration
Add a server entry that runs the package with npx and passes the variables above. Example:
{
"mcpServers": {
"bitbucket": {
"command": "npx",
"args": ["-y", "@inconcept-labs/bitbucket-mcp"],
"env": {
"BITBUCKET_USERNAME": "you@example.com",
"BITBUCKET_APP_PASSWORD": "your_atlassian_api_token",
"BITBUCKET_WORKSPACE": "your_workspace_slug"
}
}
}
}Where this file lives
Cursor:
~/.cursor/mcp.json, or Cursor → Settings → MCPClaude Desktop (macOS):
~/Library/Application Support/Claude/claude_desktop_config.jsonClaude Desktop (Windows):
%APPDATA%\Claude\claude_desktop_config.json
After saving, restart the MCP client so it picks up the new server.
Available tools
Repositories
Tool | Description |
| List repos in the workspace (supports search & pagination). |
Pull requests
Tool | Description |
| List PRs filtered by state ( |
| Full PR details including participants and reviewers. |
| Open a new PR with optional reviewers. |
| Update title, description, or reviewers. |
| Merge using |
| Decline a PR with an optional message. |
| Post a Markdown comment on a PR. |
| Fetch the unified diff (truncated for safety). |
| List all comments on a PR. |
| Get a specific comment. |
| Update a comment. |
| Delete a comment (requires |
| Resolve a comment thread. |
| Reopen a resolved comment thread. |
| Approve a PR. |
| Remove your approval. |
| Request changes on a PR. |
| List commit / build statuses for a PR. |
| List default reviewers (auto-added to new PRs). |
| Get a specific default reviewer. |
| Add a user as default reviewer. |
| Remove a user from default reviewers. |
Branches
Tool | Description |
| List branches with optional name search. |
| Delete a branch (requires |
Example prompts
"List all open PRs in the backend repo"
"Create a PR from feature/auth to main: 'Add OAuth login'"
"Show me the diff for PR #42"
"Merge PR #42 using squash"
"Decline PR #15 with message: not needed anymore"
"Add a comment to PR #8: 'LGTM!'"
Troubleshooting
Configuration erroron startup — One or more required env vars are missing or empty. SetBITBUCKET_USERNAME,BITBUCKET_APP_PASSWORD, andBITBUCKET_WORKSPACE, then restart the MCP client.401 Unauthorized— Most often one of:BITBUCKET_USERNAMEis your Bitbucket username instead of your Atlassian email — API tokens require the email.The API token is wrong, expired, or was created without the scopes listed above.
You're still using a legacy app password — create an API token instead (app passwords are being phased out).
403 Forbidden— The token authenticates but is missing a scope for the tool you ran. Re-create the token and add the missing scope (e.g.write:pullrequest:bitbucketfor merge/approve,write:repository:bitbucketfordelete_branch).404 Not Foundfor repos —BITBUCKET_WORKSPACEis wrong. Use the slug from the URL (e.g.acme-inc), not the workspace display name.Destructive tool not found —
delete_branchanddelete_pr_commentare not registered unlessBITBUCKET_MCP_ALLOW_DESTRUCTIVE_TOOLSis set to a truthy value. Set it and restart the client.
Contributing
For development, project layout, testing, and release automation, see CONTRIBUTING.md.
Links
License
MIT
Available Tools
23 toolsadd_default_reviewerB
Add a user as default reviewer for the repository
Inputs: username (required), repo_slug (required).
add_pr_commentA
Post a Markdown comment on a pull request
Inputs: pr_id (required), content (required), repo_slug (required).
approve_pull_requestC
Approve a pull request
Inputs: pr_id (required), repo_slug (required).
create_pull_requestC
Create a new pull request
Inputs: title (required), repo_slug (required), source_branch (required), destination_branch (required), +3 more.
decline_pull_requestB
Decline (reject) an open pull request
Inputs: pr_id (required), repo_slug (required), message.
get_default_reviewerB
Get a specific default reviewer
Inputs: username (required), repo_slug (required).
get_diffA
Get the unified diff for a pull request (truncated to 8 KB)
Inputs: pr_id (required), repo_slug (required).
get_pr_commentB
Get a specific comment on a pull request
Inputs: pr_id (required), repo_slug (required), comment_id (required).
get_pull_requestA
Get full details of a specific pull request
Inputs: pr_id (required), repo_slug (required).
list_branchesC
List branches in a repository
Inputs: repo_slug (required), page, search.
list_default_reviewersA
List default reviewers for a repository (auto-added to new PRs)
Inputs: repo_slug (required).
list_pr_commentsB
List all comments on a pull request
Inputs: pr_id (required), repo_slug (required), page.
list_pr_statusesB
List commit/build statuses for a pull request
Inputs: pr_id (required), repo_slug (required), page.
list_pull_requestsC
List pull requests for a repository
Inputs: repo_slug (required), page, state.
list_repositoriesA
List all repositories in the configured workspace
Inputs: page, search.
merge_pull_requestB
Merge an open pull request. When merge_strategy is omitted, the repository's configured default for the PR's destination branch is used (falling back to merge_commit if none is set).
Inputs: pr_id (required), repo_slug (required), message, merge_strategy, +1 more.
remove_default_reviewerB
Remove a user from default reviewers
Inputs: username (required), repo_slug (required).
reopen_pr_commentA
Reopen a resolved comment thread on a pull request
Inputs: pr_id (required), repo_slug (required), comment_id (required).
request_pr_changesC
Request changes on a pull request
Inputs: pr_id (required), repo_slug (required), message.
resolve_pr_commentA
Resolve a comment thread on a pull request
Inputs: pr_id (required), repo_slug (required), comment_id (required).
unapprove_pull_requestA
Remove your approval from a pull request
Inputs: pr_id (required), repo_slug (required).
update_pr_commentC
Update a comment on a pull request
Inputs: pr_id (required), content (required), repo_slug (required), comment_id (required).
update_pull_requestB
Update the title, description, or reviewers of a pull request
Inputs: pr_id (required), repo_slug (required), title, reviewers, +1 more.
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelog…
TDQS
Scored across 23 tools
Each tool targets a distinct resource/action: pull request lifecycle, comments, approvals, statuses, and default reviewers are all cleanly separated. Even closely related actions like approve, request changes, and decline are clearly differentiated by name and description.
The set overwhelmingly follows a verb_noun snake_case pattern, which makes it predictable. The main inconsistency is mixing 'pr' and 'pull_request' (e.g., list_pull_requests vs. list_pr_comments, get_pull_request vs. get_pr_comment), so it is not perfectly uniform.
At 23 tools, the server is in the heavy range. Each tool has a distinct purpose, but the granular review-state operations and default reviewer management could feel bloated compared to a leaner PR-focused server.
The server covers the core Bitbucket pull request workflow well: PR CRUD, merging/declining, comments, approvals, statuses, and default reviewers. Minor gaps exist, such as no single-repository fetch and no way to delete a PR comment, but these are unlikely to block common workflows.
Maintenance
Related MCP Connectors
A MCP server built for developers enabling Git based project management with project and personal…
Create, deploy, and operate MCP servers directly from your GitHub repositories.
MCP Server for JFrog, providing tools for development and artifact management.
The MCP server for Azure DevOps, bringing the power of Azure DevOps directly to your agents.
Related MCP Servers
- AlicenseBqualityCmaintenanceAn MCP server that enables interaction with Bitbucket repositories through the Model Context Protocol, supporting both Bitbucket Cloud and Server with features for PR lifecycle management and code review.208,411 npm30MIT
- AlicenseBqualityDmaintenanceAn MCP server that provides tools for interacting with the Bitbucket API, supporting both Bitbucket Cloud and Bitbucket Server, enabling pull request, branch, file, code review, and search operations.198,411 npmMIT
- FlicenseCqualityDmaintenanceAn MCP server for Bitbucket Cloud, covering pull requests, pull request comments, and pipelines.26-
- AlicenseAqualityDmaintenanceMCP server for Bitbucket Cloud that enables reviewing, managing, and merging pull requests, assigning reviewers by name, reading files at a ref, and inspecting pipeline status from any MCP client.14MIT