Idea ID: 1682995

Add a Public API to download a report in CSV/PDF/Word format

Status : Delivered
over 2 years ago

Some users prefer to run tests and other operations via API and not using the user interface.

If you were designing the solution, how would you do it?

Add an API to get the report in CSV/PDF/Word format.

Tags:

  • Hi Pratap,

    For question, please use discussion forum or open a ticket to request asistance.

    Regarding "Next we trigger- /test-runs/reports/{reportId} API, the response received isn't in a file format.", does you code wait / loop until the exported file becomes available (http status: 200)?

    Regards,

    Wei Sun

  • Hi Levins,

    We are facing some issue with the above mentioned API. In our Jenkins pipeline, we first trigger - /test-runs/{runId}/reports API and pass pdf or docx report type. Response we receive is the report ID. Next we trigger- /test-runs/reports/{reportId} API, the response received isn't in a file format. We are getting a response, which we are writing onto a file and saving it with .pdf or .docx extension.. When we open the file, we do not see any report.

    I agree from the swagger API, the pdf and docx opens fine.. But when run from our pipeline (Linux OS), it does not help.. Having said that, the csv ones work fine, but isn't in a presentable format to our stakeholders, any thoughts, please?

     

    Thank,

    Pratap