Skip to content

Commit bfcd16b

Browse files
Merge branch 'main' into dependabot/go_modules/github.com/migueleliasweb/go-github-mock-1.4.0
2 parents 5443d91 + d5e1f48 commit bfcd16b

17 files changed

+2317
-193
lines changed

README.md

Lines changed: 32 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -462,6 +462,8 @@ The following sets of tools are available (all are on by default):
462462
- **list_discussions** - List discussions
463463
- `after`: Cursor for pagination. Use the endCursor from the previous page's PageInfo for GraphQL APIs. (string, optional)
464464
- `category`: Optional filter by discussion category ID. If provided, only discussions with this category are listed. (string, optional)
465+
- `direction`: Order direction. (string, optional)
466+
- `orderBy`: Order discussions by field. If provided, the 'direction' also needs to be provided. (string, optional)
465467
- `owner`: Repository owner (string, required)
466468
- `perPage`: Results per page for pagination (min 1, max 100) (number, optional)
467469
- `repo`: Repository name (string, required)
@@ -478,6 +480,13 @@ The following sets of tools are available (all are on by default):
478480
- `owner`: Repository owner (string, required)
479481
- `repo`: Repository name (string, required)
480482

483+
- **add_sub_issue** - Add sub-issue
484+
- `issue_number`: The number of the parent issue (number, required)
485+
- `owner`: Repository owner (string, required)
486+
- `replace_parent`: When true, replaces the sub-issue's current parent issue (boolean, optional)
487+
- `repo`: Repository name (string, required)
488+
- `sub_issue_id`: The ID of the sub-issue to add. ID is not the same as issue number (number, required)
489+
481490
- **assign_copilot_to_issue** - Assign Copilot to issue
482491
- `issueNumber`: Issue number (number, required)
483492
- `owner`: Repository owner (string, required)
@@ -515,6 +524,27 @@ The following sets of tools are available (all are on by default):
515524
- `sort`: Sort order (string, optional)
516525
- `state`: Filter by state (string, optional)
517526

527+
- **list_sub_issues** - List sub-issues
528+
- `issue_number`: Issue number (number, required)
529+
- `owner`: Repository owner (string, required)
530+
- `page`: Page number for pagination (default: 1) (number, optional)
531+
- `per_page`: Number of results per page (max 100, default: 30) (number, optional)
532+
- `repo`: Repository name (string, required)
533+
534+
- **remove_sub_issue** - Remove sub-issue
535+
- `issue_number`: The number of the parent issue (number, required)
536+
- `owner`: Repository owner (string, required)
537+
- `repo`: Repository name (string, required)
538+
- `sub_issue_id`: The ID of the sub-issue to remove. ID is not the same as issue number (number, required)
539+
540+
- **reprioritize_sub_issue** - Reprioritize sub-issue
541+
- `after_id`: The ID of the sub-issue to be prioritized after (either after_id OR before_id should be specified) (number, optional)
542+
- `before_id`: The ID of the sub-issue to be prioritized before (either after_id OR before_id should be specified) (number, optional)
543+
- `issue_number`: The number of the parent issue (number, required)
544+
- `owner`: Repository owner (string, required)
545+
- `repo`: Repository name (string, required)
546+
- `sub_issue_id`: The ID of the sub-issue to reprioritize. ID is not the same as issue number (number, required)
547+
518548
- **search_issues** - Search issues
519549
- `order`: Sort order (string, optional)
520550
- `owner`: Optional repository owner. If provided with repo, only notifications for this repository are listed. (string, optional)
@@ -706,6 +736,7 @@ The following sets of tools are available (all are on by default):
706736
- **update_pull_request** - Edit pull request
707737
- `base`: New base branch name (string, optional)
708738
- `body`: New description (string, optional)
739+
- `draft`: Mark pull request as draft (true) or ready for review (false) (boolean, optional)
709740
- `maintainer_can_modify`: Allow maintainer edits (boolean, optional)
710741
- `owner`: Repository owner (string, required)
711742
- `pullNumber`: Pull request number to update (number, required)
@@ -808,7 +839,7 @@ The following sets of tools are available (all are on by default):
808839
- `order`: Sort order (string, optional)
809840
- `page`: Page number for pagination (min 1) (number, optional)
810841
- `perPage`: Results per page for pagination (min 1, max 100) (number, optional)
811-
- `q`: Search query using GitHub code search syntax (string, required)
842+
- `query`: Search query using GitHub code search syntax (string, required)
812843
- `sort`: Sort field ('indexed' only) (string, optional)
813844

814845
- **search_repositories** - Search repositories

docs/testing.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ This project uses a combination of unit tests and end-to-end (e2e) tests to ensu
2222
## toolsnaps: Tool Schema Snapshots
2323

