Get build status info along with url , and build number from JSON API

52 views
Skip to first unread message

bhupendra negi

unread,
Oct 12, 2015, 8:42:00 AM10/12/15
to Jenkins Developers, bhupendra...@3dplmsoftware.com
Hello ,

I am building an front-end application for my jenkins server. The  objective is to show build history of the job along with status { success,failed ,aborted etc:).

I tried this JSON REST API :   http://<jenkins server>:8080/jenkins/view/<job name>/job/validation_xxxx_cmd/api/json   , this api gives me this info 

"buildable" : true,
  "builds" : [
    {
      "number" : 32,
      "url" : "http://<jenkins server>>/jenkins/view/<job name>/job/validation_xxxx_cmdd/32/"
    },
    {
      "number" : 31,
      "url" : "http://<jenkins server>/jenkins/view/<job name>/job/validation_xxxx_cmd/31/"
    },
]

along with other info , I also require status of each build along with number and url , how can I achieve this.  Although i can get Individual build result if I go to  http://<jenkins server>/jenkins/view/<job name>/job/validation_xxxx_cmd/31/api/json . i get result as Success or failure etc.
But I need at once all build url , number , status , so that I can use this info to show in my front end.

Thanks ,
Bhupendra 

Oleg Nenashev

unread,
Oct 17, 2015, 12:15:43 PM10/17/15
to Jenkins Developers, bhupendra...@3dplmsoftware.com
Which Jenkins version do you use?
The "result" field should be exported starting from jenkins-1.312

понедельник, 12 октября 2015 г., 15:42:00 UTC+3 пользователь bhupendra negi написал:
Reply all
Reply to author
Forward
0 new messages