List the merge queue
GET/api/repos/{owner}/{repo}/merge-queue
listMergeQueue
Requires authentication using a bearer token or a session cookie — see tokens and scopes.
curl
curl -X GET 'https://neosource.dev/api/repos/OWNER/REPO/merge-queue' \
-H 'Authorization: Bearer $NEOSOURCE_TOKEN'fetch
fetch("https://neosource.dev/api/repos/OWNER/REPO/merge-queue", {
method: "GET",
headers: {
Authorization: "Bearer $NEOSOURCE_TOKEN",
},
});Path parameters
ownerrequiredRepository owner or organization slug.
reporequiredRepository name.
Query parameters
target_branch
Responses
200Ordered merge queue
application/json
Standard errors
Bodies documented once for the whole API — see standard errors.
- 400Bad Request — one of: invalid_input
- 403Forbidden — one of: forbidden
- 404Not Found — one of: not_found
- 423Locked — one of: busy
- 429Rate limited — retry after the `Retry-After` header
- 500Internal server error
- 503Service temporarily unavailable / at capacity — retry after the `Retry-After` header
- 504Gateway timeout — the request exceeded the server's handling budget
Schemas
Referenced above. Listed here rather than expanded inline, so the same definition is not repeated at every level.
PrMergeQueueSummary
`PartialEq` because the drive publishes an entry exactly when this — the face the API shows — differs from what the entry showed before the step (`merge_queue.rs`, `QueueFrames`): a record rewrite that changes nothing visible (a `blocked_by` refresh every tick, a `waits` verdict) must not nudge every viewer's queue.
blocked_byrequired- items
enqueued_atrequiredentry_idrequiredhead_commitrequiredmethodrequiredpositionspeculative_headstaterequiredtarget_branchrequired
MergeQueueCandidateChecks
What is running against a queue entry's candidate, joined SERVER-SIDE. The queue page used to fetch `/commits/{sha}/runs` once per entry on every poll — three entries were four requests every five seconds. The join lives here so the page is one request, and, more to the point, so the row shows the SAME set the merge gate judges: `neosource_forge::head_checks` collapses the candidate's runs to the newest per context (a re-run supersedes the attempt before it), and a client that rolled up the raw run list would paint a red row beside an entry the gate is about to publish. One collapse, stated once, read by both.
checks_summaryrequiredheadrequiredThe candidate commit judged (40-char Git OID hex) — equal to the entry's `speculative_head`, repeated so the block is self-describing.
runsrequiredThe runs that contributed a surviving check, newest first and distinct — what the row links to. Empty exactly when `checks_summary.total` is zero.
itemsworkflowsThe same set split by workflow, in row order (by path, then id) — what a queue row paints one icon per, as the PR list does.
items
MergeQueueGate
Which commit's checks an entry's gate reads — derived from the private preparation, so a list row can show the CI that actually decides it instead of inferring that from which commit hexes are present.
"speculative""pr_head""unprepared"