Skip to content
Get started

List Snapshots

assets.list_snapshots(strasset_id, AssetListSnapshotsParams**kwargs) -> SyncSnapshotsCursor[AssetListSnapshotsResponse]
GET/assets/{assetId}/snapshots

List snapshots of a canvas type asset

ParametersExpand Collapse
asset_id: str
page_size: Optional[int]

The number of items to return in the response. The default value is 10, maximum value is 100, minimum value is 10

minimum10
maximum100
pagination_token: Optional[str]

A token you received in a previous request to query the next page of items

ReturnsExpand Collapse
class AssetListSnapshotsResponse:
author_id: str
hash: str
raw_data: str
taken_at: float

List Snapshots

import os
from scenario_sdk import Scenario

client = Scenario(
    api_key=os.environ.get("SCENARIO_SDK_API_KEY"),  # This is the default and can be omitted
    api_secret=os.environ.get("SCENARIO_SDK_API_SECRET"),  # This is the default and can be omitted
)
page = client.assets.list_snapshots(
    asset_id="assetId",
)
page = page.snapshots[0]
print(page.author_id)
{
  "snapshots": [
    {
      "authorId": "authorId",
      "hash": "hash",
      "rawData": "rawData",
      "takenAt": 0
    }
  ],
  "nextPaginationToken": "nextPaginationToken"
}
Returns Examples
{
  "snapshots": [
    {
      "authorId": "authorId",
      "hash": "hash",
      "rawData": "rawData",
      "takenAt": 0
    }
  ],
  "nextPaginationToken": "nextPaginationToken"
}