GI

github-mcp-server

Provides setup patterns and configuration options for connecting AI agents to GitHub via the Model Context Protocol.

Install

mkdir -p .claude/skills/github-mcp-server && curl -L -o skill.zip "https://agentskills.codes/api/skills/download/2588" && unzip -o skill.zip -d .claude/skills/github-mcp-server && rm skill.zip

Installs to .claude/skills/github-mcp-server

Activation

This is the description your AI agent reads to decide when to run this skill — the better it matches your request, the more reliably it fires.

Reference for GitHub MCP server tools, methods, and usage patterns.
67 charsno explicit “when” trigger
Intermediate

Key capabilities

  • Configure GitHub MCP server in local Docker mode
  • Configure GitHub MCP server in remote hosted mode
  • Specify toolsets for GitHub API access
  • Enable read-only mode for GitHub operations
  • Set up custom authentication with a GitHub token

How it works

The skill configures the GitHub MCP server to operate in either a local Docker container or connect to a remote hosted service, defining the accessible GitHub API toolsets and authentication method.

Inputs & outputs

You give it
Configuration parameters for GitHub MCP server mode, toolsets, read-only status, and authentication token
You get back
Configured GitHub MCP server providing programmatic access to GitHub's API

When to use github-mcp-server

  • Setting up GitHub MCP server
  • Configuring GitHub API access for agents
  • Troubleshooting MCP connectivity
  • Restricting API access via read-only mode

About this skill

GitHub MCP Server Documentation

This file documents the GitHub MCP (Model Context Protocol) server, including tools and configuration options.

Note: This file is automatically generated and updated by the github-mcp-tools-report.md workflow. Manual edits may be overwritten.

Last Updated: [To be filled by workflow]

Overview

The GitHub MCP server provides AI agents with programmatic access to GitHub's API through the Model Context Protocol. It supports two modes of operation:

Local Mode (Docker-based)

  • Runs as a Docker container on the GitHub Actions runner
  • Uses GITHUB_PERSONAL_ACCESS_TOKEN environment variable for authentication
  • Configurable toolsets via GITHUB_TOOLSETS environment variable
  • Supports read-only mode via GITHUB_READ_ONLY environment variable

Remote Mode (Hosted)

  • Connects to hosted GitHub MCP server at https://api.githubcopilot.com/mcp/
  • Uses Bearer token authentication in HTTP headers
  • Supports read-only mode via X-MCP-Readonly header
  • No Docker container required

Configuration

Basic Configuration

Local Mode (Docker):

tools:
  github:
    mode: "local"
    toolsets: [default]  # or [repos, issues, pull_requests]

Remote Mode (Hosted):

tools:
  github:
    mode: "remote"
    toolsets: [default]  # or [repos, issues, pull_requests]

Read-Only Mode

To restrict the GitHub MCP server to read-only operations:

tools:
  github:
    mode: "remote"
    read-only: true
    toolsets: [repos, issues]

Custom Authentication

Use a custom GitHub token instead of the default:

tools:
  github:
    mode: "remote"
    github-token: "${{ secrets.CUSTOM_GITHUB_PAT }}"
    toolsets: [repos, issues]

Available Toolsets

The GitHub MCP server organizes tools into logical toolsets. You can enable specific toolsets, use [default] for the recommended defaults, or use [all] to enable everything.

:::note[Why Use Toolsets?] The allowed: pattern for listing individual GitHub tools is not recommended for new workflows. Individual tool names may change between GitHub MCP server versions, but toolsets provide a stable API. Always use toolsets: instead. See Migration from Allowed to Toolsets for guidance on updating existing workflows. :::

:::tip[Best Practice] Always use toolsets: for GitHub tools. Toolsets provide:

  • Stability: Tool names may change between MCP server versions, but toolsets remain stable
  • Better organization: Clear groupings of related functionality
  • Complete functionality: Get all related tools automatically
  • Reduced verbosity: Cleaner configuration
  • Future-proof: New tools are automatically included as they're added :::

Recommended Default Toolsets

The following toolsets are enabled by default when toolsets: is not specified:

  • context - User and environment context (strongly recommended)
  • repos - Repository management
  • issues - Issue management
  • pull_requests - Pull request operations

Note: The users toolset is not included by default and must be explicitly specified if needed.

