Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi team,
There is the possibility to export formatted data to excel (data settings: table formatting)
Is it also possible to do this via API?
Thanks, Swen
Hi @SwenWa, it is possible to export data with formatting directly from a Qlik App checking below checkbox before export
Unfortunately, there is no way to do this via API with Capability APIs in Client Managed version.
If you are using Qlik SaaS, this is the API you need for export excel with formatting
Hi @SwenWa, it is possible to export data with formatting directly from a Qlik App checking below checkbox before export
Unfortunately, there is no way to do this via API with Capability APIs in Client Managed version.
If you are using Qlik SaaS, this is the API you need for export excel with formatting
Do you all have an example of how to utilize the reports api to export an object (straight or pivot table) to Excel?
HI, do you know how to export a cvs file from script? (saas)
@bander04 this is an example for exporting an excel from a visualization.
You need to set your tenant host name, webIntegrationId (if you are using this kind of authorization), visualization id, temporaryBookmark and crsf token for authroizate POST requests.
In the response you will find the end point for monitoring the generation status. You have to make a GET requests for checking when report is ready, then when it is complete, you can download it.
const vizId = 'dfXmJ'
const reportSettings = {
"type": "sense-data-1.0",
"senseDataTemplate": {
"appId": appId,
"id": vizId,
"selectionType": "temporaryBookmarkV2",
"temporaryBookmarkV2": {
"id": tempBookmark
}
},
"output": {
"outputId": "Chart_excel",
"type": "xlsx"
}
}
//Generate Report
const report = await fetch(`https://_yourTenantHost_/api/v1/reports`, {
method: "POST",
credentials: "include",
headers: {
"Content-Type": "application/json",
"Qlik-Csrf-Token": csrfToken,
"Qlik-Web-Integration-Id": webIntegrationId
},
body: JSON.stringify(reportSettings),
})
//Get status url for monitoring report generation status
const reportStatusLocation = report.headers.get('Content-Location')
//Check Report APIs status end point for understanding when report is ready to be downloaded
Hey @Rodlibar you cannot export data as csv, this is not supported yet and will be remove from our docs.