Skip to main content

Exports

Download a report as a PDF or a PowerPoint file, as viewers see it. The export answers a link to the file, valid for 15 minutes, so download it right away.

Exports render the whole report, so they have a lower rate limit than other calls.

To keep a copy in Google Drive, OneDrive or SharePoint that stays up to date, set the report's cloud save with updateReportCloudExport: its runs then save it to the folder you choose, and getReportCloudExport tells how the last save went.

Get cloud save

GET https://api.rollstack.com/public/v1/reports/{id}/cloud-export

Where a report is saved after its runs, in Google Drive, OneDrive or SharePoint, and how its last save went, with a link to the saved file. Answers 404 until it is set up with updateReportCloudExport or in the app's scheduling panel.

Requires the slide_decks:read scope.

Operation ID: getReportCloudExport.

Path parameters

  • id (string, required): The report to act on, by its id from listReports or createReport. Only reports whose type is SlideDeck work here: another type, such as a Google Slides presentation, returns 400. You can also copy it from the report's link in Rollstack: it's the part right after /slides/.

Response 200

Success

application/json

  • provider (string, required): Where the report is saved: google saves it to Google Drive as a Google Slides presentation, with its charts as linked Google Sheets charts, and microsoft saves it to OneDrive or SharePoint as a PowerPoint file with native charts. One of google, microsoft.
  • folder (object, required): The folder the report is saved in.
    • id (string, required): The folder's id in Google Drive, OneDrive or SharePoint.
    • name (string, required): The folder's name.
  • fileName (string, required): The saved file's name.
  • trigger (string, required): Which runs save it: all after every run that doesn't fail, scheduled only after the report's scheduled runs, and none never, which stops saving it and keeps the setting. One of all, scheduled, none.
  • updateMethod (string, required): update replaces the saved file with the new version. archive first copies the saved file, named with the date of its last save in datestampSuffix, then replaces it. One of update, archive, updateVisualizations.
  • datestampSuffix (string, required): How archive dates the copies it keeps, as a moment.js format such as MM/DD/YYYY or YYYY-MM-DD.
  • ignoreFailuresOnArchive (boolean, required): With archive, whether a copy that fails still lets the save go on.
  • fileUrl (string or null, required): A link to the saved file, which its sharing in Google Drive, OneDrive or SharePoint lets people open. null until it is first saved.
  • runsAsUserId (number, required): The member whose Google or Microsoft account saves it, as id in listMembers: the one who last chose its folder.
  • lastStatus (string or null, required): Whether the last save worked. null until it is first saved. A failed one emails the member it runs as. One of success, failed.
  • lastStatusMessage (string or null, required): Why the last save failed. null when it worked.
  • lastExportedAt (string (date-time) or null, required): When the report was last saved. null until it is first saved.

Set cloud save

PUT https://api.rollstack.com/public/v1/reports/{id}/cloud-export

Saves a report to a Google Drive, OneDrive or SharePoint folder after its runs, as the app's scheduling panel does, replacing the setting it had. Each save replaces the same file, or archives a dated copy first with archive. The folder is opened with the user's own Google or Microsoft account, which saves the report from then on. To save it now, start a run with startReportRun: a run that doesn't fail then tries to save it when trigger is all, and getReportCloudExport tells whether the save worked, since a failed save doesn't fail the run. Set trigger to none to stop saving it. Only its editors may.

Requires the slide_decks:write scope.

Operation ID: updateReportCloudExport.

Path parameters

  • id (string, required): The report to act on, by its id from listReports or createReport. Only reports whose type is SlideDeck work here: another type, such as a Google Slides presentation, returns 400. You can also copy it from the report's link in Rollstack: it's the part right after /slides/.

Headers

  • Idempotency-Key (string): A unique value, such as a UUID, that makes retrying this call safe. A retry with the same key within 24 hours answers the first call's result instead of running it again. Use a new key for each new call. From 1 to 255 printable ASCII characters.

Request body, required

