API · GitHub
GET /github/repos/{owner}/{repo}/issues
Issues and pull requests of a GitHub repository, filtered by state, labels and date.
| |
|---|
| Request | GET /v1/github/repos/{owner}/{repo}/issues |
| Operation id | github.repo.issues |
| Cost | 1 credit, refunded if the call fails |
| Auth | API key: Authorization: Bearer <key> or x-api-key. |
Issues and pull requests of a GitHub repository, filtered by state, labels and date.
| Name | Type | Required | Description |
|---|
owner | string | yes | Repository owner (user or organisation). Example: vercel. |
repo | string | yes | Repository name. Example: next.js. |
| Name | Type | Required | Description |
|---|
type | "issue" | "pr" | "all" | no | issue, pr or all (default). One of issue, pr, all. |
state | "open" | "closed" | "all" | no | open (default), closed or all. One of open, closed, all. |
sort | "created" | "updated" | "comments" | no | created (default), updated or comments. One of created, updated, comments. |
direction | "asc" | "desc" | no | desc (default) or asc. One of asc, desc. |
labels | string | no | Comma-separated label names; issues must have all of them. |
since | string | no | Only issues updated at or after this date (YYYY-MM-DD or ISO 8601). |
per_page | integer | no | Items per page, 1-100 (default 30). |
page | integer | no | 1-indexed page number (default 1). |
after | string | no | Cursor: the previous page’s next_cursor (instead of page). |
| Status | Meaning | Schema |
|---|
200 | A page of issues. | GitHubIssuesResponse |
400 | Invalid input. Nothing was charged. | Error |
401 | Missing or invalid API key. | Error |
402 | Not enough credits, a spend cap was reached, or payment is required. | Error |
403 | The target is private, or the account is suspended. | Error |
404 | No public GitHub user, repository or issue by that name. | Error |
429 | Too many requests. Wait for Retry-After seconds. | Error |
503 | GitHub is temporarily unavailable. Retryable; nothing was charged. | Error |
| Field | Type | Description |
|---|
items | GitHubIssue[] | |
page | integer | 1-indexed page this is. |
per_page | integer | |
has_more | boolean | |
next_cursor | string | null | Pass as after for the next page; null at the end. |
Errors use one shape everywhere; see Errors for every code and what to do.