github chat mcp
An MCP server that enables analyzing and querying GitHub repositories through the GitHub Chat API, allowing users to index repositories and ask questions about their code, architecture and tech stack.
An MCP server that enables analyzing and querying GitHub repositories through the GitHub Chat API, allowing users to index repositories and ask questions about their code, architecture and tech stack.
A Model Context Protocol (MCP) for analyzing and querying GitHub repositories using the GitHub Chat API. Official Site: https://github-chat.com
# Install with pip
pip install github-chat-mcp
# Or install with the newer uv package manager
uv install github-chat-mcp
Example prompts: - "Use github-chat-mcp to analyze the React repository" - "Index the TypeScript repository with github-chat-mcp and ask about its architecture"
Before anything, ensure you have a GitHub Chat API key. This is required to use the service.
Install uv first.
MacOS/Linux:
curl -LsSf https://astral.sh/uv/install.sh | sh
Windows:
powershell -ExecutionPolicy ByPass -c "irm https://astral.sh/uv/install.ps1 | iex"
In mcp.json:
{
"mcpServers": {
"github-chat": {
"command": "uvx",
"args": [
"github-chat-mcp"
]
}
}
}
With above, no envs required since it's a freemium release.
# claude_desktop_config.json
# Can find location through:
# Hamburger Menu -> File -> Settings -> Developer -> Edit Config
# Must perform: brew install uv
{
"mcpServers": {
"github-chat": {
"command": "uvx",
"args": ["github-chat-mcp"],
"env": {
}
}
}
}
You can install GitHub Chat for Claude Desktop automatically via Smithery:
npx -y @smithery/cli install github-chat-mcp --client claude
Index a GitHub repository first: "Index the GitHub repository at https://github.com/username/repo"
Then ask questions about the repository: "What is the core tech stack used in this repository?"
Run:
npx @modelcontextprotocol/inspector uvx github-chat-mcp
git clone https://github.com/yourusername/github-chat-mcp.git
Install uv first.
MacOS/Linux:
curl -LsSf https://astral.sh/uv/install.sh | sh
Windows:
powershell -ExecutionPolicy ByPass -c "irm https://astral.sh/uv/install.ps1 | iex"
Then install MCP server dependencies:
cd github-chat-mcp
# Create virtual environment and activate it
uv venv
source .venv/bin/activate # MacOS/Linux
# OR
.venv/Scripts/activate # Windows
# Install dependencies
uv sync
# `pip install mcp[cli]` if you haven't
mcp install /ABSOLUTE/PATH/TO/PARENT/FOLDER/github-chat-mcp/src/github_chat_mcp/server.py -v "GITHUB_API_KEY=API_KEY_HERE"
# claude_desktop_config.json
# Can find location through:
# Hamburger Menu -> File -> Settings -> Developer -> Edit Config
{
"mcpServers": {
"github-chat": {
"command": "uv",
"args": [
"--directory",
"/ABSOLUTE/PATH/TO/PARENT/FOLDER/github-chat-mcp",
"run",
"github-chat-mcp"
],
"env": {
}
}
}
}
Index a GitHub repository first: "Index the GitHub repository at https://github.com/username/repo"
Then ask questions about the repository: "What is the core tech stack used in this repository?"
Run:
# If mcp cli installed (`pip install mcp[cli]`)
mcp dev /ABSOLUTE/PATH/TO/PARENT/FOLDER/github-chat-mcp/src/github_chat_mcp/server.py
# If not
npx @modelcontextprotocol/inspector
uv
--directory /ABSOLUTE/PATH/TO/PARENT/FOLDER/github-chat-mcp
run
github-chat-mcp
Then access MCP Inspector at http://localhost:5173
. You may need to add your GitHub API key in the environment variables in the inspector under GITHUB_API_KEY
.
FASTMCP_LOG_LEVEL
environment variable (e.g. FASTMCP_LOG_LEVEL="ERROR"
)[
{
"description": "Index a GitHub repository to analyze its codebase. This must be done before asking questions about the repository.",
"inputSchema": {
"properties": {
"repo_url": {
"description": "The GitHub repository URL to index (format: https://github.com/username/repo).",
"title": "Repo Url",
"type": "string"
}
},
"required": [
"repo_url"
],
"title": "index_repositoryArguments",
"type": "object"
},
"name": "index_repository"
},
{
"description": "Ask questions about a GitHub repository and receive detailed AI responses. The repository must be indexed first.",
"inputSchema": {
"properties": {
"conversation_history": {
"anyOf": [
{
"items": {
"additionalProperties": {
"type": "string"
},
"type": "object"
},
"type": "array"
},
{
"type": "null"
}
],
"description": "Previous conversation history for multi-turn conversations.",
"title": "Conversation History"
},
"question": {
"description": "The question to ask about the repository.",
"title": "Question",
"type": "string"
},
"repo_url": {
"description": "The GitHub repository URL to query (format: https://github.com/username/repo).",
"title": "Repo Url",
"type": "string"
}
},
"required": [
"repo_url",
"question"
],
"title": "query_repositoryArguments",
"type": "object"
},
"name": "query_repository"
}
]