All Available Toolsets

ToolsetDescriptionCommon Tools
contextUser and environment contextget_teams, get_team_members
reposRepository managementget_repository, get_file_contents, search_code, list_commits
issuesIssue managementissue_read, list_issues, create_issue, search_issues
pull_requestsPull request operationspull_request_read, list_pull_requests, create_pull_request
actionsGitHub Actions/CI/CDlist_workflows, list_workflow_runs, download_workflow_run_artifact
code_securityCode scanning and securitylist_code_scanning_alerts ⚠️ (always include state: open and severity: critical,high), get_code_scanning_alert
dependabotDependency managementDependabot alerts and updates
discussionsGitHub Discussionslist_discussions, create_discussion
experimentsExperimental featuresUnstable/preview APIs
gistsGist operationscreate_gist, list_gists
labelsLabel managementget_label, list_labels, create_label
notificationsNotificationslist_notifications, mark_notifications_read
orgsOrganization managementget_organization, list_organizations
projectsGitHub ProjectsProject board operations
secret_protectionSecret scanningSecret detection and management
security_advisoriesSecurity advisoriesAdvisory creation and management
stargazersRepository starsStar-related operations
usersUser profilesget_me ⚠️ (see note below), get_user, list_users
searchAdvanced searchSearch across repos, code, users

:::caution[get_me returns 403 under the integration token] get_me is not recommended in agentic workflows. It returns HTTP 403 when called under the GitHub Actions integration token (which is the default in all gh-aw runs). Do not call get_me to determine the agent's identity.

Canonical identity source: The <github-context> block is injected at the start of every workflow prompt and contains actor, repository, run_id, and other context values. Always read identity from there. :::

Available Tools by Toolset

This section maps individual tools to their respective toolsets to help with migration from allowed: to toolsets:.

Context Toolset

  • get_teams - List teams the user belongs to
  • get_team_members - List members of a specific team

Repos Toolset

  • get_repository - Get repository information
  • get_file_contents - Read file contents from repository
  • search_code - Search code across repositories
  • list_commits - List commits in a repository
  • get_commit - Get details of a specific commit
  • get_latest_release - Get the latest release
  • list_releases - List all releases

Issues Toolset

  • issue_read - Read issue details
  • list_issues - List issues in a repository
  • create_issue - Create a new issue
  • update_issue - Update an existing issue
  • search_issues - Search issues across repositories
  • add_reaction - Add reaction to an issue or comment
  • create_issue_comment - Add a comment to an issue

Pull Requests Toolset

  • pull_request_read - Read pull request details
  • list_pull_requests - List pull requests in a repository
  • get_pull_request - Get details of a specific pull request
  • create_pull_request - Create a new pull request
  • search_pull_requests - Search pull requests across repositories

When invoking list_pull_requests from workflow prompts/templates:

  • Default to a small page size (perPage: 10 unless a smaller/larger value is justified).
  • On GitHub MCP server ≥ 1.6.0 with the fields_param feature (enabled automatically in Insiders mode), pass fields: [number, title, state, html_url] (or whichever top-level fields you need) to reduce response size. The same fields parameter is available on list_issues, search_issues, search_pull_requests, list_commits, list_releases, and search_code. For get_file_contents, fields only reduces directory listings; use fields: [name, type, size, path] to check file metadata before deciding whether to read a file.
  • Before using get_file_contents on a file, list its parent directory with fields: [name, type, size, path]. If the file is large or you only need a header/section, use a bounded excerpt such as a raw file URL with an HTTP range or another available ranged-read tool instead of fetching the whole file.
  • On older servers, request minimal_output: true when the installed MCP server exposes that input (minimal output trims non-essential nested fields such as large head/base payloads).
  • Confirm parameter support in the method schema from mcp list-tools or the tool docs for your server version.

Actions Toolset

  • list_workflows - List GitHub Actions workflows
  • list_workflow_runs - List workflow runs
  • get_workflow_run - Get details of a specific workflow run
  • download_workflow_run_artifact - Download workflow artifacts

Code Security Toolset

  • list_code_scanning_alerts - List code scanning alerts
  • get_code_scanning_alert - Get details of a specific alert
  • create_code_scanning_alert - Create a code scanning alert

