GitHub
🧠🤖 MCP-compliant AI agent server in TypeScript 🚀 — Extend Claude & others with 🐙 GitHub Repos, Issues, Pull Requests & Actions superpowers! Ready-to-use executables available for macOS & Windows
claude mcp add --transport stdio chayan-1906-github-mcp node dist/server.js \ --env PORT="20253" \ --env DB_NAME="github" \ --env CLIENT_ID="your_github_client_id" \ --env MONGODB_URI="your_mongodb_connection_string" \ --env TOKEN_SECRET="your_token_secret" \ --env CLIENT_SECRET="your_github_client_secret" \ --env GITHUB_CALLBACK_URL="http://localhost:20253/github/oauth/callback"
How to use
GitHub-MCP is an MCP-compliant server built with TypeScript that extends Claude and other AI agents with specialized GitHub capabilities. It provides tools to manage and interact with GitHub data such as repositories, issues, pull requests, branches, releases, and actions. After starting the server, you can browse the available tools via the provided UI at the configured port (default 20253) and prompt Claude or other agents to use the GitHub tools for tasks like listing repositories, getting repository details, creating repositories, and managing collaborators. To use the tools effectively, authenticate with a GitHub account to enable OAuth-scoped access; the tools automatically handle API calls and return structured results that you can present in your prompts or workflows. When prompting, instruct the agent to use the available GitHub tools to ensure actions are executed through the MCP rather than external web searches.
How to install
Prerequisites:
- Node.js 16.x or newer and npm
- MongoDB instance reachable at the configured MONGODB_URI
- A GitHub OAuth App with client ID and secret
Installation steps:
-
Clone the repository: git clone https://github.com/chayan-1906/GitHub-MCP.git cd GitHub-MCP
-
Install dependencies: npm install
-
Configure credentials: Create or edit src/config/config.ts and set:
- PORT = 20253
- DB_NAME = github
- CLIENT_ID = your_github_client_id
- CLIENT_SECRET = your_github_client_secret
- GITHUB_CALLBACK_URL = http://localhost:20253/github/oauth/callback
- MONGODB_URI = your_mongodb_connection_string
- TOKEN_SECRET = a securely generated hex string
Example snippet:
export const PORT = 20253
export const DB_NAME = "github"
export const CLIENT_ID = "your_github_client_id"
export const CLIENT_SECRET = "your_github_client_secret"
export const GITHUB_CALLBACK_URL =
http://localhost:${PORT}/github/oauth/callbackexport const MONGODB_URI = "your_mongodb_connection_string" export const TOKEN_SECRET = "your_token_secret"
-
Generate a secure token secret (optional but recommended): openssl rand -hex 32
-
Run the server (development): npm run dev
-
Build and package (optional): npm run build npm run bundle npm run package
Additional notes
Notes and tips:
- This MCP server can also run via pre-built executables for macOS, Windows, and Linux as described in the Quick Start section to avoid Node.js dependencies on the client machine.
- The server exposes a web UI at http://localhost:20253/ to explore available tools and understand descriptions.
- If you need to switch GitHub accounts, visit http://localhost:20253/auth to complete the OAuth flow for the desired account.
- Ensure you provide valid MongoDB connection details and GitHub OAuth credentials before starting the server.
- The port, database name, and OAuth settings are configurable; adjust them in src/config/config.ts or environment variables as needed.
Related MCP Servers
mcp -tree-sitter
MCP Server for Tree-sitter
ls
List MCP Server configurations in your system used by AI applications like Cursor, Claude Desktop, VS Code and others
mcp_server_filesystem
MCP File System Server: A secure Model Context Protocol server that provides file operations for AI assistants. Enables Claude and other assistants to safely read, write, and list files in a designated project directory with robust path validation and security controls.
mcp-claude-spotify
An integration that allows Claude Desktop to interact with Spotify using the Model Context Protocol (MCP).
mirroir
MCP server for controlling a real iPhone via macOS iPhone Mirroring...and any MacOs app. Screenshot, tap, swipe, type — from any MCP client.
mcp-salesforce
🚀 Complete MCP (Model Context Protocol) server for Salesforce integration with Claude Desktop. Provides seamless OAuth authentication, universal CRUD operations on any Salesforce object.