I want to access an Issue data via a java program using REST API of JIRA

 

1 answer

0 votes

That can be done - REST can be used by any language that supports doing the calls.  Could you explain what you are asking?

Say, I have an issue "XYZ1" , the API call gives me a JSON Response(lots of unnecessary fields), which I want to store a few fields like Status,Assignee,Reporter,etc. in my database (say Oracle/MongoDB).

I am facing difficulty in :

  1. getting JSON from the api call in the development environment(using eclipse)
  2. Parsing the response, to store objects of my interest.

Can you guide me how to go about this?

That's not really a JIRA question - you're getting the issue data from the API call - what you do with it is up to your code. 

On your difficulties

  1. What is your dev environment doing differently to the calls that have worked and returned your issue data
  2. I'd look for a JSON parsing library for java, and a database library for talking to your chosen data store
  3. You mention (lots of fields) - have a look at https://developer.atlassian.com/jiradev/jira-apis/jira-rest-apis/jira-rest-api-tutorials/jira-rest-api-example-query-issues to see how to reduce the results to just the fields you want

Suggest an answer

Log in or Sign up to answer
Community showcase
Published 13 hours ago in Statuspage

194 years of downtime: looking back on incident data from 2018

Statuspage customers logged more than 194 years of collective incidents in 2018. That’s a whopping 87% increase from the  104 years logged in 2017 , and we aren’t even through December yet....

29 views 1 5
Read article

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