layout: m1x_soap title: Balance Remove Amount
Allows you to remove store credit amount from the shopping cart (quote) and increase the customer store credit.
Arguments:
Type | Name | Description |
---|---|---|
string | sessionId | Session ID |
string | quoteId | Shopping cart ID (quote ID) |
string | store | Store view code or ID (optional) |
Return:
Type | Description |
---|---|
boolean | Result of removing the amount |
Faults:
Fault Code | Fault Message |
---|---|
100 | Provided data is invalid. |
103 | No quote found with requested id. |
104 | Store credit can not be used for quote created by guest. |
105 | No store found with requested id or code. |
$proxy = new SoapClient('https://inovarti.com.br/index.php/api/soap/?wsdl'); $sessionId = $proxy->login('apiUser', 'apiKey'); $quoteId = 15; $balanceAmountUsedInQuote = $proxy->call($sessionId, 'storecredit_quote.removeAmount', array($quoteId));
$proxy = new SoapClient('https://inovarti.com.br/index.php/api/v2_soap/?wsdl'); // TODO : change url $sessionId = $proxy->login('apiUser', 'apiKey'); // TODO : change login and pwd if necessary $result = $proxy->shoppingCartCustomerbalanceRemoveAmount($sessionId, '15'); var_dump($result);
$proxy = new SoapClient('https://inovarti.com.br/index.php/api/v2_soap/?wsdl'); $sessionId = $proxy->login((object)array('username' => 'apiUser', 'apiKey' => 'apiKey')); $result = $proxy->shoppingCartCustomerbalanceRemoveAmount((object)array('sessionId' => $sessionId->result, 'quoteId' => '15', 'store' => null)); var_dump($result->result);