Skip to content

Commit 3cd8be6

Browse files
committed
Merge branch 'main' of https://github.com/github/github-mcp-server into consolidate-prs-write
2 parents 82ac788 + bcc5275 commit 3cd8be6

21 files changed

+1890
-76
lines changed

.github/workflows/docker-publish.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -127,3 +127,4 @@ jobs:
127127
# This step uses the identity token to provision an ephemeral certificate
128128
# against the sigstore community Fulcio instance.
129129
run: echo "${TAGS}" | xargs -I {} cosign sign --yes {}@${DIGEST}
130+

.github/workflows/registry-releaser.yml

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,25 @@ jobs:
2929
echo "Skipping tag fetch - already on tag ${{ github.ref_name }}"
3030
fi
3131
32+
- name: Wait for Docker image
33+
run: |
34+
if [[ "${{ github.ref_type }}" == "tag" ]]; then
35+
TAG="${{ github.ref_name }}"
36+
else
37+
TAG=$(git tag --sort=-version:refname | grep -E '^v[0-9]+\.[0-9]+\.[0-9]+' | head -n1)
38+
fi
39+
IMAGE="ghcr.io/github/github-mcp-server:$TAG"
40+
41+
for i in {1..10}; do
42+
if docker manifest inspect "$IMAGE" &>/dev/null; then
43+
echo "✅ Docker image ready: $TAG"
44+
break
45+
fi
46+
[ $i -eq 10 ] && { echo "❌ Timeout waiting for $TAG after 5 minutes"; exit 1; }
47+
echo "⏳ Waiting for Docker image ($i/10)..."
48+
sleep 30
49+
done
50+
3251
- name: Install MCP Publisher
3352
run: |
3453
git clone --quiet https://github.com/modelcontextprotocol/registry publisher-repo

README.md

Lines changed: 45 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -340,6 +340,7 @@ The following sets of tools are available (all are on by default):
340340
| `experiments` | Experimental features that are not considered stable yet |
341341
| `gists` | GitHub Gist related tools |
342342
| `issues` | GitHub Issues related tools |
343+
| `labels` | GitHub Labels related tools |
343344
| `notifications` | GitHub Notifications related tools |
344345
| `orgs` | GitHub Organization related tools |
345346
| `projects` | GitHub Projects related tools |
@@ -599,6 +600,11 @@ The following sets of tools are available (all are on by default):
599600
- `perPage`: Results per page for pagination (min 1, max 100) (number, optional)
600601
- `repo`: Repository name (string, required)
601602

603+
- **get_label** - Get a specific label from a repository.
604+
- `name`: Label name. (string, required)
605+
- `owner`: Repository owner (username or organization name) (string, required)
606+
- `repo`: Repository name (string, required)
607+
602608
- **list_issue_types** - List available issue types
603609
- `owner`: The organization owner of the repository (string, required)
604610

@@ -613,6 +619,11 @@ The following sets of tools are available (all are on by default):
613619
- `since`: Filter by date (ISO 8601 timestamp) (string, optional)
614620
- `state`: Filter by state, by default both open and closed issues are returned when not provided (string, optional)
615621

622+
- **list_label** - List labels from a repository or an issue
623+
- `issue_number`: Issue number - if provided, lists labels on the specific issue (number, optional)
624+
- `owner`: Repository owner (username or organization name) - required for all operations (string, required)
625+
- `repo`: Repository name - required for all operations (string, required)
626+
616627
- **list_sub_issues** - List sub-issues
617628
- `issue_number`: Issue number (number, required)
618629
- `owner`: Repository owner (string, required)
@@ -661,6 +672,31 @@ The following sets of tools are available (all are on by default):
661672

662673
<details>
663674

675+
<summary>Labels</summary>
676+
677+
- **get_label** - Get a specific label from a repository.
678+
- `name`: Label name. (string, required)
679+
- `owner`: Repository owner (username or organization name) (string, required)
680+
- `repo`: Repository name (string, required)
681+
682+
- **label_write** - Write operations on repository labels.
683+
- `color`: Label color as 6-character hex code without '#' prefix (e.g., 'f29513'). Required for 'create', optional for 'update'. (string, optional)
684+
- `description`: Label description text. Optional for 'create' and 'update'. (string, optional)
685+
- `method`: Operation to perform: 'create', 'update', or 'delete' (string, required)
686+
- `name`: Label name - required for all operations (string, required)
687+
- `new_name`: New name for the label (used only with 'update' method to rename) (string, optional)
688+
- `owner`: Repository owner (username or organization name) (string, required)
689+
- `repo`: Repository name (string, required)
690+
691+
- **list_label** - List labels from a repository or an issue
692+
- `issue_number`: Issue number - if provided, lists labels on the specific issue (number, optional)
693+
- `owner`: Repository owner (username or organization name) - required for all operations (string, required)
694+
- `repo`: Repository name - required for all operations (string, required)
695+
696+
</details>
697+
698+
<details>
699+
664700
<summary>Notifications</summary>
665701

