This package is an MCP stdio server. The client starts the process and communicates over stdin/stdout.
See also: mcp-tools.md (tool ids, parameters, JSON shapes), HUMANS.md (dev, CI, publishing), AGENTS.md (contributors).
- Prerequisites
- GitHub Packages
- Ways to run the binary
- Configuration shape (stdio)
- Cursor
- Visual Studio Code (GitHub Copilot)
- Claude Desktop
- Zed
- Other clients and CLIs
- From source (this repository)
- Troubleshooting
- GitHub token: All tools require a GitHub personal access token. Set
GITHUB_TOKENorGH_TOKENin the environment, or haveghCLI authenticated (gh auth login). Required scopes:repo(for private repos),read:org(fororg_pulse). See mcp-tools.md. - Node.js >= 22 if you use
npx, or Bun if you usebunx/bun(seepackage.jsonengines/packageManager).
Every version tag on this repo is published to the GitHub npm registry as @rethunk-ai/github-mcp (scope matches the GitHub org). The npmjs package @rethunk/github-mcp is also maintained and is current as of v1.0.0.
-
Create a GitHub personal access token with at least
read:packages. -
In
~/.npmrcor the project.npmrc(do not commit secrets):@rethunk-ai:registry=https://npm.pkg.github.com //npm.pkg.github.com/:_authToken=YOUR_TOKEN_HERE
-
Install or run:
npx -y @rethunk-ai/github-mcp
Confirm the package runs (each starts the stdio server until EOF). npmjs name:
npx -y @rethunk/github-mcp
bunx @rethunk/github-mcp
npm install -g @rethunk/github-mcp && rethunk-github-mcpGitHub Packages name (after configuring .npmrc):
npx -y @rethunk-ai/github-mcp
bunx @rethunk-ai/github-mcpPublished entrypoint: dist/server.js (see bin / exports).
Across clients you always provide:
- A command (e.g.
npx,bunx,bun,node). - Arguments that resolve to this package's server.
- An
envblock with your GitHub token.
Register the server under a stable name (this documentation uses rethunk-github). Tools appear as {serverName}_{toolName} (e.g. rethunk-github_repo_status).
User scope: ~/.cursor/mcp.json. Project scope: .cursor/mcp.json.
{
"mcpServers": {
"rethunk-github": {
"command": "npx",
"args": ["-y", "@rethunk/github-mcp"],
"env": {
"GITHUB_TOKEN": "ghp_..."
}
}
}
}After editing, reload MCP (Command Palette: reload / restart MCP).
.vscode/mcp.json or user MCP config (Command Palette: MCP: Open User Configuration):
{
"servers": {
"rethunk-github": {
"type": "stdio",
"command": "npx",
"args": ["-y", "@rethunk/github-mcp"],
"env": {
"GITHUB_TOKEN": "ghp_..."
}
}
}
}Config file (create if missing):
| OS | Path |
|---|---|
| macOS | ~/Library/Application Support/Claude/claude_desktop_config.json |
| Windows | %APPDATA%\Claude\claude_desktop_config.json |
| Linux | ~/.config/Claude/claude_desktop_config.json |
{
"mcpServers": {
"rethunk-github": {
"command": "npx",
"args": ["-y", "@rethunk/github-mcp"],
"env": {
"GITHUB_TOKEN": "ghp_..."
}
}
}
}Restart Claude Desktop after saving.
~/.config/zed/settings.json:
{
"context_servers": {
"rethunk-github": {
"command": "npx",
"args": ["-y", "@rethunk/github-mcp"],
"env": {
"GITHUB_TOKEN": "ghp_..."
}
}
}
}Any MCP host that supports stdio can use the same command / args / env pattern. Map:
- Command:
npx(orbunx,node, etc.) - Args: e.g.
["-y", "@rethunk/github-mcp"] - Env:
{ "GITHUB_TOKEN": "..." }
Official protocol overview: modelcontextprotocol.io.
For contributors working inside a clone of rethunk-github-mcp:
- Dependencies, build, and CI parity: HUMANS.md — Development.
- Run the dev server (no
dist/required):GITHUB_TOKEN=ghp_... bun src/server.ts(stdio MCP).
MCP registration for a local checkout: this repo ships .cursor/mcp.json using bun + ["src/server.ts"]; open the workspace at the repository root.
| Issue | What to try |
|---|---|
github_auth_missing |
Set GITHUB_TOKEN or GH_TOKEN in the env block of your MCP config, or run gh auth login. |
| Tools missing / stale | Restart the MCP host or use its "reload MCP / reset tools" action. |
npx / bun not found |
Install Node >= 22 or Bun; use full paths in config if PATH is minimal. |
org_not_found |
Verify the org login; the token needs read:org scope for org access. |
| Rate limits | GitHub API has rate limits (5,000/hr REST, 5,000 points/hr GraphQL). Reduce maxRepos/maxResults if hitting limits. |
| GitHub Enterprise | Set GITHUB_API_URL (and optionally GITHUB_GRAPHQL_URL) in the env block. |