GitHub MCP App Shim
A lightweight stdio-to-http relay that enables the GitHub MCP server to authenticate using a GitHub App instead of a Personal Access Token. It automatically manages fine-grained permissions and short-lived tokens for secure, organizational AI agent workflows.
README
GitHub MCP App Shim
A lightweight stdio-to-http relay that enables the GitHub MCP Server to authenticate using a GitHub App instead of a Personal Access Token (PAT).
Why use this?
The official GitHub MCP server typically requires a static PAT. This shim allows your AI agent to use a GitHub App's fine-grained permissions and short-lived tokens, which is more secure for organizational use and avoids the 1-year expiration limit of standard tokens.
Features
- Auto-Refresh: Automatically exchanges your App's Private Key for a fresh Installation Access Token every 50 minutes.
- Stdio Bridge: Acts as a local
stdioserver for AI clients (like Claude Desktop) while communicating with GitHub's remote MCP endpoint overhttps. - Environment Driven: No secrets are hardcoded; all identifiers are passed via environment variables.
Prerequisites
- Python 3.9+
- A GitHub App registered in your organization with the necessary permissions (e.g.,
Contents: Read/Write,Metadata: Read-only). - The App must be installed on the target organization or repositories.
Installation
- Clone or copy the
github_shim.pyandpyproject.tomlinto a folder. - Install the dependencies:
pip install .
Finding Your Credentials
| Identifier | Where to find it |
|---|---|
| Client ID | Found on the General settings page of your GitHub App (e.g., Iv23liABC123). |
| Private Key | Generate and download the .pem file from the General settings page. |
| Installation ID | Navigate to your Org Settings > Installed GitHub Apps > Click Configure next to your app. The ID is the numeric string at the end of the URL (e.g., .../installations/12345678). |
Configuration
Claude Desktop
Add the following to your claude_desktop_config.json (found at ~/Library/Application Support/Claude/claude_desktop_config.json on macOS):
{
"mcpServers": {
"github-app-agent": {
"command": "github-mcp-shim",
"env": {
"GH_CLIENT_ID": "YOUR_CLIENT_ID",
"GH_INSTALLATION_ID": "YOUR_INSTALL_ID",
"GH_PRIVATE_KEY_PATH": "/absolute/path/to/your-app.private-key.pem",
"GH_REMOTE_MCP_URL": "https://api.githubcopilot.com/mcp" // optional
}
}
}
}
Security Note
Keep your .pem private key file secure. Anyone with access to this file and your Client ID can impersonate your agent and access the repositories authorized during the app installation.
Recommended Servers
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.
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.
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.
VeyraX MCP
Single MCP tool to connect all your favorite tools: Gmail, Calendar and 40 more.
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.
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.
E2B
Using MCP to run code via e2b.
Neon Database
MCP server for interacting with Neon Management API and databases
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.
Qdrant Server
This repository is an example of how to create a MCP server for Qdrant, a vector search engine.