Retrieve recommended upsell campaign
Last updated: 02-Jun-2021
Use the getRecommendedUpsellCampaign method via SOAP API 6.0 to find a campaign for the product code and the other sent filters.
Parameter Name | Type | Required/Optional | Description |
---|---|---|---|
SessionId | String | Required |
Unique 2Checkout session ID code.
|
ProductCode | String | Required |
The primary product code. |
Quantity | Integer | Optional |
The product quantity. |
PriceOptions | String | Optional |
The price options for the primary product. |
EnabledForRenewals | Boolean | Optional |
Returns only upsell campaigns that are enabled (or not) for renewals. |
<?php
require ('PATH_TO_AUTH');
$productCode = 'upsell_module_po';
$quantity = 13;
$priceOptions = 'option1,module_scale_po2=5';
$enabledForRenewals = true;
try {
$results = $client->getRecommendedUpsellCampaign($sessionID, $productCode, $quantity, $priceOptions, $enabledForRenewals);
var_dump($results);
}
catch (SoapFault $e) {
var_dump($e->getMessage());
}
Parameters | Type | Description |
---|---|---|
Object |
Object containing information related to the upsell campaigns, including product information and discount settings. |
Do you have a question? If you didn’t find the answer you are looking for in our documentation, you can contact our Support teams for more information. If you have a technical issue or question, please contact us. We are happy to help.
We’ll help you choose the right payment solution for your business, wherever you want to sell, in-person or online. Our team of experts will happily discuss your needs.