Pagination =========== If pagination is supported by specific method it will accept :py:meth:`models.page.PageRequest` object and return list of items wrapped in :py:meth:`models.page.Page` object. :py:meth:`models.page.Page` object contains information such as page number, size and total number of items. It also contains helper methods that you can use while working with pages. Example of using pagination .. code-block:: python :linenos: import datetime import pprint from lime_trader.models.page import PageRequest from lime_trader import LimeClient client = LimeClient.from_file(file_path="credentials.json") accounts = client.account.get_balances() # need to get account numbers first account_number = accounts[0].account_number # get account number of first account in a list trades = client.account.get_trades(account_number=account_number, date=datetime.date.today(), page=PageRequest(page=1, size=20)) pprint.pprint(trades) pprint.pprint(f"Total elements: {trades.total_elements}") pprint.pprint(f"Has next page: {trades.has_next()}") pprint.pprint(f"Data: {trades.data}")