Build is not prioritized despite using queueAtTop=true in TeamCity's REST API
Hello,
I am using the TeamCity REST API to trigger builds, and I have set the queueAtTop=true parameter to prioritize the build. However, despite this, my build is still being placed at the bottom of the queue rather than at the top.
Here’s a snippet of the request body:
{
"branchName": "main",
"buildType": {"id": "%build_id%"},
"queueAtTop": "true" }
TeamCity Professional 2024.07.3 (build 160765)
Has anyone experienced a similar issue? Could there be other factors affecting the build queue that I am overlooking? Any guidance or suggestions would be appreciated.
Thank you!
Please sign in to leave a comment.
To help reproduce the issue, could you please share the API endpoint and the full request body?
Feel free to remove any sensitive information from both the endpoint and the request body
Hey Tom,
Thank you for the reply. Sure, I can share the whole code. I’ve actually created a meta-runner to run a custom build via the API as a build step. Here’s the full listing:
Hi,
According to the addBuildToQueue documentation, the request body should contain a Build object.
Within the Build object, the triggeringOptions field is supported as documented here.
Therefore, please use the following request body:
That helps, thanks a lot!