github-repo-mcp-server
This server provides a read-only interface for an AI assistant to query GitHub on your behalf. It covers your personal repositories (restricted to a configured allowlist) and offers public trending repo discovery that is not gated.
Repository Metadata & Browsing:
get_repo(description, stars, language, default branch, visibility),list_repos(all allowlisted repos),list_branches,list_commits,get_file_contents(read file at any ref),search_code(within a single allowlisted repo).Issues & Pull Requests:
list_issues(filter by state, label, assignee),get_issue(detail + comment thread),list_pull_requests(filter by state, base, head),get_pull_request(diff stats, mergeable state, review status).CI/CD & Notifications:
get_workflow_runs(recent GitHub Actions status) andget_notifications(unread mentions/review requests, requires token permission).Discovery:
search_trending_reposfinds trending public repositories by topic, ranked by star count among recently pushed repos.Resources: Access README, issue details, and PR details via URI templates (e.g.,
repo://owner/repo/readme).Prompts: Reusable templates for summarizing open PRs (
summarize_prs_for_review), generating a weekly digest (weekly_repo_digest), and surfacing trending topics (whats_trending).Utility:
pingfor health check.
All actions are read-only; write operations like creating issues are intentionally excluded.
Provides tools for querying GitHub data, including personal repositories, issues, pull requests, commit history, file contents, code search, workflow runs, and notifications, as well as discovering trending public repositories by topic.
Click on "Install 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., "@github-repo-mcp-serverwhat are the latest issues in my repo?"
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.
github-repo-mcp-server
An MCP (Model Context Protocol) server that lets an AI assistant query GitHub on your behalf — your own repos, issues, PRs, and CI status, plus discovery of trending repos by topic across public GitHub.
See SPEC.md for the full design and development plan.
Status
✅ All planned milestones complete.
M0 — Project scaffold: TypeScript + MCP SDK, minimal
pingtool over stdioM1 — GitHub client + config (Octokit auth, repo allowlist)
M2 — Tier 1 read-only personal-repo tools (12 tools)
M3 —
search_trending_reposdiscovery toolM4 — MCP resources (README, issue/PR content)
M5 — MCP prompts (reusable templates)
M6 — Tests, rate-limit hardening, docs
Tier 2 write tools (create issue, comment, etc.) were scoped out of v1 intentionally — see SPEC.md §11. This is a read-only server.
Related MCP server: GitHub Analytics MCP Server
Requirements
Node.js 18+ (developed against Node 20; see
.nvmrc)
Configuration
Copy
.env.exampleto.envand setGITHUB_TOKENto a fine-grained personal access token with read-onlyContents,Issues,Pull requests, andActionspermissions, scoped to the repos you want this server to access.List those repos (as
"owner/repo"strings) inconfig.json— this is the allowlist personal-scope tools are restricted to.search_trending_reposis exempt, since it queries public GitHub data rather than a specific repo.get_notificationsadditionally needs the token's Notifications account permission (separate section from repository permissions on the token creation page) — every other tool works without it.
Tools
Personal scope (allowlist-gated): get_repo, list_repos, list_branches,
list_commits, get_file_contents, list_issues, get_issue,
list_pull_requests, get_pull_request, search_code, get_workflow_runs,
get_notifications.
Global discovery (not allowlist-gated, searches public GitHub data):
search_trending_repos — finds trending repos for a topic, ranked by star
velocity among recently-created repos. A documented proxy for
github.com/trending, which has no official API.
Resources
URI template | Content |
| The repo's README, as markdown |
| Issue title, body, and comments |
| PR title, description, diff stats |
Prompts
Name | What it does |
| Finds open PRs and summarizes which need attention |
| Commits, issues, PRs, and CI status from the last week |
| Trending public repos for a GitHub topic |
Getting started
npm install
npm run dev # run the server directly via tsx
npm run build # compile to dist/
npm start # run the compiled serverThe server communicates over stdio, following the MCP protocol — it's meant to be launched by an MCP-compatible host (e.g. Claude Code), not run standalone in a terminal.
Testing
npm test # typecheck (src + test) then run the full vitest suite
npm run typecheckThe suite (32 tests) runs through the real MCP protocol layer — an
McpServer and Client connected over an in-memory transport — with
@octokit/rest mocked, so it exercises actual schema validation and request
routing without making live API calls. Every tool, resource, and prompt was
also manually verified against a real repo during development; see individual
commit messages for what was and wasn't exercised against real data.
Notable things found during development
A few real issues surfaced by testing against live data instead of just mocks, worth knowing if you extend this:
GitHub's code search doesn't index unstarred forks.
search_codereturned 0 results withincomplete_results: trueagainst a fresh fork - confirmed via a rawcurlcall that this is GitHub's own indexing limitation, not a bug (forks are only code-search-indexed once they have more stars than their parent repo).get_notificationsneeds a separate token permission. It uses a GitHub account-level permission (Notifications), not a repository permission like every other tool - discovered via a live 403, now surfaced as a specific error message instead of the generic one.Composed Octokit plugin types aren't portable. Wrapping the client with
@octokit/plugin-throttlingbroke.d.tsemission (TS2883). Fixed by droppingdeclaration: truefromtsconfig.json, since this is a runnable server, not a library other packages import.
License
MIT
Maintenance
Resources
Unclaimed servers have limited discoverability.
Looking for Admin?
If you are the server author, to access and configure the admin panel.
Related MCP Servers
- Flicense-qualityDmaintenanceProvides access to GitHub trending projects through MCP, allowing AI assistants to query popular repositories filtered by language and time range (daily/weekly/monthly).Last updated
- Alicense-qualityDmaintenanceEnables querying and analysis of public GitHub repositories for statistics, contributor data, and commit history. It provides both a RESTful API and an MCP interface for seamless integration with AI agents.Last updatedMIT
- Alicense-qualityCmaintenanceDiscover, rank, and compare GitHub repositories from any MCP-compatible AI client. Enables searching, filtering, ranking, and evaluating open-source repositories by topic, language, stars, license, activity, and relevance.Last updatedMIT
- Alicense-qualityDmaintenanceEnables AI-powered GitHub interactions including repository analysis, code search, PR reviews, and more through the MCP protocol.Last updated4MIT
Related MCP Connectors
Connect AI assistants to GitHub - manage repos, issues, PRs, and workflows through natural language.
An MCP server that gives your AI access to the source code and docs of all public github repos
Connect AI assistants to your GitHub-hosted Obsidian vault to seamlessly access, search, and analy…
Latest Blog Posts
- Who's Calling? MCP Hosts Are an Identity Blind Spot (And the Spec Knows It)By Om-Shree-0709 on .mcpAgent IdentityOAuth 2.1
- Your AI Chatbot Just Exposed Your CEO's Salary to an InternBy Om-Shree-0709 on .Agent IdentityMCP SecurityOAuth Delegation
- Why MCP Servers Need Execution Sandboxing (And Why Your Current Stack Isn't Enough)By Om-Shree-0709 on .Agentic AiPrompt InjectionWebAssembly
MCP directory API
We provide all the information about MCP servers via our MCP API.
curl -X GET 'https://glama.ai/api/mcp/v1/servers/technomad641/github-repo-mcp-server'
If you have feedback or need assistance with the MCP directory API, please join our Discord server