Join GitHub today
GitHub is home to over 40 million developers working together to host and review code, manage projects, and build software together.Sign up
Add pagination to /admin/users/list API #4866
Prior to this, only the first 100 active/new/etc. users were available via the
Added tests to cover pagination.
Prior to this, only the first 100 active/new/etc. users were available via the `/admin/users/list` API. This change adds support for a `page=#` querystring parameter so that *all* of the users can be retrieved. Requests for pages past the last user result in an empty-list response; requests for negative pages (or zero) just return the first page. Added tests to cover pagination.
Related to discourse/discourse#4866, document the `page` parameter. I also noted that several of the parameters were marked as in `path`, but I believe these should be in `query`... if I'm wrong, and these need to be `path` for some reason, just let me know and I'll roll them back. But, FWIW, when I try using the API myself, those values only seem to work when in the querystring.