Quantcast
Channel: Active questions tagged rest - Stack Overflow
Viewing all articles
Browse latest Browse all 3667

Jenkins REST API to retrieve completed job info

$
0
0

I am simply trying to retrieve completed job info including the job result and have looked at many articles and still I can't get the completed job info. The latest url I tried is as follows:

https://<myjenkinsserver>/jenkins/<jenkinsinstancename>/api/json/&pretty=true&depth=3&tree=builds[actions[parameters[name,value]],number,result,building]

but still I get nothing that looks at all like what I am looking for. Everything I am seeing appears to be the static jobs defined, not the completed results of the jobs because there is no job number in the results that I see which has to be there if I want to query the results of a completed job!

Here is a snippet of what I get back:

{"_class":"hudson.model.Hudson","assignedLabels":[{"name":"docker"},{"name":"master"}],"mode":"EXCLUSIVE","nodeDescription":"the master Jenkins node","nodeName":"","numExecutors":4,"description":null,"jobs":[{"_class":"hudson.model.FreeStyleProject","name":"build_GBO","url":"https://<jenkinsserver>/jenkins/<jenkinsinstance>/job/API_build_GBO/","color":"disabled"},...

Thoughts?

Thanks,Don Bouchard


Viewing all articles
Browse latest Browse all 3667

Trending Articles