Interface: UseProductSearchOptions
Defined in: composables/react/useProductSearch.ts:47
Options for useProductSearch.
Properties
applyOrderlists?
optionalapplyOrderlists?:boolean
Defined in: composables/react/useProductSearch.ts:73
Apply the orderlist filter on the search input. Defaults to true when
orderlistIds is non-empty, false otherwise — so an authenticated user
without a contract still sees the full catalogue.
availability?
optionalavailability?:Availability
Defined in: composables/react/useProductSearch.ts:91
Stock selection to filter by. 'all' or unset sends no stock filter.
Filtering happens server-side, so itemsFound and the page count
describe the filtered set.
brand?
optionalbrand?:string
Defined in: composables/react/useProductSearch.ts:57
Manufacturer/brand to filter by — also triggers a wide search.
categoryId?
optionalcategoryId?:number
Defined in: composables/react/useProductSearch.ts:53
Category id to list products from.
companyId?
optionalcompanyId?:number
Defined in: composables/react/useProductSearch.ts:65
Active company id for company-scoped pricing/visibility.
configuration
configuration:
object
Defined in: composables/react/useProductSearch.ts:101
Portal configuration: base category fallback plus image filters.
anonymousUserId?
optionalanonymousUserId?:number
The channel's anonymous user, seeded by the host. Scopes logged-out listings exactly like the SSR seed does.
baseCategoryId?
optionalbaseCategoryId?:number
imageSearchFiltersGrid?
optionalimageSearchFiltersGrid?:MediaImageProductSearchInput
imageVariantFiltersMedium?
optionalimageVariantFiltersMedium?:TransformationsInput
graphqlClient?
optionalgraphqlClient?:GraphQLClient
Defined in: composables/react/useProductSearch.ts:49
GraphQL client; omit it together with a products array for controlled mode.
language?
optionallanguage?:string
Defined in: composables/react/useProductSearch.ts:59
Language for product queries. Defaults to 'NL'.
minStock?
optionalminStock?:number
Defined in: composables/react/useProductSearch.ts:93
Minimum stock quantity for the 'in-stock' selection.
onCategoryChange?
optionalonCategoryChange?: (category) =>void
Defined in: composables/react/useProductSearch.ts:120
Fires with the resolved category object after each category fetch.
Parameters
category
Category
Returns
void
onFiltersChange?
optionalonFiltersChange?: (filters) =>void
Defined in: composables/react/useProductSearch.ts:110
Fires with the available attribute filters from the category response.
Parameters
filters
AttributeFilter[]
Returns
void
onItemsFoundChange?
optionalonItemsFoundChange?: (count) =>void
Defined in: composables/react/useProductSearch.ts:114
Fires with the total matching item count whenever it changes.
Parameters
count
number
Returns
void
onPageChange?
optionalonPageChange?: (page) =>void
Defined in: composables/react/useProductSearch.ts:116
Fires when the current page changes.
Parameters
page
number
Returns
void
onPriceBoundsChange?
optionalonPriceBoundsChange?: (min,max) =>void
Defined in: composables/react/useProductSearch.ts:112
Fires with the min/max price bounds from the category response.
Parameters
min
number
max
number
Returns
void
onProductsResponse?
optionalonProductsResponse?: (products) =>void
Defined in: composables/react/useProductSearch.ts:118
Fires with the raw ProductsResponse after each category fetch.
Parameters
products
ProductsResponse
Returns
void
orderlistIds?
optionalorderlistIds?:number[]
Defined in: composables/react/useProductSearch.ts:67
Scope the product fetch to specific orderlist IDs (e.g. a chosen B2B contract).
pageSize?
optionalpageSize?:number
Defined in: composables/react/useProductSearch.ts:99
Page size. Defaults to 12.
priceFilterMax?
optionalpriceFilterMax?:number
Defined in: composables/react/useProductSearch.ts:85
Upper price bound filter.
priceFilterMin?
optionalpriceFilterMin?:number
Defined in: composables/react/useProductSearch.ts:83
Lower price bound filter.
products?
optionalproducts?: (Product|Cluster)[]
Defined in: composables/react/useProductSearch.ts:51
When provided, the hook is controlled — it renders these products and skips fetching.
productTrackAttributes?
optionalproductTrackAttributes?:string[]
Defined in: composables/react/useProductSearch.ts:79
Attribute names to request per product, e.g. ['MPN']. Unset returns the
first page of ALL attributes (12 per product), so products with more than
12 silently lose the rest — name what you render.
sortField?
optionalsortField?:string
Defined in: composables/react/useProductSearch.ts:95
Sort field; overrides the internal sort state when set.
sortOrder?
optionalsortOrder?:string
Defined in: composables/react/useProductSearch.ts:97
Sort direction ('ASC' / 'DESC'); overrides internal state when set.
taxZone?
optionaltaxZone?:string
Defined in: composables/react/useProductSearch.ts:61
Tax zone for price calculation. Defaults to 'NL'.
term?
optionalterm?:string
Defined in: composables/react/useProductSearch.ts:55
Free-text search term — triggers a wide search across the base category.
textFilters?
optionaltextFilters?:ProductTextFilterInput[]
Defined in: composables/react/useProductSearch.ts:81
Attribute text filters applied to the category search.
user?
optionaluser?:Contact|Customer|null
Defined in: composables/react/useProductSearch.ts:63
The signed-in user; supplies userId/contactId/customerId for pricing.