GitHub MCP Server
A Model Context Protocol (MCP) server that connects Claude AI directly to the GitHub API, enabling natural language queries for live repository data, issues, PRs, and contributions.
README
🤖 GitHub MCP Server — Your AI-Powered GitHub Assistant
Ask Claude anything about a GitHub repo — and it actually does it.

What is this?
This is a Model Context Protocol (MCP) server that connects Claude AI directly to the GitHub API.
Instead of copy-pasting repo links and asking Claude to "analyze this", you just talk to Claude naturally:
"Get the stats for facebook/react" "Find good first issues in microsoft/vscode" "Summarize PR #42 for vercel/next.js"
And Claude calls the right tool, fetches live data from GitHub, and gives you a clean, formatted answer — all inside Claude Desktop.
No browser switching. No manual copy-paste. Just ask.
Tools Available
| Tool | What it does |
|---|---|
get_repo_stats |
Stars, forks, language, license, last push — everything at a glance |
get_open_issues |
Lists open issues with labels, age, and comment count |
get_contributors |
Top contributors ranked by commits, with percentage insights |
summarize_pull_request |
Fetches PR diffs and generates an AI summary with risk level |
find_good_first_issues |
Finds beginner-friendly issues filtered by label — great for open source contributions |
How it works
You (in Claude Desktop)
↓
Claude AI
↓
MCP Server (this project)
↓
GitHub REST API + Groq AI
↓
Formatted response back to Claude
When you ask Claude about a repo, it calls one of the tools registered in this server. The server fetches data from GitHub, optionally runs it through Groq for AI summaries, formats everything into clean markdown, and sends it back to Claude to show you.
Tech Stack
- Runtime — Node.js + TypeScript
- MCP SDK —
@modelcontextprotocol/sdk(connects to Claude Desktop) - GitHub API — via
axioswith token auth - AI Summaries — Groq API (fast, free tier available)
- Config —
dotenvfor environment variables
Project Structure
src/
├── server.ts # Entry point — wires up the MCP server
├── tools/
│ ├── registry.ts # Tool registry — all tools defined and dispatched here
│ ├── issues.ts # Open issues logic
│ ├── contributors.ts # Contributors logic
│ ├── pullRequest.ts # PR fetch + AI summary
│ └── goodFirstIssues.ts # Beginner issue finder
├── services/
│ ├── githubService.ts # Shared GitHub axios client
│ └── aiService.ts # Groq AI summarization
└── utils/
└── formatters.ts # Markdown formatters for all tool responses
Getting Started
1. Clone and install
git clone https://github.com/aviralkaushik412/github-mcp-server
cd github-mcp-server
npm install
2. Set up environment variables
Create a .env file in the root:
GITHUB_TOKEN=your_github_personal_access_token
GROQ_API_KEY=your_groq_api_key
- Get a GitHub token at github.com/settings/tokens — needs
reposcope - Get a free Groq key at console.groq.com
3. Connect to Claude Desktop
Open your Claude Desktop config file:
- Mac:
~/Library/Application Support/Claude/claude_desktop_config.json - Windows:
%APPDATA%\Claude\claude_desktop_config.json
Add this:
{
"mcpServers": {
"github-mcp-server": {
"command": "npx",
"args": ["ts-node", "/absolute/path/to/src/server.ts"]
}
}
}
4. Restart Claude Desktop and start asking
"Get stats for torvalds/linux"
"Find good first issues in facebook/react"
"Summarize PR #1 for aviralkaushik412/SkillMirror"
Screenshots
Repo Stats

PR Summary with AI

Current working

What I learned building this
This project taught me a lot about how AI models actually work with tools — not just answering questions from memory, but taking actions and fetching real-time data.
A few things that were genuinely tricky:
- MCP servers communicate over stdout as a JSON stream — one stray
console.log()breaks everything silently - Claude decides which tool to call based on the tool's
descriptionfield — so wording matters a lot - Structuring responses as clean markdown makes Claude's output dramatically better
Coming Soon
- [ ]
explain_repository— AI-generated plain-English explanation of what any repo does - [ ]
analyze_pr_risk— flags high-risk PRs based on file count, diff size, and sensitive paths - [ ] React dashboard frontend for non-Claude-Desktop users
Resume Bullet Points
If you're here from my resume, here's the one-liner version:
Built a production-ready Model Context Protocol (MCP) server in TypeScript that connects Claude AI to the GitHub REST API and Groq AI, enabling natural language queries over live repository data via 5 registered tools with structured error handling, formatted markdown responses, and a tool registry pattern.
Author
Aviral Kaushik github.com/aviralkaushik412
Built with Claude Desktop, TypeScript, and a lot of stderr debugging.
推荐服务器
Baidu Map
百度地图核心API现已全面兼容MCP协议,是国内首家兼容MCP协议的地图服务商。
Playwright MCP Server
一个模型上下文协议服务器,它使大型语言模型能够通过结构化的可访问性快照与网页进行交互,而无需视觉模型或屏幕截图。
Magic Component Platform (MCP)
一个由人工智能驱动的工具,可以从自然语言描述生成现代化的用户界面组件,并与流行的集成开发环境(IDE)集成,从而简化用户界面开发流程。
Audiense Insights MCP Server
通过模型上下文协议启用与 Audiense Insights 账户的交互,从而促进营销洞察和受众数据的提取和分析,包括人口统计信息、行为和影响者互动。
VeyraX
一个单一的 MCP 工具,连接你所有喜爱的工具:Gmail、日历以及其他 40 多个工具。
graphlit-mcp-server
模型上下文协议 (MCP) 服务器实现了 MCP 客户端与 Graphlit 服务之间的集成。 除了网络爬取之外,还可以将任何内容(从 Slack 到 Gmail 再到播客订阅源)导入到 Graphlit 项目中,然后从 MCP 客户端检索相关内容。
Kagi MCP Server
一个 MCP 服务器,集成了 Kagi 搜索功能和 Claude AI,使 Claude 能够在回答需要最新信息的问题时执行实时网络搜索。
e2b-mcp-server
使用 MCP 通过 e2b 运行代码。
Neon MCP Server
用于与 Neon 管理 API 和数据库交互的 MCP 服务器
Exa MCP Server
模型上下文协议(MCP)服务器允许像 Claude 这样的 AI 助手使用 Exa AI 搜索 API 进行网络搜索。这种设置允许 AI 模型以安全和受控的方式获取实时的网络信息。