CatalogModule
The catalog on commercetools: products by id, slug or SKU, categories, a category page by its path, and productSearch.
import { CatalogModule } from "@evolve-framework/commercetools";Serves the Catalog part of the GraphQL API: categories, product, productCategoryPageByPath, products, productsBySku, productSearch, productSearchMaxResults, productSearchSuggestions, productSortOrders.
new CatalogModule(options: CatalogModuleOptions)| Option | Type | Description |
|---|---|---|
clientFactory | ClientFactory | The commercetools client its requests to the project go through, built
with |
search? | SearchProvider | Where product search is answered from. Defaults to commercetools' own product search. MoreAny search engine plugs in here by wrapping its adapter:
|
variantDimensions? | VariantDimensionsConfig | Which attributes the variants of a product vary on, keyed by product type key. A project knows its own product types, so pass them here; omitting it falls back to the demo product types. |
searchCacheTtl? | number | How long commercetools' own product search responses are cached, in
milliseconds. Omitted or 0 sends every search to commercetools. A cached
search can list a product for up to this long after it left the result
set; its price and content are always current. Ignored with |
identifierAttributes? | IdentifierAttributes | The attributes a variant's EAN, MPN and HS code are read from. Default
to attributes named |
productKinds? | ProductKindsConfig | Which product types, or which of their variants, are delivered digitally, keyed by product type key. Every other variant is physical. |
stock? | StockOptions | How a variant's stock is worded: the threshold under which the quantity left is shown, and whether an out-of-stock variant with a restock date can be pre-ordered. |
accessoryAttributes? | AccessoryAttributes | The variant attributes the accessories, spare parts, complementary
products, bundle extras (sets of product references) and sales unit are
read from. Default to |
lowestPriceField? | string | The Money custom field on a price that holds the lowest price of the 30
days before its discount, as EU price-indication rules require beside a
reduction. Set by whatever sets the discount. Defaults to |
minimumQuantityAttribute? | string | The variant attributes holding a minimum order quantity, a maximum per
line and a pack size, for |
maximumQuantityAttribute? | string | |
packSizeAttribute? | string |
IdentifierAttributes3The fields of identifierAttributes.
| Field | Type | Description |
|---|---|---|
ean? | string | |
mpn? | string | |
hscode? | string |
Extends AbstractModule<CommercetoolsLoaderContext>.

