Developer tools6 min readBy Purrkey teamUpdated

How to list a GitHub repository's issues and pull requests

Get a paginated table of a GitHub repository's issues and pull requests with authors, states, labels, counts and bodies

On this page

You have 60 open issues and pull requests in one repository to triage before a release, and no single view that puts labels, author association and comment counts side by side. anyapi.github.repository_issues returns that list one page at a time, with the author, state, labels, counts and body of each item

The triage sheet is the deliverable. One row per item, filled from the response fields, plus a decision column you add yourself. No call has been run for this article, so the sample rows below are a design, not a result

The triage sheet and its columns

Ask for state open, sort comments and order desc to bring the busiest threads onto the first page. The sheet is wide on purpose, with the timestamp fields that show how long an item has waited

numbertitlestateisPullRequestdraftauthorauthorAssociationlabelscommentsreactionscreatedUtcupdatedUtcclosedUtcmergedUtcurl
(one row per item)

Values here are placeholders showing the shape:

numbertitleisPullRequestdraftauthorAssociationlabelscommentsstate
1(issue title)falsenullCONTRIBUTOR(label names)0open
2(pull request title)truefalseFIRST_TIME_CONTRIBUTOR(label names)3open

The decision column you add holds one of three words: review, assign or close. A row with comments 0 and authorAssociation FIRST_TIMER is a candidate for a reply, while a quiet row with a stale updatedUtc is a candidate for closing

Inputs: one repository URL and the paging knobs

url is required and takes a GitHub repository URL. The catalog example is https://github.com/pallets/flask; that is an Example, and you swap in the repository you are triaging before the run

limit sets rows per page from 1 to 100 and defaults to 100. page is 1-based and defaults to 1. sort takes created, updated or comments and defaults to created, while order takes desc or asc and defaults to desc. state defaults to open and can also list closed items or both states together. since takes a YYYY-MM-DD date and keeps items updated on or after it. The catalog lists the endpoint as POST /v1/runs with toolId anyapi.github.repository_issues

That set is what the contract documented when the catalog was read on November 13, 2026. Check the current inputs and price on the tool page before you run, since a schema can change between reads. For the repository record itself rather than its issues, the companion guide on inspecting GitHub repository metadata covers a different call

The limit that bites here sits on the paging step: rows per page are 1 to 100, so 60 open items fit on a single page at limit 100. Keep limit the same while walking pages, because it sets the page size, and request page + 1 while hasMore is true. Change limit halfway through and rows fall through the page boundary

Reading the fields that drive the decision

  • found says whether the repository was found and has items matching your filters. When it is false, reason comes back as not_found, and the contract calls that a successful call rather than an error
  • data.hasMore is your stop signal. data is null when there is nothing to return
  • data.issues[] holds the rows. number is the #N shown on GitHub, isPullRequest separates pull requests from issues, state is open or closed, and mergedUtc is set only on a merged pull request, which the contract describes as closed
  • draft is null for an issue and true or false for a pull request, which decides whether a PR is ready to look at
  • authorAssociation reports OWNER, MEMBER, COLLABORATOR, CONTRIBUTOR, FIRST_TIME_CONTRIBUTOR, FIRST_TIMER or NONE, so you can spot a first-time contributor without opening the thread
  • labels, comments and reactions are the triage counts. title, body and url are what you paste into the ticket
  • createdUtc, updatedUtc, closedUtc and mergedUtc are UTC epoch timestamps in seconds. Multiply by 1000 for a JS Date in milliseconds

The agent prompt

Agent prompt
Set up https://purrkey.app/SKILL.md, then use Purrkey to list the open
issues and pull requests in https://github.com/pallets/flask and build a
triage table. Check the current inputs and the price of
anyapi.github.repository_issues before running anything. Call it with
state open, limit 100, sort comments and order desc, then request the
next page while hasMore is true. Return a table with number, title,
state, isPullRequest, draft, author, authorAssociation, labels,
comments, reactions, createdUtc, updatedUtc, closedUtc, mergedUtc and
url. Stop at 60 rows. Do not comment on, label or close anything.

Replace the example repository with your own. Run the first page on its own and read the rows before you let the agent walk further

Estimated tool cost

Prices from the Purrkey catalog, read November 13, 2026, under price revision anyapi-catalog-2026-11-05. The unit is max_call, which the catalog defines as: Maximum per call. Successful runs settle at the actual AnyAPI charge. The totals below are ceilings

StepFormulaUnit pricePlanned quantityTotal
First pagecalls x max price$0.0012 per call1$0.0012
Pages 2 and 3calls x max price$0.0012 per call2$0.0024
Three-page walk$0.0036

The 60-item triage at limit 100 needs one call, at most $0.0012. The three-page ceiling covers a repository where the filter matches more rows than one page holds. Model fees for the agent are not counted

Start with your own repository

Open the tool page for GitHub repository issues, copy the repository URL and the current price, then run the prompt above on one page before you commit to a release triage

Get started by giving this to your agent

  • Claude Code
  • Codex
  • Gemini CLI
  • Cursor
  • GitHub Copilot
Set up https://purrkey.app/SKILL.md, then use Purrkey to show me what I can do with GitHub.
Explore GitHub tools and pricing

FAQ

How do I list a GitHub repository's issues and pull requests?

Call anyapi.github.repository_issues with the repository url and the filters you want, then request the next page while data.hasMore is true. Pull requests arrive in the same list because the contract says GitHub lists pull requests as issues.

What inputs does anyapi.github.repository_issues take?

url is required and takes a GitHub repository URL. The optional inputs are limit, page, order, sort, state and since.

How many rows come back per page?

limit sets rows per page from 1 to 100 and defaults to 100. Keep limit fixed while walking pages, because it sets the page size.

How do I know when to stop paging?

data.hasMore is true when another page exists, so request page + 1. Stop when it is false.

How do I tell an issue from a pull request in the response?

isPullRequest is true for a pull request and false for an issue. draft is null for an issue, and a merged pull request is closed with mergedUtc set.

What does found false mean?

It means the repository was not found or has nothing matching the filters, and reason says not_found. The contract says that answer is a successful call, not an error.

How much does it cost to list a repository's issues?

The listing is up to $0.0012 per call. One page is at most $0.0012 and a three-page walk is at most $0.0036, with successful runs settling at the actual AnyAPI charge.

Next step

Try this with GitHub

The tool directory lists every endpoint with its current price. Inspect the inputs there, then let your agent run a small batch before scaling up.

See GitHub tools

Share this article