Skip to content

Commit acd7929

Browse files
Document that GitHub App and server-to-server tokens are not filtered
1 parent c2450ce commit acd7929

File tree

1 file changed

+7
-1
lines changed

1 file changed

+7
-1
lines changed

docs/scope-filtering.md

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
The GitHub MCP Server automatically filters available tools based on your classic Personal Access Token's (PAT) OAuth scopes. This ensures you only see tools that your token has permission to use, reducing clutter and preventing errors from attempting operations your token can't perform.
44

5-
> **Note:** This feature applies to **classic PATs** (tokens starting with `ghp_`). Fine-grained PATs and other token types don't support scope detection.
5+
> **Note:** This feature applies to **classic PATs** (tokens starting with `ghp_`). Fine-grained PATs, GitHub App installation tokens, and server-to-server tokens don't support scope detection and show all tools.
66
77
## How It Works
88

@@ -17,6 +17,8 @@ When the server starts with a classic PAT, it makes a lightweight HTTP HEAD requ
1717
| **Classic PAT** (`ghp_`) | Filters tools at startup based on token scopes—tools requiring unavailable scopes are hidden |
1818
| **OAuth** (remote server only) | Uses OAuth scope challenges—when a tool needs a scope you haven't granted, you're prompted to authorize it |
1919
| **Fine-grained PAT** (`github_pat_`) | No filtering—all tools shown, API enforces permissions |
20+
| **GitHub App** (`ghs_`) | No filtering—all tools shown, permissions based on app installation |
21+
| **Server-to-server** | No filtering—all tools shown, permissions based on app/token configuration |
2022

2123
With OAuth, the remote server can dynamically request additional scopes as needed. With PATs, scopes are fixed at token creation, so the server proactively hides tools you can't use.
2224

@@ -60,6 +62,10 @@ WARN: failed to fetch token scopes, continuing without scope filtering
6062

6163
**Fine-grained PATs** (`github_pat_` prefix) use a different permission model based on repository access and specific permissions rather than OAuth scopes. They don't return the `X-OAuth-Scopes` header, so scope filtering is skipped. All tools will be available, but the GitHub API will still enforce permissions at the API level—you'll get errors if you try to use tools your token doesn't have permission for.
6264

65+
## GitHub App and Server-to-Server Tokens
66+
67+
**GitHub App installation tokens** (`ghs_` prefix) and other server-to-server tokens use a permission model based on the app's installation permissions rather than OAuth scopes. These tokens don't return the `X-OAuth-Scopes` header, so scope filtering is skipped. The GitHub API enforces permissions based on the app's configuration.
68+
6369
## Troubleshooting
6470

6571
| Problem | Cause | Solution |

0 commit comments

Comments
 (0)