Skip to main content

List report versions

GET https://api.rollstack.com/public/v1/reports/{id}/versions

The Version history of a report of type SlideDeck, newest first, as the app lists it: the versions Rollstack saved while it was edited, run or changed by the slides agent, and those saved with saveReportVersion, each with what saved it. Answers up to limit versions, 20 by default and 100 at most, and a nextCursor: pass it as cursor for the next page, until it is null. Pass a version's id to restoreReportVersion to take the report back to it.

Requires the slide_decks:read scope.

Operation ID: listReportVersions.

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/.

Query parameters

  • limit (integer): Maximum number of versions to return on this page, from 1 to 100. Defaults to 20.
  • cursor (string): Where to continue the list: pass the nextCursor returned with the previous page to get the next one. Omit it for the first page. Example: 6c1f9a2e-3b4d-4e8f-9a1b-2c3d4e5f6a7b.

Response 200

Success

application/json

  • data (array of object, required): The report's Version history, newest first: the versions it can be restored to.

    • id (string, required): Identifies the version. Pass it as versionId to restoreReportVersion.
    • name (string or null, required): The name the version was saved with, such as Before applying Acme for the one a template apply saves. null when it has none: the app then names it after its kind or the time it was saved.
    • kind (string, required): What saved the version.

      • autoSaved: Rollstack, while the report was edited, and just before a version was restored or a template applied.
      • saved: a member, with saveReportVersion.
      • beforeRun, afterRun: a run, just before and after it updated the report.
      • beforeSlidesAgent, afterSlidesAgent: the slides agent, just before and after it changed the report. A reply's versionBeforeId names the one before it.
      • slidesAgent: an earlier version of the slides agent.

      One of autoSaved, saved, beforeRun, afterRun, beforeSlidesAgent, afterSlidesAgent, slidesAgent.

    • savedBy (object or null, required): The member whose edit, run, message or call saved it. null if their account was deleted.
      • id (number, required): The member's user id, the same as their id in listMembers.
      • name (string, required): The member's name, as shown in Rollstack.
      • email (string, required): The member's email address.
    • createdAt (string (date-time), required): When the version was saved.
  • nextCursor (string or null, required): Pass it as cursor to get the next page of versions. null when there are no more.