Request

Response

    Pagination

    For queries that return a large number of results (particularly Asset queries), the GraphQL API supports pagination to help manage the amount of data returned in a single request. Pagination allows you to retrieve results in smaller, manageable chunks rather than all at once, and helps manage rate limits. (See the Rate Limits topic for more information about rate limits.)

    The pagination mechanism uses a cursor-based approach, where each page of results includes a cursor that can be used to retrieve the next page. This is more efficient than traditional offset-based pagination, especially for large datasets.

    To use pagination in your query specify pagination parameters. In your query, you can specify the cursor and limit parameters within the pagination object.

    • cursor is a string that indicates where to start retrieving results. The first time you call the query, pass an empty string as the cursor, and then use the returned cursor from each response to retrieve the next page of results. An empty cursor indicates that there are no more results to retrieve.
    • limit specifies the suggested maximum number of results to return in a single request. Note that the actual number of results returned may vary and be slightly more or less than the limit specified. The actual number of items returned is indicated in the pagination.pageSize field of the response.

    See the Code Samples topic for an example of how to use pagination in a query.