Join 34,000+ subscribers and receive articles from our blog about software quality, testing, QA and security.

Is there any option in API to export the test run details which are all updated today in excel?



We have to export the test run details(testcase id, status etc) which are all updated today in excel everyday. Is there any API call to do this work.


Unfortunately no - the documentation for the API is good and the API really deals with creating, modifying, and closing Test Runs rather than reporting on them.

The reports would be better but you can’t choose the format to see the report.

You could export the Test Run, choose Excel, and then filter the Tested On column. You do have the ability to choose the section or more than one section and what columns you want to see - but no filtering. More labor intensive then you would like I am sure.

Outside of querying the db directly it is the only way I can think of doing what you need. Not sure if that is possible if your install of TestRail is hosted by Gurock.


Thanks for the reply…


You could use the get_results_for_run call and use the created_after filter to only return results after a certain timestamp. I would recommend also using the status_id filter to only return results contained in the list of status IDs in the filter. (This eliminates results with null status IDs from being returned.) You could then take all the results returned and write it out to a CSV file.