Skip to content
On this page

Create Upsell ​

Create a new upsell offer in your store.

Endpoint ​

POST /api/upsell/create

Request Body ​

FieldTypeRequiredDescription
storeIdstringYesStore ID
creatdBystringNoCreator user ID
namestringNoInternal name
titlestringNoDisplay title
descriptionstringNoDescription
productobjectYesMain product object
collectionsarrayNoCollection IDs
productsarrayNoRelated product IDs
discountstringNoDiscount ID

Example ​

json
{
  "name": "Summer Upsell",
  "title": "Get 20% Off on Accessories",
  "description": "Special offer for summer collection.",
  "product": {
    "_id": "product_id",
    "name": "Main Product"
  },
  "collections": ["collection_id1", "collection_id2"],
  "products": ["product_id1", "product_id2"],
  "discount": "discount_id"
}

Response ​

json
{
  "status": "success",
  "data": {
    "_id": "string",
    "name": "Summer Upsell",
    ...
  }
}

Released under the MIT License.