GitHub MCP Server

GitHub MCP Server

An MCP server that provides tools for interacting with the GitHub API, enabling AI assistants to query repositories, pull requests, issues, commits, users, and more.

Category
Visit Server

README

GitHub MCP Server

An MCP (Model Context Protocol) server that provides tools for interacting with the GitHub API. This server enables AI assistants to query repositories, pull requests, issues, commits, users, and more.

Features

  • 🔍 Search repositories and users
  • 📦 Get repository information
  • 🔀 List and view pull requests
  • 🐛 List and view issues
  • 📝 View commits and compare branches
  • 👤 Get user information
  • 📄 Read file contents from repositories
  • 🏷️ List releases and branches

Prerequisites

  • Node.js (v18 or higher)
  • A GitHub Personal Access Token

Installation

  1. Clone this repository:
git clone https://github.com/grysonbaltazar/github-mcp.git
cd github-mcp
  1. Install dependencies:
npm install
  1. Build the TypeScript code:
npm run build

Configuration

Get a GitHub Token

  1. Go to GitHub Settings → Developer settings → Personal access tokens
  2. Click "Generate new token (classic)"
  3. Give it a name (e.g., "MCP Server")
  4. Select scopes:
    • repo - Full control of private repositories
    • read:user - Read user profile data
    • read:org - Read org and team membership (optional)
  5. Generate and copy the token

For Claude Desktop

Edit ~/Library/Application Support/Claude/claude_desktop_config.json:

{
  "mcpServers": {
    "github": {
      "command": "node",
      "args": ["/path/to/github-mcp/build/index.js"],
      "env": {
        "GITHUB_TOKEN": "your_github_token_here"
      }
    }
  }
}

For Cursor

Edit ~/.cursor/mcp_config.json:

{
  "mcpServers": {
    "github": {
      "command": "node",
      "args": ["/path/to/github-mcp/build/index.js"],
      "env": {
        "GITHUB_TOKEN": "your_github_token_here"
      }
    }
  }
}

Usage

Once configured, the MCP server provides the following tools:

  • get_repository - Get detailed information about a repository
  • list_user_repos - List repositories for a user or organization
  • search_repositories - Search for repositories on GitHub
  • get_pull_request - Get details about a specific pull request
  • list_pull_requests - List pull requests for a repository
  • get_pr_files - Get the list of files changed in a pull request
  • get_pr_comments - Get review comments on a pull request
  • get_commit - Get details about a specific commit
  • list_commits - List commits in a repository
  • compare_commits - Compare two commits or branches
  • get_issue - Get details about a specific issue
  • list_issues - List issues for a repository
  • get_issue_comments - Get comments on an issue
  • list_branches - List branches in a repository
  • get_branch - Get details about a specific branch
  • get_user - Get information about a GitHub user
  • search_users - Search for users on GitHub
  • get_file_contents - Get the contents of a file in a repository
  • list_releases - List releases for a repository
  • get_latest_release - Get the latest release for a repository

Development

Testing with MCP Inspector

npx @modelcontextprotocol/inspector node build/index.js

This will open a web interface where you can test all the tools interactively.

Watch Mode

npm run watch

License

MIT

Contributing

Contributions are welcome! Please feel free to submit a Pull Request.

Recommended Servers

playwright-mcp

playwright-mcp

A Model Context Protocol server that enables LLMs to interact with web pages through structured accessibility snapshots without requiring vision models or screenshots.

Official
Featured
TypeScript
Magic Component Platform (MCP)

Magic Component Platform (MCP)

An AI-powered tool that generates modern UI components from natural language descriptions, integrating with popular IDEs to streamline UI development workflow.

Official
Featured
Local
TypeScript
Audiense Insights MCP Server

Audiense Insights MCP Server

Enables interaction with Audiense Insights accounts via the Model Context Protocol, facilitating the extraction and analysis of marketing insights and audience data including demographics, behavior, and influencer engagement.

Official
Featured
Local
TypeScript
VeyraX MCP

VeyraX MCP

Single MCP tool to connect all your favorite tools: Gmail, Calendar and 40 more.

Official
Featured
Local
graphlit-mcp-server

graphlit-mcp-server

The Model Context Protocol (MCP) Server enables integration between MCP clients and the Graphlit service. Ingest anything from Slack to Gmail to podcast feeds, in addition to web crawling, into a Graphlit project - and then retrieve relevant contents from the MCP client.

Official
Featured
TypeScript
Kagi MCP Server

Kagi MCP Server

An MCP server that integrates Kagi search capabilities with Claude AI, enabling Claude to perform real-time web searches when answering questions that require up-to-date information.

Official
Featured
Python
E2B

E2B

Using MCP to run code via e2b.

Official
Featured
Neon Database

Neon Database

MCP server for interacting with Neon Management API and databases

Official
Featured
Exa Search

Exa Search

A Model Context Protocol (MCP) server lets AI assistants like Claude use the Exa AI Search API for web searches. This setup allows AI models to get real-time web information in a safe and controlled way.

Official
Featured
Qdrant Server

Qdrant Server

This repository is an example of how to create a MCP server for Qdrant, a vector search engine.

Official
Featured