0

I'm working on an application that uses the Box v1 "enterprise" APIs for user and group management (the v2 API doesn't have these methods yet). Specifically, I'm enumerating groups and their associated folders and users using get_groups, get_group_folders, and get_group_users.

I have a large number of groups and folders in my organization, and I'm unable to page through the results; I only get 20 items at a time from each of these APIs. I've tried variations on the page and page_size parameters listed in the API docs, but they don't seem to do anything.

Specifically, each of these three requests gives me the same 20 groups back:

https://www.box.net/api/1.0/rest?api_key=XXX&auth_token=YYY&action=get_groups

https://www.box.net/api/1.0/rest?api_key=XXX&auth_token=YYY&action=get_groups&page=2

https://www.box.net/api/1.0/rest?api_key=XXX&auth_token=YYY&action=get_groups&page_size=50

The same goes for get_group_folders and get_group_users.

Brad
  • 937
  • 1
  • 9
  • 23

1 Answers1

3

For optional parameters you do need to format them within params[]. For example when changing the page_size, your request would be:

http://box.net/api/1.0/rest?action=get_groups&api_key=API_KEY&auth_token=AUTH_TOKEN&params[page_size]=VALUE .

Tosin
  • 46
  • 1