Categories API only pulling 50 categories

不羁的心 提交于 2019-12-25 11:15:08

问题


I'm trying to pull all of the categories from my store via the API. But I can't seem to get it to work. I only get 50. Is there a limit to how many categories that can be pulled?

Thanks,


回答1:


By default the API will return a maximum of 50 items for any resources requested via the API. To increase the number of returned categories you can include a limit parameter in your request. In addition you can also specify a page parameter to retrieve a particular page of results.

Example

To return the 2nd page of the categories with 10 results per page, you would make the following request

GET /categories.json?limit=10&page=2


来源:https://stackoverflow.com/questions/17056786/categories-api-only-pulling-50-categories

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!