Sample - GitHub REST API
GET/repos/{owner}/{repo}/commits/{ref}/check-runs

List check runs for a Git reference

Lists check runs associated with a commit reference in a repository. Use ref to identify a commit SHA, branch, or tag, and use check_name, status, filter, or app_id to narrow the results; use page and per_page to paginate the results. When a reference has more than 1,000 check suites, results are limited to the 1,000 most recent suites, so use the check-suite endpoints to retrieve all check runs.

  • RetriesRetries up to 2×, 500ms backoff, 30s timeout.

9 parameters
ownerstringrequired
The account owner of the repository; the name is not case sensitive.
repostringrequired
The repository name without the `.git` extension; the name is not case sensitive.
refstringrequired
The commit reference, specified as a commit SHA, branch name such as `heads/BRANCH_NAME`, or tag name such as `tags/TAG_NAME`.
check_namestringoptional
Filters results to check runs with the specified name.
statusstringoptional
Filters results by check-run status: queued, in_progress, or completed.
Allowed:queuedin_progresscompleted
filterstringoptional
Filters check runs by their `completed_at` timestamp. Use latest for the most recent check runs or all for all available check runs. Defaults to latest when omitted.
Allowed:latestallDefault:latest
per_pageintegeroptional
The number of results to return per page, up to 100. Defaults to 30 when omitted.
Default:30
pageintegeroptional
The page number to retrieve. Defaults to 1 when omitted.
Default:1
app_idintegeroptional
Filters results to check runs created by the specified application identifier.

1 status code
200Returns an object containing `total_count` and a `check_runs` array of check-run objects, including their status, conclusion, commit reference, timestamps, associated check suite, output, and application.
total_countintegerrequired
check_runsarray<CheckRun>required

Error handling

Supply owner, repo, and ref to identify the repository and Git reference. status must be queued, in_progress, or completed, and filter must be latest or all; per_page must not exceed 100.