如何通过 REST API 使用 SAP BO 网络智能导出 CSV?

How to export CSV's using SAP BO web intelligence through REST API?

我有一个要求,需要使用 GUI 或 API 自动化从 SAP BO webi 报告中导出 CSV 文件。有什么方法可以使用 REST API's 将报告数据导出到 CSV 文件中?我尝试了 OpenDocument 文档中的以下选项,但没有为 webintelligence 导出 CSV 文件的选项。

url='http://'+obr_ip+':6405/biprws/logon/long'
base_url='https://'+obr_ip+':8443/BOE/OpenDocument/opendoc/openDocument.jsp?iDocID='
export_options = '&sOutputFormat=H&sRefresh=Y&lsSEnter+number+of+days(X):=100&lsSEnter+values+for+Job+Type:=no_value'

这取决于您是要导出报告查询(即原始数据)还是报告(半格式化)。对于查询,使用以下内容:

http://<serverName>:6405/biprws/raylight/v1/documents/{documentID}/dataproviders/{dataproviderID}/flows/{flowID}

将接受设置为 text/plain 以接收 CSV 格式的结果。

对于 CSV 格式的报告,请使用:

http://<serverName>:6405/biprws/raylight/v1/documents/{documentID}/reports/{reportID}

将接受设置为 text/csv 以接收 CSV 格式的结果。

对于两者,根据需要替换 、{documentID}、{dataproviderID}、{documentID}、{reportID] 和 {flowID}