Contextual Merchandising is supported on the Item-based Recommendations family widgets. It works similarly to Item-based recommendation widgets and uses the Product ID/Context ID as an identifier for the item on your site to display relevant recommendations.
The API parameters for Contextual Merchandising remain the same as Item-based recommendations family API parameters with an additional Context PID (not mandatory) as an API parameter as highlighted in this guide. Hence, the API parameters for Contextual Merchandising include the following:
- Item-based recommendations family API parameters
- Context PID parameter
Context PID is the latest addition to Item based recommendations API parameters. Context PID comes into play when a user decides to add a Contextual Merchandising rule as an attribute rule during the widget creation process. An example of a Context PID API parameter is: 4427949
Currently, the Context PID API parameter is not mandatory. In case a Context PID is not passed as an API parameter, our system will consider Item ID as Context PID and Item ID will work as a fallback for Contextual recommendations.
But it is highly recommended to add a Context PID as an API parameter whenever a contextual attribute rule is added for better widget recall set and performance.