Liquid, JavaScript, themes, sales channels
I am not using any admin API but trying to fetch the products of any shop directly using /products.json endpoint.
Example: storename.com/products.json
It returns 30 products by default, we can set the limit param but the upper limit of limit param is 250 so it will not return more than 250 products.
Also, no other query param is working here so how can I paginate it or view all the products of any store using /products.json?
Also, there is no "link" in header.
Solved! Go to the solution
This is an accepted solution.
The products.json AJAX api endpoint isn't intended to be used as a replacement to the Admin APIs. As such it has limited max products that can be returned and won't support pagination.
If you need to grab all products from a shop look into using the Admin API instead. Once you've got an app made for this it would be simple enough to include it on shops that you have permissions for.
This is an accepted solution.
The products.json AJAX api endpoint isn't intended to be used as a replacement to the Admin APIs. As such it has limited max products that can be returned and won't support pagination.
If you need to grab all products from a shop look into using the Admin API instead. Once you've got an app made for this it would be simple enough to include it on shops that you have permissions for.
Are you ready to take your business to the next level? Look no further than the latest ...
By SarahF_Shopify Apr 15, 2024We’re keeping the ball rolling to make sure you’re always ahead of the game. So buckle ...
By JasonH Apr 8, 2024Portrait of Stephen positioned next to an image of planet Earth, with the Stephen's World ...
By JasonH Mar 18, 2024