Pagination

In this guide, we will look at how to work with paginated responses when querying the Signet API. By default, all responses limit results to twenty. However, you can go as high as 100 by adding a limit parameter to your requests. If you are using one of the official Signet API client libraries, you don't need to worry about pagination, as it's all being taken care of behind the scenes.

When an API response returns a list of objects, no matter the amount, pagination is supported. In paginated responses, objects are nested in a data.items attribute and have pagination metadata that indicates the total count and current position. You can use the limit and offset query parameters to browse pages.

Example using offset-based pagination

In this example, we request the second page by setting an offset of 20 (skipping the first 20 records). As a result, we get a list of blacklisted users and can see the pagination metadata showing we're on page 2 of 8 total pages.

  • Name
    limit
    Type
    integer
    Description

    The number of items to return per page (1-100, default: 20).

  • Name
    offset
    Type
    integer
    Description

    The number of items to skip from the beginning (default: 0).

Manual pagination using cURL

curl -G https://api.getsignet.com/fraud/v1/blacklist/users?limit=20&offset=0 \
  -H "Authorization: Bearer YOUR_API_KEY" 

Paginated response

{
  "success": true,
  "message": "Blacklisted users retrieved successfully.",
  "data": {
    "items": [...],     // Queried data
    "pagination": {
      "total": 150,     // Total number of records
      "limit": 20,      // Number of records per page
      "offset": 20      // Number of records skipped
    }
  }
}

Was this page helpful?