Skip to main content

MCP Server for interacting with GitHub Projects V2

Project description

GitHub Projects V2 MCP Server

A Model Context Protocol (MCP) server that provides tools for managing GitHub Projects V2 through Claude and other MCP clients. This server uses the GitHub GraphQL API for interacting with GitHub Projects V2.

Features

  • List and view GitHub Projects V2 for users and organizations
  • Get project fields and items (issues, PRs, draft issues)
  • Create issues and add them to projects
  • Create draft issues directly in projects
  • Update project item field values
  • Delete items from projects

Setup

  1. Clone the repository:

    git clone git@github.com:Rizz-Buzz/github-projects-mcp.git
    cd github-projects-mcp
    
  2. Create and activate a virtual environment:

    uv venv
    source venv/bin/activate
    
  3. Install dependencies:

    uv pip install -e .
    
  4. Set your GitHub token as an environment variable:

    Create a Github Personal Access Token, and give the necessary permissions. The necessary permissions are: repo, project, and read:org.

    Add the token to .env file after running command:

    cp .env.example .env
    
    export GITHUB_TOKEN=your_personal_access_token
    

Usage

This server can be used with any MCP client, such as Claude Desktop. Add it to your MCP client configuration (e.g., claude_desktop_config.json).

Here's an example configuration using uv as the command runner:

{
  "mcpServers": {
    "github-projects": {
      "command": "uv",
      "args": [
        "--directory",
        "/path/to/github-projects-mcp",
        "run",
        "mcp-github-projects"
      ],
      "env": {
        "GITHUB_TOKEN": "your_pat_here"
      }
    }
  }
}

Make sure to replace /path/to/github-projects-mcp and your_pat_here with your actual repository path and GitHub Personal Access Token.

Available Tools

  • list_projects: List GitHub Projects V2 for a given organization or user
  • get_project_fields: Get fields available in a GitHub Project V2
  • get_project_items: Get items in a GitHub Project V2 (supports filtering by state or custom single-select fields)
  • create_issue: Create a new GitHub issue
  • add_issue_to_project: Add an existing GitHub issue to a Project V2
  • update_project_item_field: Update a field value for a project item
  • create_draft_issue: Create a draft issue directly in a GitHub Project V2
  • delete_project_item: Delete an item from a GitHub Project V2

See tool documentation in the server code for detailed usage information.

Development

The project is structured as follows:

  • src/github_projects_mcp/: Main package directory
    • server.py: MCP server implementation with tool definitions
    • github_client.py: GraphQL client for GitHub API interactions

To contribute, make sure to:

  1. Add proper error handling for all GraphQL operations
  2. Add type annotations for all functions and parameters
  3. Update documentation when adding new tools or features

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

mcp_github_projects-0.1.0.tar.gz (22.6 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

mcp_github_projects-0.1.0-py3-none-any.whl (15.1 kB view details)

Uploaded Python 3

File details

Details for the file mcp_github_projects-0.1.0.tar.gz.

File metadata

  • Download URL: mcp_github_projects-0.1.0.tar.gz
  • Upload date:
  • Size: 22.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.5.10

File hashes

Hashes for mcp_github_projects-0.1.0.tar.gz
Algorithm Hash digest
SHA256 6d0b439a88854a9f9d9489b193623286a7fcf2c3aaebcc392cbb2af396431c07
MD5 1ddc4f28fcab233a04d82a402539c256
BLAKE2b-256 6d88f291062c8860833fc4f5c5aec2b4d46ccc94a06839d532eb4cae0b0ae9c1

See more details on using hashes here.

File details

Details for the file mcp_github_projects-0.1.0-py3-none-any.whl.

File metadata

File hashes

Hashes for mcp_github_projects-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 6df4cc540b26a6886ec398334104833084ebdff347b56e08bec512f13b6aa73c
MD5 bd81361fca49d8e9ba507a94c410544f
BLAKE2b-256 47c2251048447b3e2ddfdc4c95acbd1c0d31952571c74b3a496d24e72900d7df

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page