Paginated List

class fabman.paginated_list.PaginatedList(content_class: Type[FabmanObject], requester: Requester, request_method: str, first_url: str, extra_attribs: dict | None = None, _root: str | None = None, url_override: str | None = None, **kwargs)

Abstracts pagination and rate limiting of the Fabman API. Documentation: https://github.com/FabmanHQ/fabman-api#pagination

Abstracts pagination of the Fabman API. Provides a simple interface to work with objects and requests new objects from the API as needed.

Parameters:
  • content_class (Type[fabman.fabman_object.FabmanObject]) – Class of the stored objects. Must inherit from FabmanObject

  • requester (fabman.requester.Requester) – Requester for refreshing the API

  • request_method (str) – One of “GET”, “POST”, “PUT”, “DELETE”

  • first_url (str) – endpoint to be called for the first page

  • extra_attribs (Optional[dict], optional) – Extra attributes to be added to content_class, defaults to None

  • _root (str, optional) – Root endpoint without parameters, defaults to None

  • url_override (str, optional) – Override the base_url, defaults to None