Skip to content

Update a Upsell

Endpoint: https://api.youcan.shop/upsells/{id}

Method: PUT

Required Scopes

  • edit-upsells

Parameters

Param NameParam TypeDescriptionRequired
namestringNameyes
descriptionstring, nullDescriptionno
product_iduuidProduct id concerned by this upsellyes
product_offer_idsarrayArray of product ids the upsell will displayyes
actionsarray of objects [Action]Yes, No buttons with their settingyes
footerstring, nullText displayed in bottom for upsellno

Response

[200] Ok

json
{
    "id": "b28e8479-6787-4f00-aadc-93b233f4af9f",
    "name": "upsell0001updated",
    "product_offer_ids": [
        "6751f888-57bd-467f-b113-b3f3f556af75"
    ],
    "description": "<p>Buy also this one </p>",
    "footer": "<p>Limited offer</p>",
    "active": false,
    "weight": "1",
    "actions": {
        "btn_no": {
            "size": "small",
            "title": "No",
            "bg_color": "#FFFFFF",
            "font_size": "small",
            "font_color": "#FF0000"
        },
        "btn_yes": {
            "size": "large",
            "title": "Yes",
            "bg_color": "#FFFFFF",
            "font_size": "large",
            "font_color": "#05BE35"
        }
    }
}