github-issue-query

Query GitHub issues with jq filtering and state or limit options.

4.9k|489|Updated Aug 12, 2025
One-click install
npx skills add https://github.com/githubnext/gh-aw --skill github-issue-query
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: github-issue-query
Source: https://github.com/githubnext/gh-aw/tree/main/skills/github-issue-query
Command: npx skills add https://github.com/githubnext/gh-aw --skill github-issue-query

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes scripts (resource) components.

What problem does it solve?

This Skill streamlines the process of querying GitHub issues by providing efficient jq filtering support, allowing users to quickly retrieve, filter, and transform issue data for analysis or further automation. It helps AI agents and developers automate data collection and analysis from GitHub.

Core Features & Use Cases

  • Flexible Querying: List issues from the current or any specified repository with options for state (open, closed, all) and limit.
  • Advanced jq Filtering: Use jq expressions to filter by author, labels, comments, creation date, and transform output to desired formats.
  • Schema & Size Information: Get schema and data size details when no jq filter is provided, preventing overwhelming responses.
  • Automated Data Extraction: Ideal for AI agents needing specific issue data for decision-making or reporting.
  • Use Case: An AI agent needs to find all open issues labeled "bug" that have more than 5 comments. This skill enables the agent to execute a query-issues.sh --jq '.[] | select(.state == "OPEN" and (.labels | map(.name) | index("bug")) and .comments.totalCount > 5)' command.

Quick Start

Use the github-issue-query skill to list the number and title of all open issues in the current repository: ./query-issues.sh --jq '.[] | {number, title}'.

Frequently Asked Questions about github-issue-query

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I filter GitHub issues by labels and comment count?

Use jq filtering with github-issue-query to select issues by labels and comments. For example, filter open issues labeled 'bug' with more than 5 comments using `.[] | select(.state == "OPEN" and (.labels | map(.name) | index("bug")) and .comments.totalCount > 5)`.

Can I query issues from a specific repository using the GitHub CLI?

Yes. github-issue-query queries the current repository by default, or you can specify any owner/repo. It requires GitHub CLI authentication and supports state filtering (open, closed, all) and result limits.

What's the best way to extract and transform GitHub issue data for analysis?

Use jq expressions with github-issue-query to extract, filter, and reshape issue data in one step. Run without --jq to preview schema and data size first, then apply transformations like selecting specific fields or aggregating by author or labels.

Do I need to understand jq syntax to query GitHub issues effectively?

Basic jq knowledge helps, but github-issue-query supports common queries out of the box. Start by running the tool without filters to see schema, then build expressions incrementally. The skill documentation includes example queries for frequent tasks.

Can I automate GitHub issue data extraction for reporting?

Yes. github-issue-query is designed for automated data collection by AI agents and developers. Combine it with jq filtering to extract specific fields, counts, or summaries, then pipe results to other tools for reporting or further processing.