Can you list Gerrit reviews from a Jirra issue through the Jira REST API


We have the "Gerrit Code Review for Jira" plugin installed and configured. The plugin is working, I can see the related Gerrit reviews listed in the Jirra issue through the UI. 

Is there a way to see the related Gerrit reviews through the JIRA REST api?

example: curl -u admin:admin http://localhost:8090/jira/rest/api/2/issue/MKY-1


1 answer

1 accepted

0 votes
Accepted answer

You can't get them via REST from JIRA - the Gerrit reviews are rendered as a web panel which does not use REST to get the data.

You have several options, depending on access restrictions and how proficient you are in coding:

  1. Call directly the Gerrit REST API, making the same query as the one executed by the Gerrit plugin for JIRA. The plugin is open source, so you can take a look at the code.
  2. Contribute a REST endpoint to the plugin code
  3. If you use Script Runner, you can write a script to invoke the Gerrit plugin manager which returns this data ( However, this service is not currently public, so you'll need to contribute a change to its source code to make it public. This script can then be exposed as REST in Script Runner.

If you have sufficient access, the easiest way will be option 1.




Suggest an answer

Log in or Sign up to answer
Community showcase
Posted Oct 09, 2018 in Jira Core

How to manage many similar workflows?

I have multiple projects that use variations of the same base workflow. The variations depend on the requirements of the project or issue type. The variations mostly come in the form of new statuses ...

227 views 6 0
Join discussion

Atlassian User Groups

Connect with like-minded Atlassian users at free events near you!

Find a group

Connect with like-minded Atlassian users at free events near you!

Find my local user group

Unfortunately there are no AUG chapters near you at the moment.

Start an AUG

You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs

Groups near you