When invoking list_code_scanning_alerts from workflow prompts/templates, always include state: open and severity: critical,high to bound the response size and avoid oversized payloads.

Discussions Toolset

  • list_discussions - List discussions in a repository
  • create_discussion - Create a new discussion

Labels Toolset

  • get_label - Get label details
  • list_labels - List labels in a repository
  • create_label - Create a new label

Users Toolset

  • get_me - ⚠️ Not recommended — returns HTTP 403 under the integration token. Use the <github-context> block (provided at the start of every prompt) to read your identity: actor, repository, run_id, etc.
  • get_user - Get user profile information
  • list_users - List users

Notifications Toolset

  • list_notifications - List user notifications
  • mark_notifications_read - Mark notifications as read

Organizations Toolset

  • get_organization - Get organization details
  • list_organizations - List organizations

Gists Toolset

  • create_gist - Create a new gist
  • list_gists - List user's gists

Authentication Details

Remote Mode Authentication

The remote mode uses Bearer token authentication:

Headers:

  • Authorization: Bearer <token> - Required for authentication
  • X-MCP-Readonly: true - Optional, enables read-only mode

Token Source:

  • Default: ${{ secrets.GH_AW_GITHUB_TOKEN }} or ${{ secrets.GITHUB_TOKEN }}
  • Custom: Configure via github-token field

Loca


Content truncated.

When not to use it

  • When individual GitHub tools are preferred over stable toolsets
  • When `get_me` is used to determine the agent's identity

Limitations

  • Individual tool names may change between GitHub MCP server versions
  • The `users` toolset is not included by default
  • `get_me` returns HTTP 403 under the GitHub Actions integration token

How it compares

This skill provides structured configuration for GitHub API access via MCP toolsets, offering stability and organization compared to manually managing individual API tools.

Compared to similar skills

github-mcp-server side by side with the closest alternatives in the catalog.

SkillInstallsUpdatedSafetyDifficulty
github-mcp-server (this skill)527dNo flagsIntermediate
mcp-builder1363moReviewAdvanced
mcp-integration218moReviewIntermediate
opencode-orchestrator-creator89moReviewIntermediate

Try saying

Example prompts that trigger this skill in your AI assistant.

You might also like

mcp-builder

anthropics

Guide for creating high-quality MCP (Model Context Protocol) servers that enable LLMs to interact with external services through well-designed tools. Use when building MCP servers to integrate external APIs or services, whether in Python (FastMCP) or Node/TypeScript (MCP SDK).

136215

mcp-integration

anthropics

This skill should be used when the user asks to "add MCP server", "integrate MCP", "configure MCP in plugin", "use .mcp.json", "set up Model Context Protocol", "connect external service", mentions "${CLAUDE_PLUGIN_ROOT} with MCP", or discusses MCP server types (SSE, stdio, HTTP, WebSocket). Provides comprehensive guidance for integrating Model Context Protocol servers into Claude Code plugins for external tool and service integration.

21123

opencode-orchestrator-creator

IgorWarzocha

Creates universal OpenCode orchestrator folder structure with specialized agent that can manage swarm servers via curl commands

8104

claude-opus-4-5-migration

anthropics

Migrate prompts and code from Claude Sonnet 4.0, Sonnet 4.5, or Opus 4.1 to Opus 4.5. Use when the user wants to update their codebase, prompts, or API calls to use Opus 4.5. Handles model string updates and prompt adjustments for known Opus 4.5 behavioral differences. Does NOT migrate Haiku 4.5.

9101

mcp-management

mrgoonie

Manage Model Context Protocol (MCP) servers - discover, analyze, and execute tools/prompts/resources from configured MCP servers. Use when working with MCP integrations, need to discover available MCP capabilities, filter MCP tools for specific tasks, execute MCP tools programmatically, access MCP prompts/resources, or implement MCP client functionality. Supports intelligent tool selection, multi-server management, and context-efficient capability discovery.

6100

n8n-mcp-orchestrator

manutej

Expert MCP (Model Context Protocol) orchestration with n8n workflow automation. Master bidirectional MCP integration, expose n8n workflows as AI agent tools, consume MCP servers in workflows, build agentic systems, orchestrate multi-agent workflows, and create production-ready AI-powered automation pipelines with Claude Code integration.

795

Search skills

Search the agent skills registry