MCP.so
Sign In

GitHub GraphQL API MCP Server

@wanzunz

Basic information

Category

Version Control

Transports

stdio

Author

wanzunz

About GitHub GraphQL API MCP Server

A Model Control Protocol (MCP) server for exploring the GitHub GraphQL schema and executing optimized queries. Provides AI assistants with efficient GitHub data retrieval capabilities through GraphQL.

GitHub GraphQL API MCP Server config

Add this server to your MCP-compatible client using the configuration below.

{
  "mcpServers": {
    "github_graphql_api_mcp": {
      "command": "python",
      "args": [
        "-m",
        "venv",
        ".venv"
      ]
    }
  }
}

GitHub GraphQL API MCP Server tools

Tool list not available yet

This listing does not currently have a tool list to display. This does not mean the server has no tools; check its documentation for supported capabilities.

We auto-extract tools from the README. The maintainer can list them under a ## Tools heading to populate this section.

Overview

What is GitHub GraphQL API MCP?

An MCP (Model Control Protocol) server that enables querying and using the GitHub GraphQL API. It allows users to explore the GraphQL schema, view type documentation, and execute custom GraphQL queries through MCP clients like Claude AI.

How to use GitHub GraphQL API MCP?

Clone the repository, install dependencies with Poetry (poetry install), activate the virtual environment, create a .env file with a GITHUB_TOKEN, and run python github_graphql_api_mcp_server.py. For one-click startup, configure the server in the Claude desktop app by providing the Python interpreter path, project directory, and script name.

Key features of GitHub GraphQL API MCP

  • Query GitHub GraphQL schema root types (Query/Mutation)
  • Get detailed documentation for specific types and fields
  • Execute GitHub GraphQL API queries directly
  • Precisely retrieve needed data, reducing token consumption
  • Bilingual support (English and Chinese)

Use cases of GitHub GraphQL API MCP

  • Query repository basic information (name, description, star count, branches)
  • Retrieve issue lists, details, and comments for a repository
  • Access user profiles and contribution statistics
  • View pull request status, comments, and merge info
  • Analyze repository contribution trends and dependency health

Frequently asked questions

1

What are the prerequisites?

Python 3.10 or higher, a GitHub personal access token, and Poetry (recommended) for dependency management.

2

How do I set up authentication?

Create a `.env` file in the project root with `GITHUB_TOKEN="your_github_token_here"`. Do not commit this file to version control.

3

What tools does the server provide?

It provides four tools: `print_type_field` (query fields of root types), `graphql_schema_root_type` (documentation for Query/Mutation), `graphql_schema_type` (documentation for specific types), and `call_github_graphql` (execute custom GraphQL queries).

4

How can I start the server for use with Claude Desktop?

Configure `mcpServers` in Claude desktop settings with the Python interpreter path, the `--directory` argument pointing to the project folder, and `run github_graphql_api_mcp_server.py`. Example configurations are provided in the README.

5

What are the advantages of using GraphQL over REST for the GitHub API?

GraphQL allows precise data retrieval (only needed fields), reduces token consumption, enables single-request access to multiple related resources, is self-documenting, and has a strong type system to reduce errors.

Comments

More Version Control MCP servers