Functions

get-check-run

fn (owner: Str, repo: Str, check-run-id: Any): Map
fn (owner: Str, repo: Str, check-run-id: Any, opts: Map): Map

GET /repos/{owner}/{repo}/check-runs/{check_run_id} - One check run and its structured output summary.

Example

check ::github::checks/get-check-run("acme", "api", 4242)
check.output.summary

get-check-suite

fn (owner: Str, repo: Str, check-suite-id: Any): Map
fn (owner: Str, repo: Str, check-suite-id: Any, opts: Map): Map

GET /repos/{owner}/{repo}/check-suites/{check_suite_id} - One check suite.

Example

suite ::github::checks/get-check-suite("acme", "api", 777)
suite.conclusion

list-check-run-annotations

fn (owner: Str, repo: Str, check-run-id: Any): Vec
fn (owner: Str, repo: Str, check-run-id: Any, params: Map): Vec
fn (owner: Str, repo: Str, check-run-id: Any, params: Map, opts: Map): Vec

GET /repos/{owner}/{repo}/check-runs/{check_run_id}/annotations - Structured file, line, severity, and message evidence. params supports per_page and page.

Example

notes ::github::checks/list-check-run-annotations("acme", "api", 4242, {per_page: 50})
map(notes, `${%.path}:${%.start_line} ${%.message}`)

list-check-runs-for-ref

fn (owner: Str, repo: Str, ref: Str): Map
fn (owner: Str, repo: Str, ref: Str, params: Map): Map
fn (owner: Str, repo: Str, ref: Str, params: Map, opts: Map): Map

GET /repos/{owner}/{repo}/commits/{ref}/check-runs - Check runs from GitHub Actions and external CI for a SHA, branch, or tag. params supports check_name, status, filter ("latest"/"all"), app_id, per_page, and page.

Example

result ::github::checks/list-check-runs-for-ref("acme", "api", "main", {filter: "latest"})
failed filter(result.check_runs, eq(%.conclusion, "failure"))
map(failed, %.name)

list-check-runs-for-suite

fn (owner: Str, repo: Str, check-suite-id: Any): Map
fn (owner: Str, repo: Str, check-suite-id: Any, params: Map): Map
fn (owner: Str, repo: Str, check-suite-id: Any, params: Map, opts: Map): Map

GET /repos/{owner}/{repo}/check-suites/{check_suite_id}/check-runs - Check runs in one suite. params supports check_name, status, filter ("latest"/"all"), per_page, and page.

Example

result ::github::checks/list-check-runs-for-suite("acme", "api", 777, {status: "completed"})
map(result.check_runs, %.name)

list-check-suites-for-ref

fn (owner: Str, repo: Str, ref: Str): Map
fn (owner: Str, repo: Str, ref: Str, params: Map): Map
fn (owner: Str, repo: Str, ref: Str, params: Map, opts: Map): Map

GET /repos/{owner}/{repo}/commits/{ref}/check-suites - Check suites for a SHA, branch, or tag. params supports app_id, check_name, per_page, and page.

Example

result ::github::checks/list-check-suites-for-ref("acme", "api", "v1.2.0")
map(result.check_suites, %.status)