Recs only endpoint
The requester needs to supply the following information as JSON.
Parameters | Description | |
---|---|---|
lang | [Optional] Language code of the store. For example:
If not specified, en-gb is the default. |
|
user | [Optional] For example:
Note: When you provide user, also supply id; email is deprecated. |
|
[Deprecated] [Optional] The email address of the customer. For example:
Note: Use id instead because email is deprecated and kept for backward compatibility only. |
||
id | [Optional] Pseudonymised ID of the user. For example:
This identifies the user in the Personalization system. Use the user ID to improve tracking and recommendations; you can use it also in other Optimizely products, such as Email Product Recommendations, and Triggered Messages.Note: For Product Recommendations, to prevent user behavior from being lost, send Optimizely an up-to-date mapping between email addresses and pseudonymized user IDs. This needs to be provided only once so that Optimizely Personalization can replace existing customer email addresses with their corresponding pseudonymized user ID. |
|
info | [Optional] Information about the customer, such as their diet, allergies, gender, loyalty card information. This is given in key-value pairs; the keys need to be defined with Optimizely before use. For example:
New records are created; existing records are updated. |
|
campaignId | The ID of the widget campaign.
|
|
smartRecs | [Optional] Controls which attributes to show in the smartRecs callback.
|
|
showAttributes | [Optional] A comma-separated list of attribute names to send in the smartRecs callback. If this property is not supplied, no attributes are sent. If this property is set to "*", all attributes are sent.
|
|
items | [Optional] A list of products to influence the product recommendations.
|
|
excludeItems | [Optional] A list of products to exclude from the product recommendations.
|
|
recContent | [Optional] Recommendation content configuration for Product Recommendations. Available values are:
|
Example
{
"lang" : "en-gb",
"campaignId" : "k3Rw892i",
"items" : ["ref01", "ref02", "ref03"],
"excludeItems" : ["ref97", "ref99", "ref99"],
"abTestContent" : "full",
"smartRecs" : { "showAttributes": ["*"]
},
"user" : {
"id" : "abcd1234efgh",
"info" : {
"gender" : "male",
"allergy" : "dairy",
"diet" : "vegetarian"
} }
}
If no user information is sent in the request, the response contains non-personalized product recommendations, such as best sellers. If user information is supplied, the product recommendations are personalized.
- The URL for testing in the UAT environment is:
https://uat.peerius.com/tracker/smart-api/recommendations
- The URL with the production end point follows one of the following formats, depending on your provisioned environment:
https://<sitename>.peerius.com/tracker/smart-api/recommendations
https://<sitename>.peerius.episerver.net/tracker/smart-api/recommendations
Contact Optimizely if you are unsure which domain applies to your integration.
Notes
- The sitename part of this address is assigned by Optimizely.
- This entry point requires a request header containing the authentication parameters defined in the Header information section.
- The request body needs to be sent in a POST request.
- Ensure that HTTPS is in the URL.
Updated about 1 year ago