Replies: 1 comment 3 replies
-
You can add pagination parameters to your JSON API query inside the body of your async request. To get the next page, you will have to issue another (separate) async query with different parameters. For the syntax, you can look at: |
Beta Was this translation helpful? Give feedback.
3 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
In case of asyncQuery, retrieving results as embedded response (JSON API), What is the best approach to paginate the records ?
Use Case:
1, Result Data (responseBody) records are huge.
2, Possibility of supporting pagination, for "responseBody"
3, If yes, how to pass the page information to asyncQuery ?
4, How to be in compliance with JSONAPI spec - GET for a specific resource, but paginated !!
Example:
GET http://localhost:8080/api/v1/asyncQuery/ba31ca4e-ed8f-4be0-a0f3-12088fa9263d
{
"data": {
"type": "asyncQuery",
"id": "ba31ca4e-ed8f-4be0-a0f3-12088fa9263d",
"attributes": {
"query": "/group?sort=commonName&fields%5Bgroup%5D=commonName,description",
"queryType": "JSONAPI_V1_0",
"result": {
"recordCount": 5000,
"responseBody": "...."
}
}
}
}
Beta Was this translation helpful? Give feedback.
All reactions