GitHub v3 REST API

List workflow run artifacts

Lists artifacts for a workflow run. Anyone with read access to the repository can use this endpoint. If the repository is private you must use an access token with the repo scope. GitHub Apps must have the actions:read permission to use this endpoint.

get
{protocol}://{hostname}/api/v3/repos/{owner}/{repo}/actions/runs/{run_id}/artifacts

Query Parameters

per_pageinteger

Results per page (max 100)

Default:30

pageinteger

Page number of the results to fetch.

Default:1

Path Parameters

ownerstringrequired
repostringrequired
run_idintegerrequired

The id of the workflow run.

Response

200 application/json

Response

total_countintegerrequired
artifactsarray[object]required

An artifact

Show Child Parameters
get/repos/{owner}/{repo}/actions/runs/{run_id}/artifacts
 
200 application/json

Cancel a workflow run

Cancels a workflow run using its id. You must authenticate using an access token with the repo scope to use this endpoint. GitHub Apps must have the actions:write permission to use this endpoint.

post
{protocol}://{hostname}/api/v3/repos/{owner}/{repo}/actions/runs/{run_id}/cancel

Path Parameters

ownerstringrequired
repostringrequired
run_idintegerrequired

The id of the workflow run.

Response

202 application/json

Response

object
* Additional properties are NOT allowed.
post/repos/{owner}/{repo}/actions/runs/{run_id}/cancel
 
202 application/json

List jobs for a workflow run

Lists jobs for a workflow run. Anyone with read access to the repository can use this endpoint. If the repository is private you must use an access token with the repo scope. GitHub Apps must have the actions:read permission to use this endpoint. You can use parameters to narrow the list of results. For more information about using parameters, see Parameters.

get
{protocol}://{hostname}/api/v3/repos/{owner}/{repo}/actions/runs/{run_id}/jobs

Query Parameters

filterstring

Filters jobs by their completed_at timestamp. Can be one of:
* latest: Returns jobs from the most recent execution of the workflow run.
* all: Returns all jobs for a workflow run, including from old executions of the workflow run.

Allowed values:latestall

Default:latest

per_pageinteger

Results per page (max 100)

Default:30

pageinteger

Page number of the results to fetch.

Default:1

Path Parameters

ownerstringrequired
repostringrequired
run_idintegerrequired

The id of the workflow run.

Response

200 application/json

Response

total_countintegerrequired
jobsarray[object]required

Information of a job execution in a workflow run

Show Child Parameters
get/repos/{owner}/{repo}/actions/runs/{run_id}/jobs
 
200 application/json

Download workflow run logs

Gets a redirect URL to download an archive of log files for a workflow run. This link expires after 1 minute. Look for
Location: in the response header to find the URL for the download. Anyone with read access to the repository can use
this endpoint. If the repository is private you must use an access token with the repo scope. GitHub Apps must have
the actions:read permission to use this endpoint.

get
{protocol}://{hostname}/api/v3/repos/{owner}/{repo}/actions/runs/{run_id}/logs

Path Parameters

ownerstringrequired
repostringrequired
run_idintegerrequired

The id of the workflow run.

Response

302

Response

get/repos/{owner}/{repo}/actions/runs/{run_id}/logs
 
302

Delete workflow run logs

Deletes all logs for a workflow run. You must authenticate using an access token with the repo scope to use this endpoint. GitHub Apps must have the actions:write permission to use this endpoint.

delete
{protocol}://{hostname}/api/v3/repos/{owner}/{repo}/actions/runs/{run_id}/logs

Path Parameters

ownerstringrequired
repostringrequired
run_idintegerrequired

The id of the workflow run.

Response

Response

delete/repos/{owner}/{repo}/actions/runs/{run_id}/logs