Skip to content

Commit ed61afc

Browse files
chore: update readme
1 parent 0dff8b8 commit ed61afc

File tree

1 file changed

+70
-3
lines changed

1 file changed

+70
-3
lines changed

README.md

Lines changed: 70 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -16,9 +16,7 @@ automation and interaction capabilities for developers and tools.
1616

1717
1. To run the server in a container, you will need to have [Docker](https://www.docker.com/) installed.
1818
2. [Create a GitHub Personal Access Token](https://github.com/settings/personal-access-tokens/new).
19-
The MCP server can use many of the GitHub APIs, so enable the permissions that you feel comfortable granting your AI tools (to learn more about access tokens, please check out the [documentation](https://docs.github.com/en/authentication/keeping-your-account-and-data-secure/managing-your-personal-access-tokens)).
20-
21-
19+
The MCP server can use many of the GitHub APIs, so enable the permissions that you feel comfortable granting your AI tools (to learn more about access tokens, please check out the [documentation](https://docs.github.com/en/authentication/keeping-your-account-and-data-secure/managing-your-personal-access-tokens)).
2220

2321
## Installation
2422

@@ -95,6 +93,75 @@ If you don't have Docker, you can use `go` to build the binary in the
9593
command with the `GITHUB_PERSONAL_ACCESS_TOKEN` environment variable set to
9694
your token.
9795

96+
## Features Configuration
97+
98+
The GitHub MCP Server supports enabling or disabling specific groups of functionalities via the `--features` flag. This allows you to control which GitHub API capabilities are available to your AI tools.
99+
100+
### Available Features
101+
102+
The following feature groups are available:
103+
104+
| Feature | Description | Default Status |
105+
| --------------- | ------------------------------------------------------------- | -------------- |
106+
| `repos` | Repository-related tools (file operations, branches, commits) | Enabled |
107+
| `issues` | Issue-related tools (create, read, update, comment) | Enabled |
108+
| `search` | Search functionality (code, repositories, users) | Enabled |
109+
| `pull_requests` | Pull request operations (create, merge, review) | Enabled |
110+
| `code_security` | Code scanning alerts and security features | Disabled |
111+
| `experiments` | Experimental features (not considered stable) | Disabled |
112+
| `everything` | Special flag to enable all features | Disabled |
113+
114+
### Specifying Features
115+
116+
You can enable specific features in two ways:
117+
118+
1. **Using Command Line Argument**:
119+
120+
```bash
121+
github-mcp-server --features repos,issues,pull_requests,code_security
122+
```
123+
124+
2. **Using Environment Variable**:
125+
```bash
126+
GITHUB_FEATURES="repos,issues,pull_requests,code_security" ./github-mcp-server
127+
```
128+
129+
The environment variable `GITHUB_FEATURES` takes precedence over the command line argument if both are provided.
130+
131+
### Default Enabled Features
132+
133+
By default, the following features are enabled:
134+
135+
- `repos`
136+
- `issues`
137+
- `pull_requests`
138+
- `search`
139+
140+
### Using With Docker
141+
142+
When using Docker, you can pass the features as environment variables:
143+
144+
```bash
145+
docker run -i --rm \
146+
-e GITHUB_PERSONAL_ACCESS_TOKEN=<your-token> \
147+
-e GITHUB_FEATURES="repos,issues,pull_requests,code_security,experiments" \
148+
ghcr.io/github/github-mcp-server
149+
```
150+
151+
### The "everything" Feature
152+
153+
The special feature `everything` can be provided to enable all available features regardless of their individual settings:
154+
155+
```bash
156+
./github-mcp-server --features everything
157+
```
158+
159+
Or using the environment variable:
160+
161+
```bash
162+
GITHUB_FEATURES="everything" ./github-mcp-server
163+
```
164+
98165
## GitHub Enterprise Server
99166

100167
The flag `--gh-host` and the environment variable `GH_HOST` can be used to set

0 commit comments

Comments
 (0)