Skip to content

Commit 164b6eb

Browse files
labudisCopilot
andauthored
Add sub-issues, issue types, projects, and issue fields guidance to github-issues skill (#884)
* Add issue fields, issue types, and list_issue_types to github-issues skill - Add list_issue_types to available MCP tools table - Add type parameter to optional parameters with guidance - Expand issue types section: MCP tools (preferred) + GraphQL (advanced) - Document org-level type discovery, create/update with type, GraphQL mutations - Add issue fields section: discover, read, set via GraphQL - Note required GraphQL-Features headers (issue_fields, issue_types) - Update skill description to mention fields, types, dates, priority Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> * Add Projects V2 guidance to github-issues skill Include MCP tools (projects_list, projects_get, projects_write) and GraphQL examples for project item management. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> * Add sub-issues section, move issue fields to end with preview note - Add Sub-Issues and Parent Issues section (MCP, REST, GraphQL) - Add issue_read tool to MCP tools table - Move Issue Fields to last section with private preview callout - Link to community discussion for requesting access Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> * Prefer issue types over labels for categorization Update guidance and examples to use type parameter (Bug, Feature) instead of equivalent labels when issue types are available. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> * Prefer issue fields over project fields for metadata Issue fields live on the issue and travel across projects. Project fields are scoped to a single project. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> * Add issue dependencies (blocked by/blocking) section Covers REST endpoints (list, add, remove) and GraphQL (blockedBy, blocking, issueDependenciesSummary, mutations). Also documents tracked issues read-only fields. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> * Add project discovery workflow for progress reports Teach agents how to find projects by name, discover fields and iterations, paginate items, and build status breakdowns. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> * Generate updated skill listing after SKILL.md changes Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> * Split skill into reference files per reviewer feedback Move sub-issues, dependencies, issue types, projects, and issue fields into separate references/ files. Main SKILL.md now contains core MCP workflow and a capability table pointing to each reference. This way the agent only loads the knowledge it needs for the specific task. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> --------- Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
1 parent 0d4b328 commit 164b6eb

7 files changed

Lines changed: 542 additions & 4 deletions

File tree

docs/README.skills.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -120,7 +120,7 @@ See [CONTRIBUTING.md](../CONTRIBUTING.md#adding-skills) for guidelines on how to
120120
| [git-commit](../skills/git-commit/SKILL.md) | Execute git commit with conventional commit message analysis, intelligent staging, and message generation. Use when user asks to commit changes, create a git commit, or mentions "/commit". Supports: (1) Auto-detecting type and scope from changes, (2) Generating conventional commit messages from diff, (3) Interactive commit with optional type/scope/description overrides, (4) Intelligent file staging for logical grouping | None |
121121
| [git-flow-branch-creator](../skills/git-flow-branch-creator/SKILL.md) | Intelligent Git Flow branch creator that analyzes git status/diff and creates appropriate branches following the nvie Git Flow branching model. | None |
122122
| [github-copilot-starter](../skills/github-copilot-starter/SKILL.md) | Set up complete GitHub Copilot configuration for a new project based on technology stack | None |
123-
| [github-issues](../skills/github-issues/SKILL.md) | Create, update, and manage GitHub issues using MCP tools. Use this skill when users want to create bug reports, feature requests, or task issues, update existing issues, add labels/assignees/milestones, or manage issue workflows. Triggers on requests like "create an issue", "file a bug", "request a feature", "update issue X", or any GitHub issue management task. | `references/templates.md` |
123+
| [github-issues](../skills/github-issues/SKILL.md) | Create, update, and manage GitHub issues using MCP tools. Use this skill when users want to create bug reports, feature requests, or task issues, update existing issues, add labels/assignees/milestones, set issue fields (dates, priority, custom fields), set issue types, or manage issue workflows. Triggers on requests like "create an issue", "file a bug", "request a feature", "update issue X", "set the priority", "set the start date", or any GitHub issue management task. | `references/dependencies.md`<br />`references/issue-fields.md`<br />`references/issue-types.md`<br />`references/projects.md`<br />`references/sub-issues.md`<br />`references/templates.md` |
124124
| [go-mcp-server-generator](../skills/go-mcp-server-generator/SKILL.md) | Generate a complete Go MCP server project with proper structure, dependencies, and implementation using the official github.com/modelcontextprotocol/go-sdk. | None |
125125
| [image-manipulation-image-magick](../skills/image-manipulation-image-magick/SKILL.md) | Process and manipulate images using ImageMagick. Supports resizing, format conversion, batch processing, and retrieving image metadata. Use when working with images, creating thumbnails, resizing wallpapers, or performing batch image operations. | None |
126126
| [import-infrastructure-as-code](../skills/import-infrastructure-as-code/SKILL.md) | Import existing Azure resources into Terraform using Azure CLI discovery and Azure Verified Modules (AVM). Use when asked to reverse-engineer live Azure infrastructure, generate Infrastructure as Code from existing subscriptions/resource groups/resource IDs, map dependencies, derive exact import addresses from downloaded module source, prevent configuration drift, and produce AVM-based Terraform files ready for validation and planning across any Azure resource type. | None |

skills/github-issues/SKILL.md

Lines changed: 26 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
---
22
name: github-issues
3-
description: 'Create, update, and manage GitHub issues using MCP tools. Use this skill when users want to create bug reports, feature requests, or task issues, update existing issues, add labels/assignees/milestones, or manage issue workflows. Triggers on requests like "create an issue", "file a bug", "request a feature", "update issue X", or any GitHub issue management task.'
3+
description: 'Create, update, and manage GitHub issues using MCP tools. Use this skill when users want to create bug reports, feature requests, or task issues, update existing issues, add labels/assignees/milestones, set issue fields (dates, priority, custom fields), set issue types, or manage issue workflows. Triggers on requests like "create an issue", "file a bug", "request a feature", "update issue X", "set the priority", "set the start date", or any GitHub issue management task.'
44
---
55

66
# GitHub Issues
@@ -17,6 +17,11 @@ Manage GitHub issues using the `@modelcontextprotocol/server-github` MCP server.
1717
| `mcp__github__search_issues` | Search issues |
1818
| `mcp__github__add_issue_comment` | Add comments |
1919
| `mcp__github__list_issues` | List repository issues |
20+
| `mcp__github__list_issue_types` | List available issue types for an organization |
21+
| `mcp__github__issue_read` | Read issue details, sub-issues, comments, labels |
22+
| `mcp__github__projects_list` | List projects, project fields, project items, status updates |
23+
| `mcp__github__projects_get` | Get details of a project, field, item, or status update |
24+
| `mcp__github__projects_write` | Add/update/delete project items, create status updates |
2025

2126
## Workflow
2227

@@ -43,8 +48,13 @@ body: structured markdown content
4348
labels: ["bug", "enhancement", "documentation", ...]
4449
assignees: ["username1", "username2"]
4550
milestone: milestone number (integer)
51+
type: issue type name (e.g., "Bug", "Feature", "Task", "Epic")
4652
```
4753

54+
**Issue types** are organization-level metadata. Before using `type`, call `mcp__github__list_issue_types` with the org name to discover available types. If the org has no issue types configured, omit the parameter.
55+
56+
**Prefer issue types over labels for categorization.** When issue types are available (e.g., Bug, Feature, Task), use the `type` parameter instead of applying equivalent labels like `bug` or `enhancement`. Issue types are the canonical way to categorize issues on GitHub. Only fall back to labels when the org has no issue types configured.
57+
4858
### Title Guidelines
4959

5060
- Start with type prefix when useful: `[Bug]`, `[Feature]`, `[Docs]`
@@ -89,7 +99,7 @@ State values: `open`, `closed`
8999
"repo": "awesome-copilot",
90100
"title": "[Bug] Login page crashes when using SSO",
91101
"body": "## Description\nThe login page crashes when users attempt to authenticate using SSO.\n\n## Steps to Reproduce\n1. Navigate to login page\n2. Click 'Sign in with SSO'\n3. Page crashes\n\n## Expected Behavior\nSSO authentication should complete and redirect to dashboard.\n\n## Actual Behavior\nPage becomes unresponsive and displays error.\n\n## Environment\n- Browser: [To be filled]\n- OS: [To be filled]\n\n## Additional Context\nReported by user.",
92-
"labels": ["bug"]
102+
"type": "Bug"
93103
}
94104
```
95105

@@ -104,7 +114,8 @@ State values: `open`, `closed`
104114
"repo": "awesome-copilot",
105115
"title": "[Feature] Add dark mode support",
106116
"body": "## Summary\nAdd dark mode theme option for improved user experience and accessibility.\n\n## Motivation\n- Reduces eye strain in low-light environments\n- Increasingly expected by users\n- Improves accessibility\n\n## Proposed Solution\nImplement theme toggle with system preference detection.\n\n## Acceptance Criteria\n- [ ] Toggle switch in settings\n- [ ] Persists user preference\n- [ ] Respects system preference by default\n- [ ] All UI components support both themes\n\n## Alternatives Considered\nNone specified.\n\n## Additional Context\nHigh priority request.",
107-
"labels": ["enhancement", "high-priority"]
117+
"type": "Feature",
118+
"labels": ["high-priority"]
108119
}
109120
```
110121

@@ -130,3 +141,15 @@ Use these standard labels when applicable:
130141
- Ask for missing critical information rather than guessing
131142
- Link related issues when known: `Related to #123`
132143
- For updates, fetch current issue first to preserve unchanged fields
144+
145+
## Extended Capabilities
146+
147+
The following features require REST or GraphQL APIs beyond the basic MCP tools. Each is documented in its own reference file so the agent only loads the knowledge it needs.
148+
149+
| Capability | When to use | Reference |
150+
|------------|-------------|-----------|
151+
| Sub-issues & parent issues | Breaking work into hierarchical tasks | [references/sub-issues.md](references/sub-issues.md) |
152+
| Issue dependencies | Tracking blocked-by / blocking relationships | [references/dependencies.md](references/dependencies.md) |
153+
| Issue types (advanced) | GraphQL operations beyond MCP `list_issue_types` / `type` param | [references/issue-types.md](references/issue-types.md) |
154+
| Projects V2 | Project boards, progress reports, field management | [references/projects.md](references/projects.md) |
155+
| Issue fields | Custom metadata: dates, priority, text, numbers (private preview) | [references/issue-fields.md](references/issue-fields.md) |
Lines changed: 71 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,71 @@
1+
# Issue Dependencies (Blocked By / Blocking)
2+
3+
Dependencies let you mark that an issue is blocked by another issue. This creates a formal dependency relationship visible in the UI and trackable via API. No MCP tools exist for dependencies; use REST or GraphQL directly.
4+
5+
## Using REST API
6+
7+
**List issues blocking this issue:**
8+
```
9+
GET /repos/{owner}/{repo}/issues/{issue_number}/dependencies/blocked_by
10+
```
11+
12+
**Add a blocking dependency:**
13+
```
14+
POST /repos/{owner}/{repo}/issues/{issue_number}/dependencies/blocked_by
15+
Body: { "issue_id": 12345 }
16+
```
17+
18+
The `issue_id` is the numeric issue **ID** (not the issue number).
19+
20+
**Remove a blocking dependency:**
21+
```
22+
DELETE /repos/{owner}/{repo}/issues/{issue_number}/dependencies/blocked_by/{issue_id}
23+
```
24+
25+
## Using GraphQL
26+
27+
**Read dependencies:**
28+
```graphql
29+
{
30+
repository(owner: "OWNER", name: "REPO") {
31+
issue(number: 123) {
32+
blockedBy(first: 10) { nodes { number title state } }
33+
blocking(first: 10) { nodes { number title state } }
34+
issueDependenciesSummary { blockedBy blocking totalBlockedBy totalBlocking }
35+
}
36+
}
37+
}
38+
```
39+
40+
**Add a dependency:**
41+
```graphql
42+
mutation {
43+
addBlockedBy(input: {
44+
issueId: "BLOCKED_ISSUE_NODE_ID"
45+
blockingIssueId: "BLOCKING_ISSUE_NODE_ID"
46+
}) {
47+
blockedByIssue { number title }
48+
}
49+
}
50+
```
51+
52+
**Remove a dependency:**
53+
```graphql
54+
mutation {
55+
removeBlockedBy(input: {
56+
issueId: "BLOCKED_ISSUE_NODE_ID"
57+
blockingIssueId: "BLOCKING_ISSUE_NODE_ID"
58+
}) {
59+
blockedByIssue { number title }
60+
}
61+
}
62+
```
63+
64+
## Tracked issues (read-only)
65+
66+
Task-list tracking relationships are available via GraphQL as read-only fields:
67+
68+
- `trackedIssues(first: N)` - issues tracked in this issue's task list
69+
- `trackedInIssues(first: N)` - issues whose task lists reference this issue
70+
71+
These are set automatically when issues are referenced in task lists (`- [ ] #123`). There are no mutations to manage them.
Lines changed: 127 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,127 @@
1+
# Issue Fields (GraphQL, Private Preview)
2+
3+
> **Private preview:** Issue fields are currently in private preview. Request access at https://github.com/orgs/community/discussions/175366
4+
5+
Issue fields are custom metadata (dates, text, numbers, single-select) defined at the organization level and set per-issue. They are separate from labels, milestones, and assignees. Common examples: Start Date, Target Date, Priority, Impact, Effort.
6+
7+
**Important:** All issue field queries and mutations require the `GraphQL-Features: issue_fields` HTTP header. Without it, the fields are not visible in the schema.
8+
9+
**Prefer issue fields over project fields.** When you need to set metadata like dates, priority, or status on an issue, use issue fields (which live on the issue itself) rather than project fields (which live on a project item). Issue fields travel with the issue across projects and views, while project fields are scoped to a single project. Only use project fields when issue fields are not available or when the field is project-specific (e.g., sprint iterations).
10+
11+
## Discovering available fields
12+
13+
Fields are defined at the org level. List them before trying to set values:
14+
15+
```graphql
16+
# Header: GraphQL-Features: issue_fields
17+
{
18+
organization(login: "OWNER") {
19+
issueFields(first: 30) {
20+
nodes {
21+
__typename
22+
... on IssueFieldDate { id name }
23+
... on IssueFieldText { id name }
24+
... on IssueFieldNumber { id name }
25+
... on IssueFieldSingleSelect { id name options { id name color } }
26+
}
27+
}
28+
}
29+
}
30+
```
31+
32+
Field types: `IssueFieldDate`, `IssueFieldText`, `IssueFieldNumber`, `IssueFieldSingleSelect`.
33+
34+
For single-select fields, you need the option `id` (not the name) to set values.
35+
36+
## Reading field values on an issue
37+
38+
```graphql
39+
# Header: GraphQL-Features: issue_fields
40+
{
41+
repository(owner: "OWNER", name: "REPO") {
42+
issue(number: 123) {
43+
issueFieldValues(first: 20) {
44+
nodes {
45+
__typename
46+
... on IssueFieldDateValue {
47+
value
48+
field { ... on IssueFieldDate { id name } }
49+
}
50+
... on IssueFieldTextValue {
51+
value
52+
field { ... on IssueFieldText { id name } }
53+
}
54+
... on IssueFieldNumberValue {
55+
value
56+
field { ... on IssueFieldNumber { id name } }
57+
}
58+
... on IssueFieldSingleSelectValue {
59+
name
60+
color
61+
field { ... on IssueFieldSingleSelect { id name } }
62+
}
63+
}
64+
}
65+
}
66+
}
67+
}
68+
```
69+
70+
## Setting field values
71+
72+
Use `setIssueFieldValue` to set one or more fields at once. You need the issue's node ID and the field IDs from the discovery query above.
73+
74+
```graphql
75+
# Header: GraphQL-Features: issue_fields
76+
mutation {
77+
setIssueFieldValue(input: {
78+
issueId: "ISSUE_NODE_ID"
79+
issueFields: [
80+
{ fieldId: "IFD_xxx", dateValue: "2026-04-15" }
81+
{ fieldId: "IFT_xxx", textValue: "some text" }
82+
{ fieldId: "IFN_xxx", numberValue: 3.0 }
83+
{ fieldId: "IFSS_xxx", singleSelectOptionId: "OPTION_ID" }
84+
]
85+
}) {
86+
issue { id title }
87+
}
88+
}
89+
```
90+
91+
Each entry in `issueFields` takes a `fieldId` plus exactly one value parameter:
92+
93+
| Field type | Value parameter | Format |
94+
|-----------|----------------|--------|
95+
| Date | `dateValue` | ISO 8601 date string, e.g. `"2026-04-15"` |
96+
| Text | `textValue` | String |
97+
| Number | `numberValue` | Float |
98+
| Single select | `singleSelectOptionId` | ID from the field's `options` list |
99+
100+
To clear a field value, set `delete: true` instead of a value parameter.
101+
102+
## Workflow for setting fields
103+
104+
1. **Discover fields** - query the org's `issueFields` to get field IDs and option IDs
105+
2. **Get the issue node ID** - from `repository.issue.id`
106+
3. **Set values** - call `setIssueFieldValue` with the issue node ID and field entries
107+
4. **Batch when possible** - multiple fields can be set in a single mutation call
108+
109+
## Example: Set dates and priority on an issue
110+
111+
```bash
112+
gh api graphql \
113+
-H "GraphQL-Features: issue_fields" \
114+
-f query='
115+
mutation {
116+
setIssueFieldValue(input: {
117+
issueId: "I_kwDOxxx"
118+
issueFields: [
119+
{ fieldId: "IFD_startDate", dateValue: "2026-04-01" }
120+
{ fieldId: "IFD_targetDate", dateValue: "2026-04-30" }
121+
{ fieldId: "IFSS_priority", singleSelectOptionId: "OPTION_P1" }
122+
]
123+
}) {
124+
issue { id title }
125+
}
126+
}'
127+
```
Lines changed: 72 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,72 @@
1+
# Issue Types (Advanced GraphQL)
2+
3+
Issue types (Bug, Feature, Task, Epic, etc.) are defined at the **organization** level and inherited by repositories. They categorize issues beyond labels.
4+
5+
For basic usage, the MCP tools handle issue types natively. Call `mcp__github__list_issue_types` to discover types, and pass `type: "Bug"` to `mcp__github__create_issue` or `mcp__github__update_issue`. This reference covers advanced GraphQL operations.
6+
7+
## GraphQL Feature Header
8+
9+
All GraphQL issue type operations require the `GraphQL-Features: issue_types` HTTP header.
10+
11+
## List types (org or repo level)
12+
13+
```graphql
14+
# Header: GraphQL-Features: issue_types
15+
{
16+
organization(login: "OWNER") {
17+
issueTypes(first: 20) {
18+
nodes { id name color description isEnabled }
19+
}
20+
}
21+
}
22+
```
23+
24+
Types can also be listed per-repo via `repository.issueTypes` or looked up by name via `repository.issueType(name: "Bug")`.
25+
26+
## Read an issue's type
27+
28+
```graphql
29+
# Header: GraphQL-Features: issue_types
30+
{
31+
repository(owner: "OWNER", name: "REPO") {
32+
issue(number: 123) {
33+
issueType { id name color }
34+
}
35+
}
36+
}
37+
```
38+
39+
## Set type on an existing issue
40+
41+
```graphql
42+
# Header: GraphQL-Features: issue_types
43+
mutation {
44+
updateIssueIssueType(input: {
45+
issueId: "ISSUE_NODE_ID"
46+
issueTypeId: "IT_xxx"
47+
}) {
48+
issue { id issueType { name } }
49+
}
50+
}
51+
```
52+
53+
## Create issue with type
54+
55+
```graphql
56+
# Header: GraphQL-Features: issue_types
57+
mutation {
58+
createIssue(input: {
59+
repositoryId: "REPO_NODE_ID"
60+
title: "Fix login bug"
61+
issueTypeId: "IT_xxx"
62+
}) {
63+
issue { id number issueType { name } }
64+
}
65+
}
66+
```
67+
68+
To clear the type, set `issueTypeId` to `null`.
69+
70+
## Available colors
71+
72+
`GRAY`, `BLUE`, `GREEN`, `YELLOW`, `ORANGE`, `RED`, `PINK`, `PURPLE`

0 commit comments

Comments
 (0)