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

changeMonexAtBnode

An operation changeMonexAtBnode does a money redemption-change at the bank.

The redemption-change can be did in one of three types. Appropriate parameters of the change must also be provided depending on the chosen type.

  • AMOUNT: The money is to be distributed so that an amount given in milibillons can be created.
  • HISTOGRAM: The money is to be distributed so that it corresponds to a given coins distribution. The possible distributions are:
    • DEFAULT_ISSUANCE_CURVE
    • GROSZY_ISSUANCE_CURVE
    • ZLOTY_ISSUANCE_CURVE
    • TENS_ISSUANCE_CURVE
    • HUNDREDS_ISSUANCE_CURVE
  • FACE_VALUE: The money is to be distributed according to a list of coins. The list must consist of a maximum of 21 integers, separated by newlines; each of them corresponds to a number of the coins that you want to get of the given denomination (according to the list of denominations, from the smallest to the largest)

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:changeMonexAtBnode>
   <amountToChange>
    <amount>1000</amount>
    <currency>PLN</currency>
    <colour>0</colour>
   </amountToChange>
   <changeMonexType>HISTOGRAM</changeMonexType>
   <value>HUNDREDS_ISSUANCE_CURVE</value>
  </ns:changeMonexAtBnode>
 </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:changeMonexAtBnodeResponse>
   <return>
    <taskId>0B3LCA6254A12E5GEB0MF4F6LH</taskId>
    <requestStatus>SUCCESS</requestStatus>
    <requestStatusDescription>Request succeeded.</requestStatusDescription>
   </return>
  </ns:changeMonexAtBnodeResponse>
 </SOAP-ENV:Body>
</SOAP-ENV:Envelope>

Request parameters:

ParameterTypeDescriptionRequired?Specification
changeMonexTypestringThe type of coin changeYesOne from among AMOUNT, HISTOGRAM, FACE_VALUE
valuestringThe parameter of change, depended on changeMonexTypeYesSee the description
amountToChangebillonAmountThe amount that is to be distributedYesThe amount must be between 0 and 25 000 miliBillons inclusive

Response parameters:

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

Possible errors:

ErrorDescription
ERR_INVALID_AMOUNTinvalid amount
ERR_INVALID_CURRENCYinvalid currency
ERR_INVALID_MONEY_COLOURinvalid/not supported colour of money
ERR_INVALID_CHANGE_MONEY_PARAMS
ERR_NOT_ENOUGH_MONEYnot enought amount of money
FINISHED_ERRan unknown error occurred
FINISHED_ERR_CANCELLED_DUE_TO_PREVIOUS_ERRORrestart CNode

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?