bitbucket
Bitbucket MCP - A Model Context Protocol (MCP) server for integrating with Bitbucket Cloud and Server APIs
claude mcp add --transport stdio matanyemini-bitbucket-mcp npx -y bitbucket-mcp@latest \ --env BITBUCKET_URL="https://api.bitbucket.org/2.0" \ --env BITBUCKET_PASSWORD="your-app-password" \ --env BITBUCKET_USERNAME="your-username" \ --env BITBUCKET_WORKSPACE="your-workspace"
How to use
This MCP server provides a Connector to Bitbucket data and actions, exposing tools to list and retrieve repositories, fetch repository details, and access pull requests within a given workspace. It follows the Model Context Protocol so AI assistants can discover and invoke Bitbucket-related capabilities in a structured way. Use the Baton-like tools exposed by the MCP to browse repositories, inspect pull requests, and retrieve metadata without performing destructive changes. The server emphasizes safety by avoiding delete operations and includes CodeQL checks when analyzing pull requests.
To use with Cursor or another MCP consumer, configure an MCP entry that runs the bitbucket-mcp package via NPX (as shown in the integration example). The available tools allow paging through lists (repositories, pull requests, etc.), fetching specific items by ID, and extracting details like repository name, description, owner, and PR status. You can access the Bitbucket data through the tool calls and compose prompts that reference repository and PR attributes, enabling operations such as review workflows or status checks within your AI assistant workflows.
How to install
Prerequisites:
- Node.js and npm installed on your system
- Access to Bitbucket with a valid app password or token
Installation steps:
- Prepare environment variables for Bitbucket access (example):
# API-based access (recommended)
export BITBUCKET_URL="https://api.bitbucket.org/2.0"
export BITBUCKET_WORKSPACE="your-workspace"
export BITBUCKET_USERNAME="your-username"
export BITBUCKET_PASSWORD="your-app-password"
- Run the MCP server using NPX (no global install required):
npx -y bitbucket-mcp@latest
- Optional: install globally if you prefer a persistent binary (not required):
# Global install (optional)
npm install -g bitbucket-mcp
# Run globally installed version (Option A)
BITBUCKET_URL="https://api.bitbucket.org/2.0" \
BITBUCKET_WORKSPACE="your-workspace" \
BITBUCKET_USERNAME="your-username" \
BITBUCKET_PASSWORD="your-app-password" \
bitbucket-mcp
- For Cursor integration, configure the MCP from the Cursor settings as shown in the README example, ensuring the environment variables are provided in the configuration.
Additional notes
Notes and tips:
- Use a dedicated Bitbucket app password with at least Read permissions for Repositories and Pull requests.
- If you encounter authentication issues, verify that you are not using a regular Bitbucket password and that BITBUCKET_PASSWORD contains the app password.
- The MCP supports non-destructive operations; avoid enabling dangerous tools unless you explicitly intend to allow deletions or other risky actions.
- You can override the default API URL with BITBUCKET_URL if you are using self-hosted Bitbucket Server/Cloud variants.
- In Cursor integration, you can embed the runtime configuration and reuse the same environment variables across sessions for consistent access.
Related MCP Servers
mcp-for-beginners
This open-source curriculum introduces the fundamentals of Model Context Protocol (MCP) through real-world, cross-language examples in .NET, Java, TypeScript, JavaScript, Rust and Python. Designed for developers, it focuses on practical techniques for building modular, scalable, and secure AI workflows from session setup to service orchestration.
langchainjs -adapters
** THIS REPO HAS MOVED TO https://github.com/langchain-ai/langchainjs/tree/main/libs/langchain-mcp-adapters ** Adapters for integrating Model Context Protocol (MCP) tools with LangChain.js applications, supporting both stdio and SSE transports.
mcp-arr
MCP server for *arr media management suite
mcp-debugpy
MCP server for AI-assisted Python debugging using debugpy and Debug Adapter Protocol
mcpman
The package manager for MCP servers — install, manage & monitor across Claude Desktop, Cursor, VS Code, Windsurf
Obsidian
MCP server for bidirectional knowledge flow between Claude Code and Obsidian vaults