search-icon

DEAR API V2 has been released! Please consider migrating to V2 version as it has more advanced functionality and covers all recent system changes. You can find documentation for API V2 at https://dearinventory.docs.apiary.io/#


Pagination

 

Pagination is the process of dividing content into discrete pages. The benefit of pagination is that it allows for faster response times to requests against large datasets like Customers, Products and Invoices, thus providing a more responsive and flexible API for your mission-critical applications.

DEAR Inventory API currently uses pagination on the following endpoints:

• Customers

• Suppliers

• Products

• ProductFamilies

• ProductAvailability

• Sales

 

All remaining API endpoints do not support pagination.

 

 

Requesting a page

 

Pages are requested by adding page parameter to where {endpoint} and {pagenumber} are placeholders.


For example, if you wanted to retrieve the 3rd page of 100 records from the Products endpoint we would write.



Page size

 

The default page size is 100 records, but is configurable by adding the desired page size in the URL querystring.

The minimum page size is 1 and the maximum page size is 1000 records.

If you want to retrieve the 5th page of 200 ProductAvailability records (ie. 1001st to 1500th record) then you would use this URL:

 

 

Pagination info

 

In the endpoints that support Pagination additional parameter Total is returned with every API call response to provide information regarding how many records there are overall. Below is an example of this structure in JSON for Products endpoint.

{ "Products":[{...}], "Total":41}

Did you find it helpful? Yes No

Send feedback
Sorry we couldn't be helpful. Help us improve this article with your feedback.