Let's assume I have a table on Slate with pagination enabled with a pageSize of 10 that is backed by an Object-Service-API query which has the following body format:
{
"objectSet": "objectSet.ObjectSet",
"objectSetContext": "optional<ObjectSetContext>",
"pageSize": "integer",
"pageToken": "optional<PageToken>",
"sort": "optional<list<PropertySort>>"
}
Let's also say I have 100 records total, when I first run the query, I start with "pageToken": null
and the response gives the first 10 of the 100 records. The response also includes a pageToken
set to something like: "v1.abc-some-uuid-xyz.10"
.
Now if I want to reach page 5 of the results which should show results 41 to 50, what do I pass as a pageToken to reach those results specifically?
I couldn't find any documentation on the object-service-api. All I could find is in the Slate query tab.
There is a section in the internal documentation under /documentation/product/slate/writeback-foundry
hinting at passing the pagination offset value as the page token. This means that it can be a changing integer value. No need to prefix by parsing the previous pagingToken. Example:
"{{w_tableWidget.gridOptions.pagingOptions.currentOffset}}"