I am using active choice plugin, have groovy script which retrieves names of all jobs in Jenkins. Can I write a groovy script which get me list of all the build numbers of t
Try:
def xml=new XmlSlurper().parse("http:{serverName}/Jenkins/rssLatest")
def projects = xml.entry.collect{(it.title as String).split("#")[0].trim()}
println projects
In general I suggest browsing your jenkins feed for the info you want then look for an "rss feed" -- then put that rss URL into the XmlSlurper and see what you get.
Also I tend to work through these things in groovysh, it makes it really easy to explorer how objects work. In this case you might want to also be looking at the raw XML as you try objects in groovysh.