> For the complete documentation index, see [llms.txt](https://docs.2checkout.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.2checkout.com/api-reference/reference/cross-sell.md).

# Cross Sell

## Get Cross Sell campaigns by filter

> Use this endpoint to extract information about the cross-sell campaigns you configured.

```json
{"openapi":"3.0.0","info":{"title":"API REST Documentation","version":"6.0-oas3"},"servers":[{"url":"https://api.2checkout.com/rest/6.0"}],"paths":{"/crosssells":{"get":{"tags":["Cross Sell"],"summary":"Get Cross Sell campaigns by filter","description":"Use this endpoint to extract information about the cross-sell campaigns you configured.","parameters":[{"name":"Accept","in":"header","required":true,"style":"simple","explode":false,"schema":{"type":"string","default":"application/json","enum":["application/json"]}},{"name":"X-Avangate-Authentication","in":"header","description":"Authentication header","required":true,"style":"simple","explode":false,"schema":{"type":"string"}},{"name":"CampaignName","description":"The name of the campaign.","in":"query","required":false,"style":"form","explode":true,"schema":{"type":"string"}},{"name":"Status","description":"The status of the campaign; can be ACTIVE/INACTIVE.","in":"query","required":false,"style":"form","explode":true,"schema":{"type":"array","items":{"type":"string"}}},{"name":"Type","in":"query","required":false,"style":"form","explode":true,"schema":{"type":"string","enum":["MERCH","AFF"]}},{"name":"Products","description":"Array of product codes to apply to this campaign.","in":"query","required":false,"style":"form","explode":true,"schema":{"type":"array","items":{"type":"string"}}},{"name":"RecommendedProducts","description":"Array of product codes recommended to the shopper.","in":"query","required":false,"style":"form","explode":true,"schema":{"type":"array","items":{"type":"string"}}},{"name":"StartDate","description":"The date when the cross-sell campaign starts, formatted as YYYY-MM-DD","in":"query","required":false,"style":"form","explode":true,"schema":{"type":"string"}},{"name":"EndDate","description":"The date when the cross-sell campaign ends, formatted as YYYY-MM-DD","in":"query","required":false,"style":"form","explode":true,"schema":{"type":"string"}},{"name":"Page","description":"The page number of the results.","in":"query","required":false,"style":"form","explode":true,"schema":{"type":"number"}},{"name":"Limit","description":"The number of results per page.","in":"query","required":false,"style":"form","explode":true,"schema":{"type":"number"}}],"responses":{"200":{"description":"Returns Cross Sell campaign collection","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CrossSellCampaignSearchResponse"}}}},"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CrossSellSearchError"}}}}}}}},"components":{"schemas":{"CrossSellCampaignSearchResponse":{"type":"object","properties":{"Items":{"type":"array","description":"An array of CrossSellCampaign objects","items":{"$ref":"#/components/schemas/CrossSellCampaign"}},"Pagination":{"$ref":"#/components/schemas/Pagination"}}},"CrossSellCampaign":{"type":"object","properties":{"IdCrossSellingCampaign":{"type":"number"},"Name":{"type":"string"},"CampaignCode":{"type":"string"},"DisplayType":{"type":"string","enum":["cart","review","finish"]},"ProductCode":{"type":"string","enum":["cart","review","finish"]},"MasterProducts":{"type":"array","items":{"type":"string"}},"Products":{"type":"array","items":{"$ref":"#/components/schemas/CrossSellProduct_Search"}}}},"CrossSellProduct_Search":{"type":"object","properties":{"ProductCode":{"type":"string"},"Discount":{"type":"integer"},"DiscountType":{"type":"string","enum":["PERCENT"]},"Type":{"type":"string","enum":["Network","Own"]},"AutoAdded":{"type":"boolean"},"DiscountedPrice":{"type":"array","items":{"$ref":"#/components/schemas/CrossSellProductDiscountedPrice"}},"BasePrice":{"type":"array","items":{"$ref":"#/components/schemas/CrossSellProductBasePrice"}}}},"CrossSellProductDiscountedPrice":{"type":"object","properties":{"Currency":{"type":"string"},"Price":{"type":"number"}}},"CrossSellProductBasePrice":{"type":"object","properties":{"Currency":{"type":"string"},"Price":{"type":"number"}}},"Pagination":{"type":"object","properties":{"Page":{"type":"integer","description":"Number of pages used for displaying the results."},"Limit":{"type":"integer","description":"Limitation of the result numbers."},"Count":{"type":"integer","description":"Total number of results."}}},"CrossSellSearchError":{"type":"object","properties":{"error_code":{"type":"string"},"message":{"type":"string"}}}}}}
```

## Create a new Cross Sell campaign

> Use this endpoint to create a cross-sell campaign for your 2Checkout account.

```json
{"openapi":"3.0.0","info":{"title":"API REST Documentation","version":"6.0-oas3"},"servers":[{"url":"https://api.2checkout.com/rest/6.0"}],"paths":{"/crosssells":{"post":{"tags":["Cross Sell"],"summary":"Create a new Cross Sell campaign","description":"Use this endpoint to create a cross-sell campaign for your 2Checkout account.","operationId":"crossSellCreate","parameters":[{"name":"X-Avangate-Authentication","in":"header","required":true,"style":"simple","explode":false,"schema":{"type":"string"}},{"name":"Accept","in":"header","required":true,"style":"simple","explode":false,"schema":{"type":"string"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CrossSellCreate"}}}},"responses":{"200":{"description":"Create campaign response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CrossSellResponse"}}}},"400":{"description":"Create campaign response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CrossSellResponseException"}}}}}}}},"components":{"schemas":{"CrossSellCreate":{"required":["DisplayInEmail","DisplayType","MasterProducts","Name","Products"],"type":"object","properties":{"Name":{"type":"string","description":"Name of campaign, max 255 chars."},"MasterProducts":{"type":"array","description":"Array of product codes to apply to this campaign.","items":{"type":"string","description":"array of product code ids to which this cross sell is going to be applied to"}},"DisplayType":{"type":"string","description":"Where should cross sell products be displayed","enum":["cart","review","finish"]},"DisplayInEmail":{"type":"boolean","description":"true/false - display in payment receipt emails or not"},"Products":{"type":"array","description":"Array of objects containing the product codes pointing to the promoted products when tied to each master product, the discount value, and the discount type (can only be percent).","items":{"$ref":"#/components/schemas/CrossSellProduct_Response"}},"StartDate":{"type":"string","description":"When should campaign start","nullable":true},"EndDate":{"type":"string","description":"When should campaign end","nullable":true}}},"CrossSellProduct_Response":{"required":["Discount","DiscountType","ProductCode","DiscountedPrice"],"type":"object","properties":{"ProductCode":{"type":"string","description":"product code id of a product that will be suggested"},"Discount":{"type":"number","format":"float","description":"Discount number (in percent), between 0-100"},"DiscountType":{"type":"string","description":"can only be 'PERCENT'","enum":["PERCENT"]},"DiscountedPrice":{"type":"array","items":{"$ref":"#/components/schemas/CrossSellProductDiscountedPrice"}},"Errors":{"type":"array","items":{"type":"string"}}}},"CrossSellProductDiscountedPrice":{"type":"object","properties":{"Currency":{"type":"string"},"Price":{"type":"number"}}},"CrossSellResponse":{"type":"object","properties":{"CampaignCode":{"type":"string","description":"The campaign code that can be used when placing orders."},"Name":{"type":"string","description":"Name of the campaign."},"MasterProducts":{"type":"array","description":"Array of product codes to apply to this campaign.","items":{"type":"string"}},"DisplayType":{"type":"string","description":"The display type of the campaign; Can be cart, review, finish.","enum":["cart","review","finish"]},"DisplayInEmail":{"type":"boolean","description":"Determines if the campaign will be displayed in payment receipt emails. Can be 'true' or 'false'."},"Products":{"type":"array","description":"Array of objects containing the product codes pointing to the promoted products when tied to each master product, the discount value, and the discount type (can only be percent).","items":{"$ref":"#/components/schemas/CrossSellProduct_Response"}},"StartDate":{"type":"string"},"EndDate":{"type":"string","description":"The date when the cross-sell campaign ends, formatted as YYYY-MM-DD."},"Errors":{"type":"array","items":{"type":"string","description":"Validation errors, will be empty in case of successful request"}}}},"CrossSellResponseException":{"type":"object","properties":{"error_code":{"type":"string","description":"Error type"},"message":{"type":"string","description":"Error message"}}}}}}
```

## Update a Cross Sell campaign

> Use this endpoint to update a cross-sell campaign for your 2Checkout account.

```json
{"openapi":"3.0.0","info":{"title":"API REST Documentation","version":"6.0-oas3"},"servers":[{"url":"https://api.2checkout.com/rest/6.0"}],"paths":{"/crosssells":{"put":{"tags":["Cross Sell"],"summary":"Update a Cross Sell campaign","description":"Use this endpoint to update a cross-sell campaign for your 2Checkout account.","operationId":"crossSellUpdate","parameters":[{"name":"X-Avangate-Authentication","in":"header","required":true,"style":"simple","explode":false,"schema":{"type":"string"}},{"name":"Accept","in":"header","required":true,"style":"simple","explode":false,"schema":{"type":"string"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CrossSellUpdate"}}}},"responses":{"200":{"description":"Update campaign success response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CrossSellUpdateResponse"}}}},"400":{"description":"Update campaign error response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CrossSellResponseException"}}}}}}}},"components":{"schemas":{"CrossSellUpdate":{"allOf":[{"type":"object","required":["CampaignCode","CampaignStatus"],"properties":{"CampaignCode":{"type":"string","description":"The unique code of the cross-sell campaign"},"CampaignStatus":{"type":"string","description":"The cross-selll campaign status","enum":["ACTIVE","DISABLED"]}}},{"$ref":"#/components/schemas/CrossSellCreate"}]},"CrossSellCreate":{"required":["DisplayInEmail","DisplayType","MasterProducts","Name","Products"],"type":"object","properties":{"Name":{"type":"string","description":"Name of campaign, max 255 chars."},"MasterProducts":{"type":"array","description":"Array of product codes to apply to this campaign.","items":{"type":"string","description":"array of product code ids to which this cross sell is going to be applied to"}},"DisplayType":{"type":"string","description":"Where should cross sell products be displayed","enum":["cart","review","finish"]},"DisplayInEmail":{"type":"boolean","description":"true/false - display in payment receipt emails or not"},"Products":{"type":"array","description":"Array of objects containing the product codes pointing to the promoted products when tied to each master product, the discount value, and the discount type (can only be percent).","items":{"$ref":"#/components/schemas/CrossSellProduct_Response"}},"StartDate":{"type":"string","description":"When should campaign start","nullable":true},"EndDate":{"type":"string","description":"When should campaign end","nullable":true}}},"CrossSellProduct_Response":{"required":["Discount","DiscountType","ProductCode","DiscountedPrice"],"type":"object","properties":{"ProductCode":{"type":"string","description":"product code id of a product that will be suggested"},"Discount":{"type":"number","format":"float","description":"Discount number (in percent), between 0-100"},"DiscountType":{"type":"string","description":"can only be 'PERCENT'","enum":["PERCENT"]},"DiscountedPrice":{"type":"array","items":{"$ref":"#/components/schemas/CrossSellProductDiscountedPrice"}},"Errors":{"type":"array","items":{"type":"string"}}}},"CrossSellProductDiscountedPrice":{"type":"object","properties":{"Currency":{"type":"string"},"Price":{"type":"number"}}},"CrossSellUpdateResponse":{"allOf":[{"$ref":"#/components/schemas/CrossSellUpdate"},{"type":"object","properties":{"Errors":{"type":"array","items":{"type":"string"}}}}]},"CrossSellResponseException":{"type":"object","properties":{"error_code":{"type":"string","description":"Error type"},"message":{"type":"string","description":"Error message"}}}}}}
```

## Get Cross Sell campaigns by code

> Use this endpoint to extract information about the cross-sell campaign identified by the provided campaign code.

```json
{"openapi":"3.0.0","info":{"title":"API REST Documentation","version":"6.0-oas3"},"servers":[{"url":"https://api.2checkout.com/rest/6.0"}],"paths":{"/crosssells/{campaignCode}/campaign":{"get":{"tags":["Cross Sell"],"summary":"Get Cross Sell campaigns by code","description":"Use this endpoint to extract information about the cross-sell campaign identified by the provided campaign code.","parameters":[{"name":"Accept","in":"header","required":true,"style":"simple","explode":false,"schema":{"type":"string","default":"application/json","enum":["application/json"]}},{"name":"X-Avangate-Authentication","in":"header","description":"Authentication header","required":true,"style":"simple","explode":false,"schema":{"type":"string"}},{"name":"campaignCode","description":"The campaign code.","in":"path","required":true,"style":"simple","explode":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Returns Cross Sell campaign collection","content":{"application/json":{"schema":{"$ref":"#/components/schemas/GetCrossSellResponse"}}}},"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CrossSellError"}}}}}}}},"components":{"schemas":{"GetCrossSellResponse":{"type":"object","properties":{"CampaignCode":{"type":"string","description":"Unique, system-generated cross-sell campaign code."},"Name":{"type":"string","description":"Campaign name.","enum":["cart","review","finish"]},"CampaignStatus":{"type":"string","description":"The status of the cross-sell campaign.","enum":["ACTIVE","DISABLED"]},"CampaignOwnerType":{"type":"string","description":"Campaign owner type: Can be either MERCH or AFF.","enum":["MERCH","AFF"]},"MasterProducts":{"type":"array","description":"Array of product codes for the items you set to trigger the cross-sell campaign.","items":{"type":"string"}},"DisplayType":{"type":"string","description":"- cart (Shopping cart),\n- review (Review page),\n- finish (Thank you page)","enum":["cart","review","finish"]},"DisplayInEmail":{"type":"boolean","description":"True or false depending on whether you set the cross-sell campaign to display in payment receipt emails or not."},"Products":{"type":"array","items":{"$ref":"#/components/schemas/GetCrossSellProduct_Response"}},"StartDate":{"type":"string","description":"YYYY-MM-DD. The start date you set for the cross- sell campaign."},"EndDate":{"type":"string","description":"YYYY-MM-DD. The end date you set for the cross- sell campaign."}}},"GetCrossSellProduct_Response":{"required":["Discount","DiscountType","ProductCode","DiscountedPrice","BasePrice"],"type":"object","properties":{"ProductCode":{"type":"string","description":"product code id of a product that will be suggested"},"Discount":{"type":"number","description":"Discount number (in percent), between 0-100"},"DiscountType":{"type":"string","description":"can only be 'PERCENT'","enum":["PERCENT"]},"DiscountedPrice":{"type":"array","items":{"$ref":"#/components/schemas/CrossSellProductDiscountedPrice"}},"BasePrice":{"type":"array","items":{"$ref":"#/components/schemas/CrossSellProductBasePrice"}}}},"CrossSellProductDiscountedPrice":{"type":"object","properties":{"Currency":{"type":"string"},"Price":{"type":"number"}}},"CrossSellProductBasePrice":{"type":"object","properties":{"Currency":{"type":"string"},"Price":{"type":"number"}}},"CrossSellError":{"type":"object","properties":{"error_code":{"type":"string"},"message":{"type":"string"}}}}}}
```

## POST /crosssells/settings/

>

```json
{"openapi":"3.0.0","info":{"title":"API REST Documentation","version":"6.0-oas3"},"servers":[{"url":"https://api.2checkout.com/rest/6.0"}],"paths":{"/crosssells/settings/":{"post":{"tags":["Cross Sell"],"parameters":[{"name":"X-Avangate-Authentication","in":"header","required":true,"style":"simple","explode":false,"schema":{"type":"string"}},{"name":"Accept","in":"header","required":true,"style":"simple","explode":false,"schema":{"type":"string"}}],"responses":{"200":{"description":"Returns cross sell","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CrossSellSetting"}}}},"500":{"description":"Validation errors","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CrossSellError"}}}}}}}},"components":{"schemas":{"CrossSellSetting":{"required":["displayProductsMax","maxThumbSize"],"type":"object","properties":{"displayProductsMax":{"type":"integer"},"maxThumbSize":{"type":"integer","enum":[60,80,100,150]},"displayShortDescription":{"type":"boolean"}}},"CrossSellError":{"type":"object","properties":{"error_code":{"type":"string"},"message":{"type":"string"}}}}}}
```

## Add cross-sell campaign texts

> \*\*\*\
> \
> \*\*Overview\*\*\
> Add cross-sell campaigns texts.

```json
{"openapi":"3.0.0","info":{"title":"API REST Documentation","version":"6.0-oas3"},"servers":[{"url":"https://api.2checkout.com/rest/6.0"}],"paths":{"/crosssells/campaignTexts/":{"post":{"tags":["Cross Sell"],"summary":"Add cross-sell campaign texts","operationId":"addCrossSellTexts","description":"***\n\n**Overview**\nAdd cross-sell campaigns texts.","parameters":[{"name":"Accept","in":"header","required":true,"style":"simple","explode":false,"schema":{"type":"string","default":"application/json","enum":["application/json"]}},{"name":"X-Avangate-Authentication","in":"header","required":true,"style":"simple","explode":false,"schema":{"type":"string"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CrossSellTextsRequest"}}}},"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CrossSellTextsResponse"}}}}}}}},"components":{"schemas":{"CrossSellTextsRequest":{"type":"array","items":{"$ref":"#/components/schemas/CrossSellTextRequest"}},"CrossSellTextRequest":{"type":"object","properties":{"Language":{"type":"string","description":"language code"},"Title":{"type":"string","description":"campaign title in the related language"},"Description":{"type":"string","description":"campaign description in the related language"}}},"CrossSellTextsResponse":{"type":"array","items":{"$ref":"#/components/schemas/CrossSellTextResponse"}},"CrossSellTextResponse":{"allOf":[{"$ref":"#/components/schemas/CrossSellTextRequest"},{"type":"object","properties":{"Errors":{"type":"array","items":{"type":"string"}}}}]}}}}
```

## Edit cross-sell campaign texts

> \*\*\*\
> \
> \*\*Overview\*\*\
> Edit cross-sell campaigns texts.

```json
{"openapi":"3.0.0","info":{"title":"API REST Documentation","version":"6.0-oas3"},"servers":[{"url":"https://api.2checkout.com/rest/6.0"}],"paths":{"/crosssells/campaignTexts/":{"put":{"tags":["Cross Sell"],"summary":"Edit cross-sell campaign texts","operationId":"editCrossSellTexts","description":"***\n\n**Overview**\nEdit cross-sell campaigns texts.","parameters":[{"name":"Accept","in":"header","required":true,"style":"simple","explode":false,"schema":{"type":"string","default":"application/json","enum":["application/json"]}},{"name":"X-Avangate-Authentication","in":"header","required":true,"style":"simple","explode":false,"schema":{"type":"string"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CrossSellTextsRequest"}}}},"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CrossSellTextsResponse"}}}}}}}},"components":{"schemas":{"CrossSellTextsRequest":{"type":"array","items":{"$ref":"#/components/schemas/CrossSellTextRequest"}},"CrossSellTextRequest":{"type":"object","properties":{"Language":{"type":"string","description":"language code"},"Title":{"type":"string","description":"campaign title in the related language"},"Description":{"type":"string","description":"campaign description in the related language"}}},"CrossSellTextsResponse":{"type":"array","items":{"$ref":"#/components/schemas/CrossSellTextResponse"}},"CrossSellTextResponse":{"allOf":[{"$ref":"#/components/schemas/CrossSellTextRequest"},{"type":"object","properties":{"Errors":{"type":"array","items":{"type":"string"}}}}]}}}}
```

## Retrieve cross-sell campaign texts

> \*\*\*\
> \
> \*\*Overview\*\*\
> Extract information on all cross-sell campaigns texts.

```json
{"openapi":"3.0.0","info":{"title":"API REST Documentation","version":"6.0-oas3"},"servers":[{"url":"https://api.2checkout.com/rest/6.0"}],"paths":{"/crossselltexts/":{"get":{"tags":["Cross Sell"],"summary":"Retrieve cross-sell campaign texts","description":"***\n\n**Overview**\nExtract information on all cross-sell campaigns texts.","parameters":[{"name":"Accept","in":"header","required":true,"style":"simple","explode":false,"schema":{"type":"string","default":"application/json","enum":["application/json"]}},{"name":"X-Avangate-Authentication","in":"header","required":true,"style":"simple","explode":false,"schema":{"type":"string"}}],"responses":{"200":{"description":"OK","content":{"application/json":{}}}}}}}}
```

## Retrieve cross-sell campaign texts

> \*\*\*\
> \
> \*\*Overview\*\*\
> Extract information on all cross-sell campaigns texts.

```json
{"openapi":"3.0.0","info":{"title":"API REST Documentation","version":"6.0-oas3"},"servers":[{"url":"https://api.2checkout.com/rest/6.0"}],"paths":{"/crossselltexts/{Language}/":{"get":{"tags":["Cross Sell"],"summary":"Retrieve cross-sell campaign texts","description":"***\n\n**Overview**\nExtract information on all cross-sell campaigns texts.","parameters":[{"name":"Language","in":"path","description":"ISO 4217 code for the language of the cross-sell campaign text.","required":true,"style":"simple","explode":false,"schema":{"type":"string"}},{"name":"Accept","in":"header","required":true,"style":"simple","explode":false,"schema":{"type":"string","default":"application/json","enum":["application/json"]}},{"name":"X-Avangate-Authentication","in":"header","required":true,"style":"simple","explode":false,"schema":{"type":"string"}}],"responses":{"200":{"description":"OK","content":{"application/json":{}}}}}}}}
```


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://docs.2checkout.com/api-reference/reference/cross-sell.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