application/json

  • provider (string, required): Where the report is saved: google saves it to Google Drive as a Google Slides presentation, with its charts as linked Google Sheets charts, and microsoft saves it to OneDrive or SharePoint as a PowerPoint file with native charts. One of google, microsoft.
  • folderUrl (string, required): The folder to save the report in, by its link: a Google Drive folder's link (or its id) with google, or a OneDrive or SharePoint folder's link with microsoft. It's opened with your own Google or Microsoft account connected to Rollstack, which then saves the report, so you must be able to add files to it. Example: https://drive.google.com/drive/folders/1AbCdEfGh.
  • fileName (string): The saved file's name. If omitted, the report's name.
  • trigger (string, required): Which runs save it: all after every run that doesn't fail, scheduled only after the report's scheduled runs, and none never, which stops saving it and keeps the setting. One of all, scheduled, none.
  • updateMethod (string): update replaces the saved file with the new version. archive first copies the saved file, named with the date of its last save in datestampSuffix, then replaces it. Defaults to update. One of update, archive.
  • datestampSuffix (string): How archive dates the copies it keeps, as a moment.js format such as MM/DD/YYYY or YYYY-MM-DD. Defaults to MM/DD/YYYY.
  • ignoreFailuresOnArchive (boolean): With archive, whether a copy that fails still lets the save go on. Defaults to false.

Response 200

Success

application/json

  • provider (string, required): Where the report is saved: google saves it to Google Drive as a Google Slides presentation, with its charts as linked Google Sheets charts, and microsoft saves it to OneDrive or SharePoint as a PowerPoint file with native charts. One of google, microsoft.
  • folder (object, required): The folder the report is saved in.
    • id (string, required): The folder's id in Google Drive, OneDrive or SharePoint.
    • name (string, required): The folder's name.
  • fileName (string, required): The saved file's name.
  • trigger (string, required): Which runs save it: all after every run that doesn't fail, scheduled only after the report's scheduled runs, and none never, which stops saving it and keeps the setting. One of all, scheduled, none.
  • updateMethod (string, required): update replaces the saved file with the new version. archive first copies the saved file, named with the date of its last save in datestampSuffix, then replaces it. One of update, archive, updateVisualizations.
  • datestampSuffix (string, required): How archive dates the copies it keeps, as a moment.js format such as MM/DD/YYYY or YYYY-MM-DD.
  • ignoreFailuresOnArchive (boolean, required): With archive, whether a copy that fails still lets the save go on.
  • fileUrl (string or null, required): A link to the saved file, which its sharing in Google Drive, OneDrive or SharePoint lets people open. null until it is first saved.
  • runsAsUserId (number, required): The member whose Google or Microsoft account saves it, as id in listMembers: the one who last chose its folder.
  • lastStatus (string or null, required): Whether the last save worked. null until it is first saved. A failed one emails the member it runs as. One of success, failed.
  • lastStatusMessage (string or null, required): Why the last save failed. null when it worked.
  • lastExportedAt (string (date-time) or null, required): When the report was last saved. null until it is first saved.

Export report

POST https://api.rollstack.com/public/v1/reports/{id}/exports

Exports a report as PDF or PowerPoint and answers a download link valid for 15 minutes. At most 10 exports a minute per user.

Requires the slide_decks:read scope.

Operation ID: exportReport.

Path parameters

  • id (string, required): The report to act on, by its id from listReports or createReport. Only reports whose type is SlideDeck work here: another type, such as a Google Slides presentation, returns 400. You can also copy it from the report's link in Rollstack: it's the part right after /slides/.

Headers

  • Idempotency-Key (string): A unique value, such as a UUID, that makes retrying this call safe. A retry with the same key within 24 hours answers the first call's result instead of running it again. Use a new key for each new call. From 1 to 255 printable ASCII characters.

Request body, required

application/json

  • format (string, required): The kind of file to create. pdf is a PDF of the report's visible slides; hidden slides are left out. pptx is a PowerPoint file in which hidden slides are included but stay hidden, speaker notes are kept, and charts are images rather than editable charts. One of pdf, pptx.
  • slideIds (array of string): The slides to export, from getReportContent or a reply's changedSlideIds. The file keeps the report's slide order whatever order you list them in. Ids that are not slides of the report are ignored, and so are hidden slides in a PDF. If omitted, the whole report is exported.

Response 200

Success

application/json

  • url (string, required): A link that downloads the exported file, named after the report. Anyone who has the link can download the file, without an API key, until expiresAt.
  • expiresAt (string (date-time), required): When url stops working, 15 minutes after the export. Export the report again to get a new link.