Download all bugs as json
Added by Robin Ovrebo almost 10 years ago
Hi everyone,
I would like to download all bugs in the database as json, is this possible?
The only way I found to download any jsons was through extending the issues page with .json, however it only shows a list of 25 bugs; See: http://www.redmine.org/projects/redmine/issues.json
I either need a link with all bugs in one json,
or
I need to be able to cycle from one link to the next, holding x jsons each pr link.
Thanks for any help,
Robin
Replies (2)
RE: Download all bugs as json - Added by Lucile Quirion almost 10 years ago
Hello,
You should check the wiki, it explains how to access Redmine's data via its API.
I suggest to read the Rest_API and Rest_Issues pages.
You can either get issues.json via your browser or a tool/script/program: languages/tools examples
To get the list of bugs of redmine.org, I guess you're looking for the list of issues filtered with the tracker 'defect'.
The first step would be to get the tracker id:
GET /trackers.json {"trackers":[{"id":1,"name":"Defect"},{"id":2,"name":"Feature"},{"id":3,"name":"Patch"}]}
Then iterate over the issue offset to get all the issues:
GET /issues.json?tracker_i=1&limit=100&offset=0
JSON last attributes "total_count":1027,"offset":0,"limit":100 give you the current offset and issue total_count.
RE: Download all bugs as json - Added by Robin Ovrebo almost 10 years ago
Hi Lucile,
That is perfect,
Thank you very much!