List concurrency groups for a workflow run
Lists all concurrency groups associated with a workflow run or its jobs.
The set of groups is derived from the run’s configuration, so a group is
included even when the run no longer has any items currently holding or
waiting in it. In that case the group_members array will be empty.
total_count reflects the number of groups the run participates in by
configuration, not the number with active items.
This differs from GET /repos/{owner}/{repo}/actions/concurrency_groups/{group_name},
which returns 404 when a group has no active items. That endpoint reports
the live state of a group repo-wide, while this endpoint reports the
groups associated with a specific run by configuration.
Results are sorted by group name and support cursor-based pagination via
before and after. The after cursor paginates forward only and does
not emit a rel="prev" Link; use before to page backward from a
forward page’s next cursor.
OAuth app tokens and personal access tokens (classic) need the repo scope to use this endpoint with a private repository.
Parameters
Section titled “ Parameters ”Path Parameters
Section titled “ Path Parameters ”The account owner of the repository. The name is not case sensitive.
The name of the repository without the .git extension. The name is not case sensitive.
The unique identifier of the workflow run.
Query Parameters
Section titled “ Query Parameters ”The number of results per page (max 100). For more information, see “Using pagination in the REST API.”
A cursor, as given in the Link header. If specified, the query only searches for results before this cursor. For more information, see “Using pagination in the REST API.”
A cursor, as given in the Link header. If specified, the query only searches for results after this cursor. For more information, see “Using pagination in the REST API.”
Responses
Section titled “ Responses ”Response
A list of concurrency groups associated with a workflow run.
object
The total number of concurrency groups this workflow run participates in,
derived from the run’s configuration. This count is not filtered by
whether the run currently holds or is waiting in each group, so it can
include groups whose group_members array is empty (for example, when
the run has already released its lease in that group).
object
The name of the concurrency group.
API URL for this concurrency group. May return 404 if the group has no active items at the time it is requested, since the get-by-name endpoint reports the live repo-wide state of a group while this endpoint lists groups associated with a run by configuration.
Items belonging to this workflow run that are either currently holding or waiting for the concurrency group lease. May be empty if the run no longer has any active or queued items in this group.
object
The ID of the workflow run.
The name of the workflow run.
API URL for the workflow run.
Web URL for the workflow run.
Queue position. 0 means the item holds the concurrency lease (in_progress), 1 or higher means queued (pending).
API URL to get items ahead of this item in the concurrency group.
The ID of the job, when the item represents a job-level or reusable-workflow-level lease.
The display name of the job, when the item represents a job-level or reusable-workflow-level lease.
API URL for the job.
Web URL for the job.
Examples
{ "total_count": 2, "concurrency_groups": [ { "group_name": "deploy-prod", "group_url": "https://api.github.com/repos/octocat/Hello-World/actions/concurrency_groups/deploy-prod", "group_members": [ { "run_id": 30433642, "run_name": "Deploy to production", "run_url": "https://api.github.com/repos/octocat/Hello-World/actions/runs/30433642", "run_html_url": "https://github.com/octocat/Hello-World/actions/runs/30433642", "status": "in_progress", "position": 0, "position_url": "https://api.github.com/repos/octocat/Hello-World/actions/concurrency_groups/deploy-prod?ahead_of_run=30433642" } ] }, { "group_name": "ci-build", "group_url": "https://api.github.com/repos/octocat/Hello-World/actions/concurrency_groups/ci-build", "group_members": [ { "run_id": 30433642, "run_name": "Deploy to production", "run_url": "https://api.github.com/repos/octocat/Hello-World/actions/runs/30433642", "run_html_url": "https://github.com/octocat/Hello-World/actions/runs/30433642", "status": "pending", "position": 2, "position_url": "https://api.github.com/repos/octocat/Hello-World/actions/concurrency_groups/ci-build?ahead_of_job=798245260", "job_id": 798245260, "job_name": "build", "job_url": "https://api.github.com/repos/octocat/Hello-World/actions/jobs/798245260", "job_html_url": "https://github.com/octocat/Hello-World/actions/runs/30433642/job/798245260" } ] } ]}Headers
Section titled “ Headers ”Example
<https://api.github.com/resource?page=2>; rel="next", <https://api.github.com/resource?page=5>; rel="last"Resource not found
Basic Error
object
Example generated
{ "message": "example", "documentation_url": "example", "url": "example", "status": "example"}Validation failed, or the endpoint has been spammed.
Validation Error
object
object
Example generated
{ "message": "example", "documentation_url": "example", "errors": [ { "resource": "example", "field": "example", "message": "example", "code": "example", "index": 1, "value": [ "example" ] } ]}