Cart Upsells
With Miso, you can offer upsells on the cart page right before the user goes through the checkout flow. These recommendations are usually related to the existing items in the cart, and often suggested as a replacement.

Introduction
Before a user goes through checkout, Cart Upsells are the "last chance" to suggest items that may result in a more valuable conversion for your site. Typically, upsells are displayed directly on the cart page itself, or in a popup right before the user enters the checkout flow. They are often accompanied by UX strategies like discounting and urgency.
You can trigger Cart Upsells using the Filter Query parameter fq
with the Product to Products API. This parameter is used to filter the recommendations that Miso returns. (For more on filtering and optimization, see our Deep Dive guide.) The Cart Upsells recipe is quite flexible. You can pass in a single product to get a laser-targeted upsell, or generate upsells across the entire cart. You can also narrow down your recommendations using product categories or other attributes. As always, upsells are personalized to the individual user and their real-time interactions on your site.
Before You Start
API Call / JSON Response
To fetch Cart Upsell recommendations, POST to the Product to Products API with the following parameters:
user_id
: The user or anonymous visitor to personalize the recommendations forproduct_ids
: The set of products in the cart for which you want to generate upsells. (Note that it's also possible to generate an upsell for a singleproduct_id
)fq
: Use the Filter Query parameter to return results above a certainprice
and (optionally) matching other attributes likecategories
orbrand
. This filtering is what differentiates the Cart Upsell API recipe from the more generic You May Also Like recipe.
The API will return a list of recommended products that match the Filter Query.
boost_fq
and
diversification
.
Read more in the deep dive
Example API Call
POST /v1/recommendation/product_to_products?api_key=<API_KEY> HTTP/1.1
{
"user_id": "user-123",
"product_ids": ["breyers-reese-pint", "digiorno-frozen-pizza"],
"fq": "categories:\\\"Ice Cream\\\" AND price > 4.99"
}
Example JSON Response
{
"message": "success",
"data": {
"took": 81,
"miso_id": "a4606bf0-ddd3-11eb-ba80-0242ac130004",
"products": [
{
"product_id": "ben-jerry-ice-cream",
"title": "Ben & Jerry Half Baked Ice Cream",
"price": 5.99,
..., // Additional scoring information
},
{
"product_id": "breyers-extra-creamy-vanilla",
"title": "Breyers Extra Creamy Vanilla",
"price": 7.99,
..., // Additional scoring information
},
...
]
}
}
Read more about the scoring information that Miso returns in the API response.
Before You Launch
API Reference
Need more info on the API? Check out our dedicated API page with all the info you could ever want.
Read API Reference