recommendations

Description:
  • Interface to recommendations related API calls
Source:
Interface to recommendations related API calls

Methods

(inner) getRecommendations(podId, parametersopt, networkParametersopt) → {Promise}

Description:
  • Retrieve recommendation results from Constructor.io API
Source:
See:
Example
constructorio.recommendations.getRecommendations('t-shirt-best-sellers', {
    numResults: 5,
    filters: {
        size: 'medium'
    },
});
Parameters:
Name Type Attributes Description
podId string Pod identifier
parameters object <optional>
Additional parameters to refine results
Properties
Name Type Attributes Description
itemIds string | array <optional>
Item ID(s) to retrieve recommendations for (strategy specific)
numResults number <optional>
The number of results to return
section string <optional>
The section to return results from
term string <optional>
The term to use to refine results (strategy specific)
filters object <optional>
Key / value mapping of filters used to refine results
variationsMap object <optional>
The variations map object to aggregate variations. Please refer to https://docs.constructor.io/rest_api/variations_mapping for details
preFilterExpression object <optional>
Faceting expression to scope search results. Please refer to https://docs.constructor.io/rest_api/collections#add-items-dynamically
hiddenFields Array.<string> <optional>
Hidden metadata fields to return
networkParameters object <optional>
Parameters relevant to the network request
Properties
Name Type Attributes Description
timeout number <optional>
Request timeout (in milliseconds)
Returns:
Type
Promise