
Bitbucket MCP
用於 Bitbucket Cloud 和 Server 的模型上下文協定 (MCP) 伺服器,能讓 Cursor 等 AI 助手透過自然語言管理儲存庫、拉取請求、管線等。

概述
Bitbucket MCP 是一個開源的模型上下文通訊協定(MCP)伺服器,用於整合 Bitbucket Cloud 與 Bitbucket Server/Data Center API。它能讓 AI 助手(如 Cursor)透過自然語言提示,直接安全地與您的 Bitbucket 儲存庫、拉取請求、管道及其他資源進行互動。
此伺服器實作了 MCP 標準,並以 bitbucket-mcp 套件發布於 npm。
功能特色
- 儲存庫操作:列出儲存庫並取得詳細資訊
- 拉取請求生命週期:列出、取得、建立、更新、合併、核准、拒絕、新增/檢視評論、差異比較及任務
- 管道操作:列出執行記錄、觸發/停止管道、檢視步驟與日誌
- 分頁支援(
pagelen、page、all、limit) - 預設安全設計:除非明確設定
BITBUCKET_ENABLE_DANGEROUS=true,否則停用 DELETE 操作
支援的操作
伺服器提供常用 Bitbucket 工作流程的工具,包括儲存庫瀏覽、PR 管理、程式碼審查自動化及管道監控。完整的工具清單與 API 對應關係定義於原始碼中。
安全性與最佳實務
- 需要使用具備最小權限範圍的 Bitbucket 應用程式密碼(或存取權杖):儲存庫:讀取;拉取請求:讀取/寫入;管道:讀取
- 預設不啟用任何 DELETE 操作
- 可設定的記錄功能(檔案型或停用)
- 支援 Bitbucket Cloud(
https://api.bitbucket.org/2.0)以及透過可設定的BITBUCKET_URL支援自架 Bitbucket Server
相容性
可搭配任何支援 MCP 的 AI 執行環境使用。主要整合範例聚焦於 Cursor,並同時支援 Bitbucket Cloud 與 Server。
連結
MCP 設定
先決條件
- 需要 Node.js(用於 npx/npm)
- 具備應用程式密碼或存取權杖的 Bitbucket 帳戶
存取需求
- 需要透過環境變數提供 Bitbucket 應用程式密碼(儲存庫:讀取、拉取請求:讀取/寫入、管道:讀取)或存取權杖
用戶端設定
Cursor
{
"mcpServers": {
"bitbucket": {
"command": "npx",
"env": {
"BITBUCKET_URL": "https://api.bitbucket.org/2.0",
"BITBUCKET_WORKSPACE": "your-workspace",
"BITBUCKET_USERNAME": "your-username",
"BITBUCKET_PASSWORD": "your-app-password"
},
"args": ["-y", "bitbucket-mcp@latest"]
}
}
}
- 在您的專案根目錄中建立或編輯
.cursor/mcp.json。 - 貼上上述配置區塊,並將佔位符(
your-workspace、your-username、your-app-password)替換為您的實際值。
認證:
- 憑證透過 MCP 配置中的環境變數傳遞。無需瀏覽器登入或其他授權步驟。
舊版 URL 格式(https://bitbucket.org/your-workspace )也支援自動偵測工作區。
Claude Code
未記錄
Claude Desktop
未記錄
VS Code
未記錄
Codex
未記錄
Windsurf
未記錄
Lovable
未記錄
Other
透過 npx -y bitbucket-mcp@latest 執行,並設定必要的環境變數(參見 envVars)。使用 stdio/command 傳輸方式在您的 MCP 用戶端中配置。
環境變數
BITBUCKET_URL(預設為 https://api.bitbucket.org/2.0 )BITBUCKET_WORKSPACE(可選,舊版模式下從 URL 自動偵測)BITBUCKET_USERNAME(您的 Bitbucket 電子郵件/使用者名稱)BITBUCKET_PASSWORD(應用程式密碼或 API 權杖)BITBUCKET_TOKEN(替代使用者名稱/密碼)
設定文件:https://github.com/MatanYemini/bitbucket-mcp
Tags
Related Entries
Keep exploring similar tools and resources in this category.

viewmax mcp
MCP ServersViewMax MCP is a hosted Streamable HTTP MCP server for generating AI video, images, music, speech, and sound effects, with tools for model discovery, task polling, and credit checks. Official setup is documented for Claude Web/Desktop, Claude Code, Cursor, Codex, and SDK clients.
Related Reads
Background, tutorials, and protocol context connected to this entry.





