Pagination

APIs that can return multiple (e.g. thousands) records support retrieving a block or page of records. This pagination policy has two key concepts:

  • page number - identifies a block (page) of records, starting with page number 1. The page number is defined using the optional pageNumber query parameter and its default value is 1;

If the pageNumber is 0, negative or non-numeric - 400 Bad Request will be returned.

  • page size - identifies the number of records for a given page. The page size is defined using the optional pageSize query parameter and its default value is 100. pageSize cannot exceed 1000;

If the pageSize is negative, non-numeric or exceeds the maximum value - 400 Bad Request will be returned.

The response body of APIs supporting pagination includes total property. The total property is the object’s total number of records.

The following table contains example page number and page size values and the range of records retrieved.

Examples

pageNumberpageSizeRecords returned
foo1400 Bad Request
-11400 Bad Request
01400 Bad Request
1foo400 Bad Request
1-1400 Bad Request
11001400 Bad Request
10Empty result but contains total
1101-10
21011-20
31021-30
11001-100
2100101-200
3100201-300
11,0001-1,000
21,0001,101-2,000
31,0002,001-3,000