Skip to content

cmem_client.models.paged_list¤

Models of paged list responses.

A paged endpoint of Corporate Memory returns its items one page at a time, together with a PageDescription of the page.

Classes:

PageDescription¤

Bases: Model

A description of a paged list.

Attributes:

  • size (int) – Number of items requested per page. fetch_data() stops paging as soon as a page returns fewer items than this.
  • number (int) – Zero based index of this page.
  • total_elements (int) – Total number of items across all pages, sent as totalElements.
  • total_pages (int) – Total number of pages, sent as totalPages.

model_config¤

model_config = ConfigDict(extra='allow', populate_by_name=True)

number¤

number: int

size¤

size: int

total_elements¤

total_elements: int = Field(alias='totalElements')

total_pages¤

total_pages: int = Field(alias='totalPages')

Comments