mcpField
G
GitHub MCP Server

GitHub MCP Server

Local
github.com/loidodevVersion Control1Updated 83w ago

About GitHub MCP Server

GitHub MCP Server lets AI applications interact with the GitHub API to manage repositories and file changes. It supports repository lookup and creation, commits, pushes, and pulls.

Key features

  1. 01List authenticated-user repositories
  2. 02Retrieve repository details
  3. 03Create repositories
  4. 04Commit file changes
  5. 05Push and pull branches

Use cases

  1. 01Review repositories available to an account
  2. 02Create a repository with an initial README
  3. 03Commit files to a branch
  4. 04Push or pull branch changes

MCP support

Exposes GitHub API operations as tools for MCP clients, including repository listing and details, repository creation, commits, pushes, and pulls.

Configuration

Local server config is the same for every client. Copy it into your client’s MCP config file.

No install method listed yet

We haven’t collected a package or remote endpoint for this server. Follow the instructions in the project README.

Repository

Tools

No tool list yet

Local servers expose tools only once running on your machine, and the maintainer has not provided a tool list.

Details

From the project README

GitHub MCP Server

A Model Context Protocol server for interacting with the GitHub API.

Features

Tools
  • list_user_repos: List repositories for the authenticated user

    • Parameters:
      • type (optional): "owner", "all", or "member" (default: "owner")
      • sort (optional): "created", "updated", "pushed", or "full_name" (default: "full_name")
      • direction (optional): "asc" or "desc" (default: "asc")
      • per_page (optional): Number of results per page (default: 30, max: 100)
      • page (optional): Page number (default: 1)
  • get_repo: Get details about a specific repository

    • Parameters:
      • repo (required): The name of the repository
      • owner (optional): The account owner. If not provided, uses authenticated user.
  • create_repo: Create a new repository

    • Parameters:
      • name (required): The name of the repository
      • description (optional): A short description
      • private (optional): Whether the repository is private (default: false)
      • auto_init (optional): Create initial commit with empty README (default: false)
  • create_commit: Create a new commit with file changes

    • Parameters:
      • repo (required): The name of the repository
      • owner (optional): The account owner. If not provided, uses authenticated user.
      • branch (optional): The branch name (default: "main")
      • message (required): The commit message
      • files (required): Array of files to include in commit
        • Each file requires:
          • path: File path relative to repository root
          • content: File content
  • push: Push changes to a remote repository

    • Parameters:
      • repo (required): The name of the repository
      • owner (optional): The account owner. If not provided, uses authenticated user.
      • branch (optional): The branch name (default: "main")
  • pull: Pull changes from a remote repository

    • Parameters:
      • repo (required): The name of the repository
      • owner (optional): The account owner. If not provided, uses authenticated user.
      • branch (required): The branch name

Requirements

  • Node.js 18+
  • GitHub personal access token with appropriate permissions
  • Set GITHUB_TOKEN environment variable

Installation

npm install
npm run build

Configuration

Set your GitHub token as an environment variable:

export GITHUB_TOKEN=your_token_here

Usage

Run the server:

npm start

Development

For development with auto-rebuild:

npm run watch

Debugging

Use the MCP Inspector:

npm run inspector

Comments

Markdown supported

New to MCP?

From what the protocol is to installing your first server, these answers cover most first questions.

An open protocol that defines how AI applications connect to external tools and data in a uniform way. Clients talk to the model; MCP servers provide tools, resources and prompt templates. They exchange standard messages, so one server can be reused by many clients.