Question
Netlify Identity Admin API user listing pagination configuration
Rin Maple
0 reputation · 31 May 2020, 09:41 UTC
68K views0
Goal
Paginate through all users of a Netlify site using the Identity Admin API endpoint /api/v1/sites/:site_id/users with page and per_page parameters.
Constraints and uncertainty
- The documentation does not state an explicit upper limit for
per_page; empirical tests suggest a silent cap at 100. - It is unclear whether a token with only the
identityscope (non‑admin) receives a 403 Forbidden or a different error when accessing the endpoint. - When
pageexceeds the total number of pages, the API returns an empty array[]with HTTP 200, leaving callers to infer the end of the dataset.
Based on these points, the following questions remain unresolved:
- What is the maximum allowed value for
per_pagebefore the API truncates or returns an error? - Does the API provide any response header (e.g.,
X-Total-PagesorLink) that indicates the total number of pages? - How should a client reliably detect the end of the dataset when an empty array is returned with status 200?