2424
- The `toolsnaps` utility ensures that the JSON schema for each tool does not change unexpectedly.
25-
- Snapshots are stored in `__toolsnaps__/*.snap` files , where `*` represents the name of the tool
25+
- Snapshots are stored in `__toolsnaps__/*.snap` files, where `*` represents the name of the tool
2626
- When running tests, the current tool schema is compared to the snapshot. If there is a difference, the test will fail and show a diff.
2727
- If you intentionally change a tool's schema, update the snapshots by running tests with the environment variable: `UPDATE_TOOLSNAPS=true go test ./...`
2828
- In CI (when `GITHUB_ACTIONS=true`), missing snapshots will cause a test failure to ensure snapshots are always
Lines changed: 39 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,39 @@
1+
{
2+
"annotations": {
3+
"title": "Add sub-issue",
4+
"readOnlyHint": false
5+
},
6+
"description": "Add a sub-issue to a parent issue in a GitHub repository.",
7+
"inputSchema": {
8+
"properties": {
9+
"issue_number": {
10+
"description": "The number of the parent issue",
11+
"type": "number"
12+
},
13+
"owner": {
14+
"description": "Repository owner",
15+
"type": "string"
16+
},
17+
"replace_parent": {
18+
"description": "When true, replaces the sub-issue's current parent issue",
19+
"type": "boolean"
20+
},
21+
"repo": {
22+
"description": "Repository name",
23+
"type": "string"
24+
},
25+
"sub_issue_id": {
26+
"description": "The ID of the sub-issue to add. ID is not the same as issue number",
27+
"type": "number"
28+
}
29+
},
30+
"required": [
31+
"owner",
32+
"repo",
33+
"issue_number",
34+
"sub_issue_id"
35+
],
36+
"type": "object"
37+
},
38+
"name": "add_sub_issue"
39+
}
Lines changed: 38 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,38 @@
1+
{
2+
"annotations": {
3+
"title": "List sub-issues",
4+
"readOnlyHint": true
5+
},
6+
"description": "List sub-issues for a specific issue in a GitHub repository.",
7+
"inputSchema": {
8+
"properties": {
9+
"issue_number": {
10+
"description": "Issue number",
11+
"type": "number"
12+
},
13+
"owner": {
14+
"description": "Repository owner",
15+
"type": "string"
16+
},
17+
"page": {
18+
"description": "Page number for pagination (default: 1)",
19+
"type": "number"
20+
},
21+
"per_page": {
22+
"description": "Number of results per page (max 100, default: 30)",
23+
"type": "number"
24+
},
25+
"repo": {
26+
"description": "Repository name",
27+
"type": "string"
28+
}
29+
},
30+
"required": [
31+
"owner",
32+
"repo",
33+
"issue_number"
34+
],
35+
"type": "object"
36+
},
37+
"name": "list_sub_issues"
38+
}
Lines changed: 35 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,35 @@
1+
{
2+
"annotations": {
3+
"title": "Remove sub-issue",
4+
"readOnlyHint": false
5+
},
6+
"description": "Remove a sub-issue from a parent issue in a GitHub repository.",
7+
"inputSchema": {
8+
"properties": {
9+
"issue_number": {
10+
"description": "The number of the parent issue",
11+
"type": "number"
12+
},
13+
"owner": {
14+
"description": "Repository owner",
15+
"type": "string"
16+
},
17+
"repo": {
18+
"description": "Repository name",
19+
"type": "string"
20+
},
21+
"sub_issue_id": {
22+
"description": "The ID of the sub-issue to remove. ID is not the same as issue number",
23+
"type": "number"
24+
}
25+
},
26+
"required": [
27+
"owner",
28+
"repo",
29+
"issue_number",
30+
"sub_issue_id"
31+
],
32+
"type": "object"
33+
},
34+
"name": "remove_sub_issue"
35+
}
Lines changed: 43 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,43 @@
1+
{
2+
"annotations": {
3+
"title": "Reprioritize sub-issue",
4+
"readOnlyHint": false
5+
},
6+
"description": "Reprioritize a sub-issue to a different position in the parent issue's sub-issue list.",
7+
"inputSchema": {
8+
"properties": {
9+
"after_id": {
10+
"description": "The ID of the sub-issue to be prioritized after (either after_id OR before_id should be specified)",
11+
"type": "number"
12+
},
13+
"before_id": {
14+
"description": "The ID of the sub-issue to be prioritized before (either after_id OR before_id should be specified)",
15+
"type": "number"
16+
},
17+
"issue_number": {
18+
"description": "The number of the parent issue",
19+
"type": "number"
20+
},
21+
"owner": {
22+
"description": "Repository owner",
23+
"type": "string"
24+
},
25+
"repo": {
26+
"description": "Repository name",
27+
"type": "string"
28+
},
29+
"sub_issue_id": {
30+
"description": "The ID of the sub-issue to reprioritize. ID is not the same as issue number",
31+
"type": "number"
32+
}
33+
},
34+
"required": [
35+
"owner",
36+
"repo",
37+
"issue_number",
38+
"sub_issue_id"
39+
],
40+
"type": "object"
41+
},
42+
"name": "reprioritize_sub_issue"
43+
}

pkg/github/__toolsnaps__/search_code.snap

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@
2525
"minimum": 1,
2626
"type": "number"
2727
},
28-
"q": {
28+
"query": {
2929
"description": "Search query using GitHub code search syntax",
3030
"type": "string"
3131
},
@@ -35,7 +35,7 @@
3535
}
3636
},
3737
"required": [
38-
"q"
38+
"query"
3939
],
4040
"type": "object"
4141
},

pkg/github/__toolsnaps__/update_pull_request.snap

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,10 @@
1414
"description": "New description",
1515
"type": "string"
1616
},
17+
"draft": {
18+
"description": "Mark pull request as draft (true) or ready for review (false)",
19+
"type": "boolean"
20+
},
1721
"maintainer_can_modify": {
1822
"description": "Allow maintainer edits",
1923
"type": "boolean"

0 commit comments

Comments
 (0)