05/17/2023 05:48 PM
Hello
We are onboarding one application called TriNet
I would like to know if we can use offset pagination method with response below.
cuz, we can't make nextUrl in current response.
It has Total Count and hasMore attribute in response
we can use URL parameter "Offset" to pull accounts from certain index but it's starting from 0 not 1.
This seems sample pagination JSON with offset. I am not sure what attribute we can use in Offset Param and Batch Param.
"pagination": { "offset": { "offsetParam": "offset", "batchParam": "limit", "batchSize": 25, "totalCountPath": 500000 }
If anyone has experience in this, please help me.
Thanks
05/17/2023 10:45 PM
Could you please try following sample :
"pagination": {
"page": {
"pageSizeParam": "size",
"pageSize": 20,
"pageRecordCount": "completeResponseMap.numberofElements",
"pageNumberParam": "page",
"totalCountPath": "completeResponseMap.totalElements",
"firstPageNumber": 1
}
}