API: cannot query running builds successfully

Answered

Hi all. I can't figure out how to get running builds to actually be included in an API response. I'm trying variations of:

/builds?locator=running:true,personal:any,branch:any

But the response always has a zero `count` and an empty `build` array. I made the user I'm authenticating as an administrator, and that didn't seem to help.

If I leave off the locator query, I get 100 builds, but they're all finished ones.

What am I missing?

Thanks!

4 comments

Hello Harvey,

Please use the following locator to get builds on all branches:

/app/rest/builds?locator=running:true,personal:any,branch:default:any
0

Thanks for the quick response! That seems to work. I'd suggest a docs update, as I'm guessing most people would assume a mere running:true would fetch the running builds.

0

Thank you for your feedback! Actually it's documented in the section. We will try to improve doc or API to make it clearer.

0

Please sign in to leave a comment.