How to retrieve history details of an issue from jira using "jira-rest-java-client"?

I am not able to retrieve history details of an issue using jira rest api.

How I can retrieve history details ?

2 answers

1 accepted

Accepted Answer
0 votes

You can ignore my question. I figured it out :)

getIssueClient().getIssue(bi.getKey(),Arrays.asList(IssueRestClient.Expandos.CHANGELOG));

How does this work? The second argument is ProgressMonitor progressMonitor not an array list.

FOUNT OUT!. getIssueClient().getIssue(bi.getKey(),Arrays.asList(IssueRestClient.Expandos.CHANGELOG), null);

try

<jira_host>/rest/api/2/issue/<ISSUE-KEY>?expand=changelog

I am new to this. i want to retrieve history details using java rest api.

how can I retrieve history details using java rest api.?

You have posted the question again as comment. Faysal's comment was the answer for your question. Read the REST API docs at https://jira.atlassian.com/plugins/servlet/restbrowser#/, search google for how to make REST calls using you language of programming.

For history as Faysal says, pass the extra argument expand=changelog.

Also search this forum for many post on the same topic, for example https://answers.atlassian.com/questions/64708/is-it-possible-to-get-the-issue-history-using-the-rest-api

I believe what nipun was specifically asking was if/how he can do this using the JIRA REST Java Client Library. Is this possible?

Yes, this is what he wanted to know. He didn't post the question as comment, he tried to clarify since the answer has nothing to do with his question.

Suggest an answer

Log in or Sign up to answer
Community showcase
Posted Sep 25, 2018 in Jira

Atlassian Research Workshop opportunity on Sep. 28th in Austin, TX

We're looking for participants for a workshop at Atlassian! We need Jira admins who have interesting custom workflows, issue views, or boards. Think you have a story to sha...

465 views 7 5
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