statistics

Get the CI runs the merge queues started, and how they ended

Changed on

CI runs the merge queues started, the ones that succeeded, and the ones they tore down before a merge with the reason why, by intervals of time. A run is one check the queue started -- a draft pull request, or the queued pull request itself when it is checked in place -- counted once however many pull requests it carries. A run succeeded when at least one of its pull requests was not torn down after it: it passed, or a later run's result merged it. A run is counted as succeeded or wasted in the interval it ended in, so one still running is in neither. A run that passed and is torn down later, while it waited to merge, moves from succeeded in the interval it passed in to wasted in the one it was torn down in. A merge the queue trusts without running CI is not a run. Divide started by the merged pull requests of queues_merged_count for the CI runs each merge costs. A draft run carries pull requests of several priority rules, so there is no priority rule filter.

get/repos/{owner}/{repository}/stats/ci_runs

Request

  • Base URL: https://api.mergify.com/v1
  • URL: https://api.mergify.com/v1/repos/{owner}/{repository}/stats/ci_runs
  • Auth: one of:
    • HTTP bearer
    • HTTP bearer
    • HTTP bearer

Path parameters

repositorystring required

The name of the repository

ownerstring required

The owner of the repository

Query parameters

base_refstring[] nullable

Base reference(s) of the pull requests

queue_namestring[] nullable

Name of the merge queue(s) for the pull requests

start_atstring date-time nullable

Get the stats from this date: an ISO 8601 datetime with a UTC offset (e.g. 2024-01-01T00:00:00Z); a Unix timestamp or a datetime without an offset is refused. Defaults to 1 day before end_at.

end_atstring date-time nullable

Get the stats until this date: an ISO 8601 datetime with a UTC offset (e.g. 2024-01-01T00:00:00Z); a Unix timestamp or a datetime without an offset is refused. Defaults to now.

Response

Successful Response

Changes