question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Support paginated results

See original GitHub issue

Could not retrieve all products (if 250 products and more) by just executing : shopifyApi.product.list(). It would be great to be able to handle automatically calling all the products here instead of having to handle the pagination ourselves.

It’s a very new issue for me and it seems to be a rather recent change to the Shopify Admin REST API : https://help.shopify.com/en/api/guides/paginated-rest-results

Issue Analytics

  • State:closed
  • Created 4 years ago
  • Reactions:7
  • Comments:18 (4 by maintainers)

github_iconTop GitHub Comments

8reactions
kdolancommented, Aug 19, 2019

The above solutions are not compliant with the 2019-07 API version. Attempting the above solutions will result in the following 400 Error:

{
    "errors": {
        "page": "page cannot be passed. See https:\/\/help.shopify.com\/api\/guides\/paginated-rest-results for more information."
    }
}

Pagination support either needs to be supported internally or the Link header needs to be returned in addition to the response body to allow a workaround.

7reactions
korucamcommented, Jul 22, 2019

That’s true, but filling the value of page_info is challenging - how can you access the Link header when the Shopify.prototype.request function returns only the .body part of the response?

Read more comments on GitHub >

github_iconTop Results From Across the Web

Paginated results - Documentation | Brightspot CMS
The Query API includes methods for returning paginated results. A paginated result prevents all query results from being returned at one time, ...
Read more >
Paginated Results - Graph API - Meta for Developers
Time pagination is used to navigate through results data using Unix timestamps which point to specific times in a list of data. ......
Read more >
Retrieving paginated results using the AWS SDK for Java 2.x
Many AWS operations return paginated results when the response object is too large to return in a single response. In the AWS SDK...
Read more >
Pagination Best Practices for Google | Documentation
Avoid indexing URLs with filters or alternative sort orders. You may choose to support filters or different sort orders for long lists of...
Read more >
Paginated Table (Results) - Qualtrics
Paginated Tables allow you to view all your open response data from Text Entry questions. In this visualization, you can see the specific...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found