666702
- **dismiss_notification** - Dismiss notification
@@ -761,6 +797,13 @@ The following sets of tools are available (all are on by default):
761797
- `per_page`: Number of results per page (max 100, default: 30) (number, optional)
762798
- `query`: Filter projects by a search query (matches title and description) (string, optional)
763799

800+
- **update_project_item** - Update project item
801+
- `item_id`: The unique identifier of the project item. This is not the issue or pull request ID. (number, required)
802+
- `owner`: If owner_type == user it is the handle for the GitHub user account. If owner_type == org it is the name of the organization. The name is not case sensitive. (string, required)
803+
- `owner_type`: Owner type (string, required)
804+
- `project_number`: The project's number. (number, required)
805+
- `updated_field`: Object consisting of the ID of the project field to update and the new value for the field. To clear the field, set "value" to null. Example: {"id": 123456, "value": "New Value"} (object, required)
806+
764807
</details>
765808

766809
<details>
@@ -976,9 +1019,11 @@ Possible options:
9761019

9771020
- **search_repositories** - Search repositories
9781021
- `minimal_output`: Return minimal repository information (default: true). When false, returns full GitHub API repository objects. (boolean, optional)
1022+
- `order`: Sort order (string, optional)
9791023
- `page`: Page number for pagination (min 1) (number, optional)
9801024
- `perPage`: Results per page for pagination (min 1, max 100) (number, optional)
9811025
- `query`: Repository search query. Examples: 'machine learning in:name stars:>1000 language:python', 'topic:react', 'user:facebook'. Supports advanced search syntax for precise filtering. (string, required)
1026+
- `sort`: Sort repositories by field, defaults to best match (string, optional)
9821027

9831028
</details>
9841029

