[closed] Can I programmatically export a Report Builder report?
We have users moving from Rational Insight to use the JRS Report Builder, however they are missing a few of the basic functions such as being able to snapshot a report at a point in time, or email report results to a group of people.
I understand these functions are not available, but we can export a report to Excel. It seems like it might be a feasible workaround to programmatically export the report via Excel - are there API's available to do this, or some way we could offer this capability?
The question has been closed for the following reason: "The question is answered, right answer was accepted" by davidhoney Sep 12 '23, 3:56 a.m.
Accepted answer
Hi Jackie,
Yes there is, and it's just a variation of the URL that you would use to view a report.
If you are viewing a report is has a URL as follows:
<server>:<port>/rs/reports#view=<id> where ID is a unique integer, server is where your application is installed and port is the port where the application is accessible from.
To access the excel API you need to call the following URL:
<server>:<port>/rs/reportdefinition/<id>/export/excel/static where server, port and id are the same as the URL where you viewed the report.
Alternatively you can replace "static" with "live" to get a live version of the report that can refreshed from within the Excel application.
Note: these api's are different then ones exposed in the Excel export page which also includes the query ID. The query ID is internal and would be difficult to derive. These URL's are also valid but achieve the same result. The api's above are much more easily derivable.
Hope that helps,
-Steve