TeamCity REST API:谁破坏了构建?

时间:2014-03-11 12:55:13

标签: api rest teamcity build-server teamcity-8.0

在我们的办公室中,我们使用自定义Geckoboard来显示有关我们 TeamCity 8 构建服务器的当前构建状态的信息。

我们使用以下REST查询显示最近签到/更改http://teamcity.internal.com:8080/httpAuth/app/rest/changes?project:ProjectName&locator=count:10

我们还使用此REST查询计算上次构建被破坏http://teamcity.internal.com:8080/httpAuth/app/rest/builds?locator=project:ProjectName

然而,我们不能做的就是将两者联系起来。

换句话说:

  • 对于最近的更改,以确定签入是否导致构建损坏
  • 上次构建被破坏确定是谁进行了此项检查

1 个答案:

答案 0 :(得分:0)

基于源代码here和文档here

我相信你想要的东西如下

http://teamcity.internal.com:8080/httpAuth/app/rest/changes?locator=build:(status:FAILED,project:ProjectName,lookupLimit:1)

这应该返回与上一次FAILED构建相关的更改,我没有测试过,因为我没有使用TeamCity。

另请参阅以下StackOverflow question以获取特定版本的更改。

相关问题