Forums

Articles
Create
cancel
Showing results for 
Search instead for 
Did you mean: 

API not returning all fields

Mark Nelson August 5, 2024

Hey,

I have a strange issue, I am using the V2 API on prem and I am trying to get the estimate field returned for a list of tickets which I have. When  I do a GET on:

api/2/issue/{Issue_ID}

some of the tickets have the 'timetracking' object which contains the Estimate field and some do not.

All these tickets are specified in the same Jira Project and when I look at these in the browser, I can see they all have an Estimate value.

Does any one know what I'm doing wrong here and why I am unable to only get some estimates and not all?

1 answer

0 votes
Anandhi Arumugam _Cprime_
Community Champion
August 7, 2024

Hi @Mark Nelson The timetracking information should be in the JSON returned, somewhere like this

"timetracking": 
{
"originalEstimate": "10m",
"originalEstimateSeconds": 600,
"remainingEstimate": "3m",
"remainingEstimateSeconds": 200,
"timeSpent": "6m",
"timeSpentSeconds": 400
}

If this information is not what you are looking for, please share the JSON response that you received. If you are looking for the worklogs, then this information will be within the worklog data item. Hope this helps. 

Mark Nelson August 7, 2024

Hey @Anandhi Arumugam _Cprime_ - thanks for your reply. I agree that it should be in the JSON returned, but its not. For the issues where it doens't appear I get fields >

timetracking and then an empty object. 
I don't want to share the entire response due to confidential data. When looking at the worklog item I see the below for both issues that return their estimate and those that don't - any idea?
"worklog": {
"startAt": 0,
"maxResults": 20,
"total": 0,
"worklogs": []
},


Anandhi Arumugam _Cprime_
Community Champion
August 7, 2024

Hi @Mark Nelson If that's the case, can you try https://developer.atlassian.com/cloud/jira/platform/rest/v2/api-group-time-tracking/#api-group-time-tracking

https://developer.atlassian.com/cloud/jira/platform/rest/v2/api-group-time-tracking/#api-rest-api-2-configuration-timetracking-get
Mark Nelson August 8, 2024

Unfortunately thats not the version of the API Im using, Im using this:

https://docs.atlassian.com/software/jira/docs/api/REST/9.4.14/

Suggest an answer

Log in or Sign up to answer