GitHub MCP (stdio)
@modelcontextprotocol 官方 GitHub stdio——26 工具全名实测,token 需自备。
规格
核实:
- 传输
- stdio(本地 npx)
- 包
- @modelcontextprotocol/server-github@2025.4.8
- 工具数
- 26(stdio 握手实测)
- 鉴权
- 握手免凭据;调用需 GitHub token
- 提供方
- @modelcontextprotocol 官方参考服务器
npm 包 `@modelcontextprotocol/server-github`(latest 2025.4.8,2026-11-21 npm view 核实)——官方参考服务器之一。2026-11-21 实测 `npx` 启动 initialize + tools/list,**26 个工具**逐名核实(create_or_update_file / search_repositories / create_repository / get_file_contents / push_files / create_issue / create_pull_request / fork_repository / create_branch / list_commits / list_issues / update_issue / add_issue_comment / search_code / search_issues / search_users / get_issue / get_pull_request / list_pull_requests / create_pull_request_review / merge_pull_request / get_pull_request_files / get_pull_request_status / update_pull_request_branch / get_pull_request_comments / get_pull_request_reviews)。无凭据握手通,实际调用需 GitHub token。remote 形态见 mcp-github 条目。
关键特性
- 官方参考服务器(servers 仓库)
- 26 工具:repo/issue/PR/搜索全覆盖
- 离线形态——配合 token 跑私有仓库
适用场景
私有仓库/离线流程:本地跑、token 自备,与 remote 版互补。
安装
`codex mcp add github-stdio --env GITHUB_PERSONAL_ACCESS_TOKEN=<TOKEN> -- npx -y @modelcontextprotocol/server-github`。config.toml 落 `mcp_servers.github-stdio` 段。
注意事项
写类工具(push/merge/PR review)随 token 权限即可执行——按 README 指引只授所需 scope(私有仓库需 `repo`)。
收录
更新
核实