1. Home
  2. Corporate Node
  3. SOAP requests
  4. changeMoney

changeMoney

An operation changeMoney allows to change money of a user whoCanChange (or in the system if blank) so that user can obtain amountToAchieve.

Example SOAP request:

<?xml version="1.0" encoding="UTF-8"?>
<SOAP-ENV:Envelope
  xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/"
  xmlns:SOAP-ENC="http://schemas.xmlsoap.org/soap/encoding/"
  xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
  xmlns:xsd="http://www.w3.org/2001/XMLSchema"
  xmlns:ns="ns1">
 <SOAP-ENV:Body  SOAP-ENV:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/">
  <ns:changeMoney>
   <amountToAchieve>
    <amount>1000</amount>
    <currency>PLN</currency>
    <colour>0</colour>
   </amountToAchieve>
   <whoCanChange>username</whoCanChange>
  </ns:changeMoney>
 </SOAP-ENV:Body>
</SOAP-ENV:Envelope>

Example SOAP response:

<?xml version="1.0" encoding="UTF-8"?>
<SOAP-ENV:Envelope
  xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/"
  xmlns:SOAP-ENC="http://schemas.xmlsoap.org/soap/encoding/"
  xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
  xmlns:xsd="http://www.w3.org/2001/XMLSchema"
  xmlns:ns="ns1">
 <SOAP-ENV:Body  SOAP-ENV:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/">
  <ns:changeMoneyResponse>
   <return>
    <taskId>0B3LCA6254A12E5GEB0MF4F6LH</taskId>
    <requestStatus>SUCCESS</requestStatus>
    <requestStatusDescription>Request succeeded.</requestStatusDescription>
   </return>
  </ns:changeMoneyResponse>
 </SOAP-ENV:Body>
</SOAP-ENV:Envelope>

Request parameters:

ParameterTypeDescriptionRequired?Specification
amountToChangebillonAmountAn amount that is to be distributedYesThe amount must be greater than zero
whoCanChangestringAn user for whom the coin change is to be doneNoit must be a valid username

Reponse parameters:

NameTypeDescription
taskIdstringthe identifier of the crated task
requestStatusDescriptionstringa description of a status
requestStatusstringresult of request

Possible errors:

ErrorDescription
ERR_INVALID_AMOUNTinvalid amount
ERR_INVALID_CURRENCYinvalid currency
ERR_INVALID_MONEY_COLOURinvalid/unsupported colour of money
ERR_INVALID_USERNAMEinvalid username

An example of JSON in a parameter ‘additionalInfo’ in the response of the operation ‘getTaskStatus’:

{
   "amount": 5000,
   "actual_amount": 0,
   "restart_amount": 0
}
Was this article helpful to you? Yes No

How can we help?