Can I export CSV by using REST API in SAP Business Objects?

Yes, it is feasible and I have done something similar in one of my previous projects. But you need to be little clear on what you need to export. There are two options regarding the content of export:

  • Raw Data ( it is basically the query)
  • Formatted Data ( it is your report)

I will provide you help for both. In case, if you are looking for just exporting the raw data then you can the following call and you should be able to fetch the raw data.

http://<Server Name>:6405/biprws/raylight/v1/documents/<document Id>/dataproviders/<Dataprovider Id>/flows/<Flow Id>

Also as will require the response in CSV, set the ACCEPT to ‘text/plain’ so that the response is returned in the required format not JSON.

If you require not the raw data but the actual report then make the below call:

http://<Server Name>:6405/biprws/raylight/v1/documents/<Document Id>/reports/<Report Id>

Here as well you need to set the ACCEPT as done above for getting the response in the required in CSV format.

Anil SAP Gupta
Anil SAP Gupta

SAP Expert