A new POST /v1/listPullRequests endpoint lets you query all PRs in your merge queue programmatically. Filter by state (not ready, pending, testing, merged, failed, cancelled), time range, and paginate through results. This gives CI integrations and internal tooling a complete view of queue activity without scraping the UI.

Example Request

1curl -X POST https://api.trunk.io/v1/listPullRequests \
2 -H "Content-Type: application/json" \
3 -H "x-api-token: $TRUNK_API_TOKEN" \
4 -d '{
5 "repo": {
6 "host": "github.com",
7 "owner": "my-org",
8 "name": "my-repo"
9 },
10 "targetBranch": "main",
11 "state": "TESTING",
12 "take": 10
13 }'