Skip to main content

products

This query returns a collection of products that match the requested filters. Optional free-text search is compared against the product code or product name. Custom metadata is not included in search; use filters.metadata to filter by stored customerMetadata entries (same sanitisation rules as updateProductMetadata). Prefer cursorPagination for large result sets (for example sync/export); deep offset pages remain expensive even with indexes. Existing pagination: { page, pageSize } behaviour is unchanged. Do not provide pagination and cursorPagination together.

products(
search: String
pagination: Pagination
cursorPagination: CursorPagination
options: QueryOptions
filters: ProductsQueryFilters
): ProductData

Arguments

products.search ● String scalar

products.pagination ● Pagination input

products.cursorPagination ● CursorPagination input

Cursor-based pagination alternative to pagination. Mutually exclusive with pagination. Use the last product's id as cursor for the next page. Results are always ordered by _id ascending for NEXT (and descending then reversed for PREVIOUS).

products.options ● QueryOptions input

products.filters ● ProductsQueryFilters input

Type

ProductData object

A collection of products and the relevant pagination information. With offset pagination, pageInfo is a standard PageInfo. With cursorPagination, pageInfo uses the PageInfoForCursorPagination shape (pageSize and hasMore only; page is unset).