You can use the Rest API to get this information; here is an example:
http://jenkins.yourdomain.com/job/job_name/build_number/api/json?tree=actions [calls [SHORTDESCRIPTION]] & pretty = true
returns
{
"actions" : [
{
"causes" : [
{
"shortDescription" : "Started by an SCM change"
}
]
},
{
},
{
},
{
},
{
},
{
},
{
}
]
}
source
share