added

Standardize Pagination

In an effort to make our API more user-friendly, our pagination implementation has been standardized to facilitate usage from one endpoint to the next.

To navigate through paginated results, clients can follow the link provided in the X-LINK header, updating the pageKey parameter to the value specified in the X-PAGE-KEY header and maintaining the pageSize parameter as specified in the X-PAGE-SIZE header.

📘

Notes

  • The rel="next" attribute in the X-LINK header indicates that the linked URL is for the next page of results. Clients should use this link for subsequent requests to retrieve the next set of items.
  • The X-LINK header retains any query parameters from the previous request. This ensures continuity between paginated responses, maintaining the original query parameters in subsequent requests for accurate pagination and filtering.

Query params

NameDescription
pageSizeSpecifies the maximum number of items to be returned in a single page of pagination. If a larger number is provided, it will be capped at 100. The minimum value is 1.
pageKeyThis is used to go to the next page of results. It's best to use the x-link header and the 'next' definition, as we've assembled them for you

Impacted endpoints

Standard Overview

🚧

Warning: Currently, there is a known issue where the generated X-LINK header fails to preserve the query parameters from the original request.

Endpoint:

  • /resource

Response:

Status code:

  • 200

Body

  • The response body will contain an array of requested items and be empty if no results exist.

Response Headers:

Name

Description

Example

X-PAGE-KEY

The key for the next page of results.

eyJkYXRhIjogIjIwMjItMDItMjFUMDk6NTk6MDEuNT

X-PAGE-SIZE

The number of items per page.

100

X-LINK

The linked URL is for the next page of results.

https://authvia.com/<version
/resource?pageKey=<>&pageSize=10; rel="next">

X-COUNT

Number of items returned in response.

100