It's not the same without you

Join the community to find out what other Atlassian users are discussing, debating and creating.

Atlassian Community Hero Image Collage

In C#, how do I get a list of all of the Issues in a given version?

I've been trying to find the clean way to get all of the Issues in a given version from a C# utility we have. I've tried using the Atlassian SDK, as well as the REST API directly. The only successful way I have found, is to get every Issue in a project, then filter it on the client for the version. This is very inefficient. It seems like there should be a way to get only the issues in a given version through the API. 

The REST API, documented here, https://docs.atlassian.com/jira/REST/latest/#api/2/version, lists many options for the version related calls. There is an option "GET /rest/api/2/version/{id}/relatedIssueCounts" described as "get version releated issues. Alas, it only seems to yield counts (statistical information). I don't get the Issue IDs, just the number of Issues. 

I have also tried using jql. I have tried the following, along with many permutations:


curl -D- -u username:passwd -X GET -H "Content-Type: application/json" http://jira/rest/api/2/search?jql=fixVersions=10704

note: not C#, but I am using curl to find the right URL.

With the above, I get the following error:
{"errorMessages":["Field 'fixVersions' does not exist or you do not have permission to view it."],"errors":{}} 

 

What is the right way to do this? Again, I don't want to pull down every single issue in the project, and then filter locally. This makes the calling program too slow. There has got to be an easier way. 



 

1 answer

There is not such field fixVersions, only fixVersion.

change jql=fixVersions=10704 to jql=fixVersion=10704

Suggest an answer

Log in or Sign up to answer
Community showcase
Posted in Jira

We want to hear from you! How do you use Slack and Atlassian together?

Hi Everyone! My name is Mina and I am on Atlassian’s Ecosystems Marketing team. Our team is focused on our technology partnerships and marketplace apps. One of Atlassian’s partners is Slack, who ...

145 views 3 10
Join discussion

Community Events

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

Find an event

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

Unfortunately there are no Community Events near you at the moment.

Host an event

You're one step closer to meeting fellow Atlassian users at your local event. Learn more about Community Events

Events near you