hi
I checked the API documentation (JIRA Service Desk 4.5.0) but I just don’t get how I can get some, to me, rather evident stats out of our Jira Service Desk install…
I basically just want to know how many issues where created this month, compare it with last month or with the stats of the same month last year…
How many issues where got their first response in time, how many issues where handled within the set SLAs.
It looks to me that the only way to get this info out of the API is to send a tremendous amount of requests, get all the issues and parse them manually in order to figure out what these basic figures are…
And I just can not imagine there isn’t a more efficient way to get this info out of Jira SD.
Any suggestions ?
Thanks
dGo
Hi Dmitri,
I am afraid JSD does not provide that as an out-of-the-box API. Depending on what kind of information you want to get in detail, I would use the JQL queries with JSD supported search functions to get the count of the issues of each category you care about. There are JQL search functions for SLA fields like “breached()” or “completed()” that can help you build the queries you need, so you don’t need to parse SLA values on your own.
Alternatively, you could build a report in your JSD project with the metrics you are interested in, then call its UI address, and it will respond with a json you can then parse, but I am not sure if that would be easier. Also reports are limited to one project context and the results from the last year only.
Cheers,
Bart
Hi Bart,
I think that last option sounds nice…
Could you point me to some documentation on that ?
Thanks a lot !
NB: theses stats via API do seem a reasonable expectation to me…
Hi Dmitri,
Here is a doc explaining what reports we have, and what custom kinds can be set up on top of that: Setting up service project reports | Jira Service Management Data Center and Server 5.5 | Atlassian Documentation.
So the way you can work this out is to go to the project and report that shows the data you want, like: /projects/{projectKey}/reports/custom/{reportId}/timescale/{timePeriodId}
. I think it will be easiest if you go to your servicedesk reports page, and see what those Ids are and how they behave as you navigate. For the time period, you can choose any number 1-8 which corresponds to the hardcoded periods from the dropdown below the report graph.
The REST endpoint you are interested in is /rest/servicedesk/reports/1/servicedesk/{projectKey}/report/{reportId}?timescaleId={timescaleId}&_={currentTimestamp}
which then will respond with json object with all the data you can see on the chart on the UI. I am afraid it was meant to be used with the reports UI only, so this endpoint is not documented, but once you get the response, you can then parse what you need.
Cheers,
Bart
1 Like
Cheers Bart
Much appreciated !
Hi there, I am trying to get a response from the endpoint mentioned by @bornatowski above.
I am getting a 404. Wondering if someone could help me out with the endpoint in the event that it has changed in the past year. Thanks