Skip to Content

ManufacturerConnection

A connection to a list of Manufacturer items.

Connection Structure

type ManufacturerConnection { edges: [ManufacturerEdge] nodes: [Manufacturer] pageInfo: PageInfo! totalCount: Int }

Pagination Arguments

ArgumentTypeDescription
firstIntReturns the first n items from the list
lastIntReturns the last n items from the list
beforeStringReturns items before the specified cursor
afterStringReturns items after the specified cursor

PageInfo Structure

The pageInfo object contains metadata about the current page of results and is used to navigate through paginated data. It includes information about whether additional pages exist and provides cursor values for fetching the next or previous page of results.

Fields:

  • hasNextPage: Boolean! - Whether there is a next page of results
  • hasPreviousPage: Boolean! - Whether there is a previous page of results
  • startCursor: String - Cursor of the first item on this page
  • endCursor: String - Cursor of the last item on this page

Example

query GetManufacturers { manufacturers(first: 10, after: "Y3Vyc29yOjE=") { edges { node { id name } cursor } nodes { id name } pageInfo { hasNextPage hasPreviousPage startCursor endCursor } totalCount } }

Edge Type

The ManufacturerEdge type represents a single item in the connection. Each edge contains a node field that holds the actual Manufacturer data, and a cursor field that represents the position of that item in the list. The cursor can be used in pagination arguments to fetch items relative to this position.