docs/remote-server.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,7 @@ Below is a table of available toolsets for the remote GitHub MCP Server. Each to
2727
| Experiments | Experimental features that are not considered stable yet | https://api.githubcopilot.com/mcp/x/experiments | [Install](https://insiders.vscode.dev/redirect/mcp/install?name=gh-experiments&config=%7B%22type%22%3A%20%22http%22%2C%22url%22%3A%20%22https%3A%2F%2Fapi.githubcopilot.com%2Fmcp%2Fx%2Fexperiments%22%7D) | [read-only](https://api.githubcopilot.com/mcp/x/experiments/readonly) | [Install read-only](https://insiders.vscode.dev/redirect/mcp/install?name=gh-experiments&config=%7B%22type%22%3A%20%22http%22%2C%22url%22%3A%20%22https%3A%2F%2Fapi.githubcopilot.com%2Fmcp%2Fx%2Fexperiments%2Freadonly%22%7D) |
2828
| Gists | GitHub Gist related tools | https://api.githubcopilot.com/mcp/x/gists | [Install](https://insiders.vscode.dev/redirect/mcp/install?name=gh-gists&config=%7B%22type%22%3A%20%22http%22%2C%22url%22%3A%20%22https%3A%2F%2Fapi.githubcopilot.com%2Fmcp%2Fx%2Fgists%22%7D) | [read-only](https://api.githubcopilot.com/mcp/x/gists/readonly) | [Install read-only](https://insiders.vscode.dev/redirect/mcp/install?name=gh-gists&config=%7B%22type%22%3A%20%22http%22%2C%22url%22%3A%20%22https%3A%2F%2Fapi.githubcopilot.com%2Fmcp%2Fx%2Fgists%2Freadonly%22%7D) |
2929
| Issues | GitHub Issues related tools | https://api.githubcopilot.com/mcp/x/issues | [Install](https://insiders.vscode.dev/redirect/mcp/install?name=gh-issues&config=%7B%22type%22%3A%20%22http%22%2C%22url%22%3A%20%22https%3A%2F%2Fapi.githubcopilot.com%2Fmcp%2Fx%2Fissues%22%7D) | [read-only](https://api.githubcopilot.com/mcp/x/issues/readonly) | [Install read-only](https://insiders.vscode.dev/redirect/mcp/install?name=gh-issues&config=%7B%22type%22%3A%20%22http%22%2C%22url%22%3A%20%22https%3A%2F%2Fapi.githubcopilot.com%2Fmcp%2Fx%2Fissues%2Freadonly%22%7D) |
30+
| Labels | GitHub Labels related tools | https://api.githubcopilot.com/mcp/x/labels | [Install](https://insiders.vscode.dev/redirect/mcp/install?name=gh-labels&config=%7B%22type%22%3A%20%22http%22%2C%22url%22%3A%20%22https%3A%2F%2Fapi.githubcopilot.com%2Fmcp%2Fx%2Flabels%22%7D) | [read-only](https://api.githubcopilot.com/mcp/x/labels/readonly) | [Install read-only](https://insiders.vscode.dev/redirect/mcp/install?name=gh-labels&config=%7B%22type%22%3A%20%22http%22%2C%22url%22%3A%20%22https%3A%2F%2Fapi.githubcopilot.com%2Fmcp%2Fx%2Flabels%2Freadonly%22%7D) |
3031
| Notifications | GitHub Notifications related tools | https://api.githubcopilot.com/mcp/x/notifications | [Install](https://insiders.vscode.dev/redirect/mcp/install?name=gh-notifications&config=%7B%22type%22%3A%20%22http%22%2C%22url%22%3A%20%22https%3A%2F%2Fapi.githubcopilot.com%2Fmcp%2Fx%2Fnotifications%22%7D) | [read-only](https://api.githubcopilot.com/mcp/x/notifications/readonly) | [Install read-only](https://insiders.vscode.dev/redirect/mcp/install?name=gh-notifications&config=%7B%22type%22%3A%20%22http%22%2C%22url%22%3A%20%22https%3A%2F%2Fapi.githubcopilot.com%2Fmcp%2Fx%2Fnotifications%2Freadonly%22%7D) |
3132
| Organizations | GitHub Organization related tools | https://api.githubcopilot.com/mcp/x/orgs | [Install](https://insiders.vscode.dev/redirect/mcp/install?name=gh-orgs&config=%7B%22type%22%3A%20%22http%22%2C%22url%22%3A%20%22https%3A%2F%2Fapi.githubcopilot.com%2Fmcp%2Fx%2Forgs%22%7D) | [read-only](https://api.githubcopilot.com/mcp/x/orgs/readonly) | [Install read-only](https://insiders.vscode.dev/redirect/mcp/install?name=gh-orgs&config=%7B%22type%22%3A%20%22http%22%2C%22url%22%3A%20%22https%3A%2F%2Fapi.githubcopilot.com%2Fmcp%2Fx%2Forgs%2Freadonly%22%7D) |
3233
| Projects | GitHub Projects related tools | https://api.githubcopilot.com/mcp/x/projects | [Install](https://insiders.vscode.dev/redirect/mcp/install?name=gh-projects&config=%7B%22type%22%3A%20%22http%22%2C%22url%22%3A%20%22https%3A%2F%2Fapi.githubcopilot.com%2Fmcp%2Fx%2Fprojects%22%7D) | [read-only](https://api.githubcopilot.com/mcp/x/projects/readonly) | [Install read-only](https://insiders.vscode.dev/redirect/mcp/install?name=gh-projects&config=%7B%22type%22%3A%20%22http%22%2C%22url%22%3A%20%22https%3A%2F%2Fapi.githubcopilot.com%2Fmcp%2Fx%2Fprojects%2Freadonly%22%7D) |

