Sensefuel can contextualize search results and recommendations according to a store selected by your customer or to a customer context.
This enables you to manage a different assortment per store code or per context, where each item can have different data such as “price”, “sale price”, “availability” etc... and synchronize this information with Sensefuel.
Then when a store code/context selected or defined, the corresponding store code/context must be accessible on your site.
Provide the store code/context code
When this feature is activated (which requires a local inventory feed previously loaded in the Sensefuel platform to manager your catalog with offers), the layer will search for an id of the selected store code/context on your website via a function/variable/datalayer. The aim is to contextualize search results and recommendations with the selected store code/context.
This information is only read by Sensefuel, and no data will be altered or stored. Any alteration of the data must be managed on your side.
It is possible to provide the id of the store code/context through:
- A global JavaScript variable, a datalayer, local storage.
- A cookie.
- An attribute value in a page form (input, selection, text field, etc.).
- Synchronous function.
Signature (when using a function)
- <data>
- function() : <data>
You provide Sensefuel with a synchronous function that gives access to the id of the selected store code/context on your website.
ℹ The store code/context must be strictly identical to the store code value provided in the attribute named “store_code” from your local inventory feed (offer).
Data structure
{
store_id: <string>
}- store_id (String) : must be strictly identical to the store id/context id data provided in an attribute named “store_code” within your local inventory feed (offer)
ℹ The data structure for the store/context id can be merged with the other data structures (add to cart, add to list, anonymized customer data) into a single data structure if required.
Return value
The expected return value of your function must be the store ID expressed as a string.
Availability
The function must be available throughout your entire website.
Function name & configuration
To activate or configure this feature, please contact your Customer Success Manager.