Github

io.github.davidweb3-ctrl由 GitHub 帳號 davidweb3-ctrl 發布v1.0.0更新於 Oct 24, 2026

GitHub MCP Server - List PRs, issues, repo info, and search code

概覽

AI 產生的概覽

一個本機 MCP 伺服器,讓 AI 助理讀取 GitHub 儲存庫:列出與檢視拉取請求及議題、取得儲存庫資訊、搜尋程式碼。

可以做什麼
列出與檢視拉取請求,可依狀態、來源分支與目標分支篩選,支援排序與分頁,並可選擇包含單一 PR 的 diff。列出與檢視議題,可依狀態、標籤、負責人與建立者篩選,並可選擇包含留言。取得指定擁有者與儲存庫的儲存庫資訊與統計。使用 GitHub 程式碼搜尋語法跨 GitHub 搜尋程式碼,支援排序與分頁。
適用情境
適合在工作過程中讓助理查詢 GitHub 動態:檢視開放的拉取請求、閱讀議題討論、檢查儲存庫中繼資料,或在 GitHub 上尋找程式碼範例。它只讀取資料,適合檢視與研究,而不是修改儲存庫。
執行需求
透過 npm(npx 或全域安裝)以本機程序執行。需要在 GITHUB_TOKEN 環境變數中提供 GitHub 個人存取權杖,並需要連線至 GitHub API 的網路存取。
安裝前請注意
伺服器需要 GITHUB_TOKEN 中的 GitHub 個人存取權杖;請盡量縮小其權限範圍,因為該權杖的權限決定助理能存取的內容。查詢與結果會傳送至 GitHub API。所列工具只讀取資料,但權杖本身是需要保護的憑證。

安裝

在 SourceWeft 中

  1. 開啟 儀表板中的 Github,將其新增到工作區。
  2. 為需要使用其工具的對話啟用該服務。

Desktop only,透過 STDIO。 STDIO 服務會啟動本機處理程序,因此需要 SourceWeft 桌面主機。

其他 MCP 客戶端

參照 儲存庫 中的啟動說明。

README

GitHub MCP Server

[npm version] [License: MIT]

A Model Context Protocol (MCP) server for GitHub operations. This server enables AI assistants to interact with GitHub repositories through a standardized interface.

Features

  • 🔍 List & View Pull Requests - Browse PRs with filtering options
  • 📋 List & View Issues - Access issues with labels, assignees, and comments
  • 📊 Repository Info - Get repository statistics and metadata
  • 🔎 Code Search - Search code across GitHub repositories

Installation

bash
npm install -g @bountyclaw/mcp-github-server

Configuration

Set your GitHub token as an environment variable:

bash
export GITHUB_TOKEN=your_github_token_here

Or pass it when creating the client programmatically.

Usage with Claude Code

Add to your Claude Code MCP settings:

json
{  "mcpServers": {    "github": {      "command": "npx",      "args": ["-y", "@bountyclaw/mcp-github-server"],      "env": {        "GITHUB_TOKEN": "your_github_token_here"      }    }  }}

Available Tools

1. github_pr_list

List pull requests for a repository.

Input:

  • owner (string, required): Repository owner
  • repo (string, required): Repository name
  • state (enum, optional): Filter by state (open, closed, all)
  • head (string, optional): Filter by head branch
  • base (string, optional): Filter by base branch
  • sort (enum, optional): Sort field
  • direction (enum, optional): Sort direction
  • per_page (number, optional): Results per page (max 100)
  • page (number, optional): Page number

2. github_pr_view

View details of a specific pull request.

Input:

  • owner (string, required): Repository owner
  • repo (string, required): Repository name
  • pull_number (number, required): PR number
  • include_diff (boolean, optional): Include diff content

3. github_issue_list

List issues for a repository.

Input:

  • owner (string, required): Repository owner
  • repo (string, required): Repository name
  • state (enum, optional): Filter by state
  • labels (string, optional): Comma-separated label names
  • assignee (string, optional): Filter by assignee
  • creator (string, optional): Filter by creator
  • sort (enum, optional): Sort field
  • direction (enum, optional): Sort direction
  • per_page (number, optional): Results per page
  • page (number, optional): Page number

4. github_issue_view

View details of a specific issue.

Input:

  • owner (string, required): Repository owner
  • repo (string, required): Repository name
  • issue_number (number, required): Issue number
  • include_comments (boolean, optional): Include comments

5. github_repo_info

Get repository information and statistics.

Input:

  • owner (string, required): Repository owner
  • repo (string, required): Repository name

6. github_search_code

Search code across GitHub.

Input:

  • query (string, required): Search query (GitHub code search syntax)
  • sort (enum, optional): Sort field (indexed, best-match)
  • order (enum, optional): Sort order
  • per_page (number, optional): Results per page
  • page (number, optional): Page number

Example Queries

"List open PRs in facebook/react""Show me issue #123 in microsoft/vscode""Get info about the kubernetes/kubernetes repo""Search for 'useEffect' in TypeScript files"

Development

bash
# Install dependenciesnpm install
# Buildnpm run build
# Run testsnpm test
# Run tests with coveragenpm run test:coverage
# Lintnpm run lint
# Formatnpm run format

Testing

The project includes comprehensive unit tests with 90%+ coverage:

  • GitHub API client tests
  • Tool handler tests for all 6 tools
  • Error handling tests
  • Input validation tests
bash
npm test

License

MIT License - see LICENSE file for details.

Contributing

Contributions are welcome! Please feel free to submit a Pull Request.


Built with 🦞 by BountyClaw

來源:README.md,提交 361f6bc

工具

0
SourceWeft 尚未在沙箱中啟動過該軟體包,因此其工具未知。

版本歷史

1
  1. v1.0.0最新Sep 16, 2026

評分

已滿足適用檢查項的 50%

該評分衡量此收錄條目的完整程度,依據註冊中心條目、端點與公開來源計算得出。它不是對伺服器本身的評價,也不表示伺服器安全或目前可用:可連通性是帶日期的檢查結果,評分也不包含安裝量或使用者評價。

  • 近 30 天內可連通25 分

    請保持端點能夠回應 MCP 握手;SourceWeft 每 30 天探測一次。

  • 已宣告認證方式10 分

    請在註冊中心條目中宣告憑證請求標頭,或保持端點能夠回應探測,以便判定其認證方式。

  • 已列出工具15 分

    請讓伺服器在無憑證時回應 tools/list,或發布可在沙箱中無憑證啟動的軟體包。

  • 描述必需15 分
  • 圖示10 分
  • 文件15 分
  • 授權條款10 分