ProductRecommendationsActions
ProductRecommendationsActions
The product recommendations action creators.
See Dispatch Actions.
Loader Function
loadProductRecommendationsActions
Loads the productRecommendations
reducer and returns possible action creators.
Parameters
-
engine:
ProductRecommendationEngine
The headless engine.
Returns ProductRecommendationsActionCreators
: The product recommendations action creators.
ProductRecommendationsActionCreators
getProductRecommendations
Refreshes the product recommendations.
Returns AsyncThunkAction<GetProductRecommendationsThunkReturn, void, AsyncThunkSearchOptions<StateNeededByGetProductRecommendations>>
: A dispatchable action.
setProductRecommendationsAdditionalFields
Updates the additional requested result fields.
Parameters
-
payload:
SetProductRecommendationsAdditionalFieldsActionCreatorPayload
The action creator payload.
Returns PayloadAction<SetProductRecommendationsAdditionalFieldsActionCreatorPayload>
: A dispatchable action.
setProductRecommendationsBrandFilter
Updates the brand used to filter recommendations.
Parameters
-
payload:
SetProductRecommendationsBrandFilterActionCreatorPayload
The action creator payload.
Returns PayloadAction<SetProductRecommendationsBrandFilterActionCreatorPayload>
: A dispatchable action.
setProductRecommendationsCategoryFilter
Updates the category used to filter recommendations.
Parameters
-
payload:
SetProductRecommendationsCategoryFilterActionCreatorPayload
The action creator payload.
Returns PayloadAction<SetProductRecommendationsCategoryFilterActionCreatorPayload>
: A dispatchable action.
setProductRecommendationsMaxNumberOfRecommendations
Updates the maximum number of recommendations to return.
Parameters
-
payload:
SetProductRecommendationsMaxNumberOfRecommendationsActionCreatorPayload
The action creator payload.
Returns PayloadAction<SetProductRecommendationsMaxNumberOfRecommendationsActionCreatorPayload>
: A dispatchable action.
setProductRecommendationsRecommenderId
Updates the recommender id, used to determine the machine-learning model that should fulfill the request.
Parameters
-
payload:
SetProductRecommendationsRecommenderIdActionCreatorPayload
The action creator payload.
Returns PayloadAction<SetProductRecommendationsRecommenderIdActionCreatorPayload>
: A dispatchable action.
setProductRecommendationsSkus
Updates the skus for which to retrieve recommendations.
Parameters
-
payload:
SetProductRecommendationsSkusActionCreatorPayload
The action creator payload.
Returns PayloadAction<SetProductRecommendationsSkusActionCreatorPayload>
: A dispatchable action.
Related Types
SetProductRecommendationsAdditionalFieldsActionCreatorPayload
Properties
-
additionalFields:
string[]
The additional result fields to request.
SetProductRecommendationsBrandFilterActionCreatorPayload
Properties
-
brand:
string
The brand to filter recommendations by.
SetProductRecommendationsCategoryFilterActionCreatorPayload
Properties
-
category:
string
The category to filter recommendations by.
SetProductRecommendationsMaxNumberOfRecommendationsActionCreatorPayload
Properties
-
number:
number
The maximum number of recommendations to return.
SetProductRecommendationsRecommenderIdActionCreatorPayload
Properties
-
id:
string
The recommender id, used to determine the machine-learning model that should fulfill the request.
SetProductRecommendationsSkusActionCreatorPayload
Properties
-
skus:
string[]
The skus to retrieve recommendations for.