internal/ghmcp/server.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -142,7 +142,7 @@ func NewMCPServer(cfg MCPServerConfig) (*server.MCPServer, error) {
142142

143143
// Create default toolsets
144144
tsg := github.DefaultToolsetGroup(cfg.ReadOnly, getClient, getGQLClient, getRawClient, cfg.Translator, cfg.ContentWindowSize)
145-
err = tsg.EnableToolsets(enabledToolsets)
145+
err = tsg.EnableToolsets(enabledToolsets, nil)
146146

147147
if err != nil {
148148
return nil, fmt.Errorf("failed to enable toolsets: %w", err)
Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,30 @@
1+
{
2+
"annotations": {
3+
"title": "Get a specific label from a repository.",
4+
"readOnlyHint": true
5+
},
6+
"description": "Get a specific label from a repository.",
7+
"inputSchema": {
8+
"properties": {
9+
"name": {
10+
"description": "Label name.",
11+
"type": "string"
12+
},
13+
"owner": {
14+
"description": "Repository owner (username or organization name)",
15+
"type": "string"
16+
},
17+
"repo": {
18+
"description": "Repository name",
19+
"type": "string"
20+
}
21+
},
22+
"required": [
23+
"owner",
24+
"repo",
25+
"name"
26+
],
27+
"type": "object"
28+
},
29+
"name": "get_label"
30+
}
Lines changed: 52 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,52 @@
1+
{
2+
"annotations": {
3+
"title": "Write operations on repository labels.",
4+
"readOnlyHint": false
5+
},
6+
"description": "Perform write operations on repository labels. To set labels on issues, use the 'update_issue' tool.",
7+
"inputSchema": {
8+
"properties": {
9+
"color": {
10+
"description": "Label color as 6-character hex code without '#' prefix (e.g., 'f29513'). Required for 'create', optional for 'update'.",
11+
"type": "string"
12+
},
13+
"description": {
14+
"description": "Label description text. Optional for 'create' and 'update'.",
15+
"type": "string"
16+
},
17+
"method": {
18+
"description": "Operation to perform: 'create', 'update', or 'delete'",
19+
"enum": [
20+
"create",
21+
"update",
22+
"delete"
23+
],
24+
"type": "string"
25+
},
26+
"name": {
27+
"description": "Label name - required for all operations",
28+
"type": "string"
29+
},
30+
"new_name": {
31+
"description": "New name for the label (used only with 'update' method to rename)",
32+
"type": "string"
33+
},
34+
"owner": {
35+
"description": "Repository owner (username or organization name)",
36+
"type": "string"
37+
},
38+
"repo": {
39+
"description": "Repository name",
40+
"type": "string"
41+
}
42+
},
43+
"required": [
44+
"method",
45+
"owner",
46+
"repo",
47+
"name"
48+
],
49+
"type": "object"
50+
},
51+
"name": "label_write"
52+
}
Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,29 @@
1+
{
2+
"annotations": {
3+
"title": "List labels from a repository.",
4+
"readOnlyHint": true
5+
},
6+
"description": "List labels from a repository or an issue",
7+
"inputSchema": {
8+
"properties": {
9+
"issue_number": {
10+
"description": "Issue number - if provided, lists labels on the specific issue",
11+
"type": "number"
12+
},
13+
"owner": {
14+
"description": "Repository owner (username or organization name) - required for all operations",
15+
"type": "string"
16+
},
17+
"repo": {
18+
"description": "Repository name - required for all operations",
19+
"type": "string"
20+
}
21+
},
22+
"required": [
23+
"owner",
24+
"repo"
25+
],
26+
"type": "object"
27+
},
28+
"name": "list_label"
29+
}

pkg/github/__toolsnaps__/search_repositories.snap

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,14 @@
1111
"description": "Return minimal repository information (default: true). When false, returns full GitHub API repository objects.",
1212
"type": "boolean"
1313
},
14+
"order": {
15+
"description": "Sort order",
16+
"enum": [
17+
"asc",
18+
"desc"
19+
],
20+
"type": "string"
21+
},
1422
"page": {
1523
"description": "Page number for pagination (min 1)",
1624
"minimum": 1,
@@ -25,6 +33,16 @@
2533
"query": {
2634
"description": "Repository search query. Examples: 'machine learning in:name stars:\u003e1000 language:python', 'topic:react', 'user:facebook'. Supports advanced search syntax for precise filtering.",
2735
"type": "string"
36+
},
37+
"sort": {
38+
"description": "Sort repositories by field, defaults to best match",
39+
"enum": [
40+
"stars",
41+
"forks",
42+
"help-wanted-issues",
43+
"updated"
44+
],
45+
"type": "string"
2846
}
2947
},
3048
"required": [

pkg/github/__toolsnaps__/update_project_item.snap

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -6,12 +6,8 @@
66
"description": "Update a specific Project item for a user or org",
77
"inputSchema": {
88
"properties": {
9-
"fields": {
10-
"description": "A list of field updates to apply.",
11-
"type": "array"
12-
},
139
"item_id": {
14-
"description": "The numeric ID of the project item to update (not the issue or pull request ID).",
10+
"description": "The unique identifier of the project item. This is not the issue or pull request ID.",
1511
"type": "number"
1612
},
1713
"owner": {
@@ -29,14 +25,19 @@
2925
"project_number": {
3026
"description": "The project's number.",
3127
"type": "number"
28+
},
29+
"updated_field": {
30+
"description": "Object consisting of the ID of the project field to update and the new value for the field. To clear the field, set \"value\" to null. Example: {\"id\": 123456, \"value\": \"New Value\"}",
31+
"properties": {},
32+
"type": "object"
3233
}
3334
},
3435
"required": [
3536
"owner_type",
3637
"owner",
3738
"project_number",
3839
"item_id",
39-
"fields"
40+
"updated_field"
4041
],
4142
"type": "object"
4243
},

0 commit comments

Comments
 (0)