WebMoney

Wiki

Interface X2

Interface X2. Transferring funds from one purse to another.

This interface is available for registered members only and can be used for making transfers from purses of any WM Keeper, including Budget Automates.

The option can be enabled at the Web Merchant Interface service settings page in the "additional parameters" section. Enabling this option you undertake to use the "trans\onlyauth = 1" parameter. The Keeper that signs requests should have Personal passport.

<w3s.request>
    <reqn></reqn>
    <wmid></wmid>
    <sign></sign>
    <trans>
        <tranid></tranid>
        <pursesrc></pursesrc>
        <pursedest></pursedest>
        <amount></amount>
        <period></period>
        <pcode></pcode>
        <desc></desc>
        <wminvid></wminvid>
        <onlyauth></onlyauth>
    </trans>
<wmb_denomination>1</wmb_denomination> 
</w3s.request>
  • Request parameters
Name Purpose Description
reqn Request number a positive integer of 15 digits maximally; must be greater than a previous payment request number!!! Each WMID that signs the request is linked to its` unique sequence of monotonically increasing values of this parameter.
wmid Signer's WMID Is used only with the WM Keeper WinPro authorization method;
sign Request signature Contains the following parameters: reqn+tranid+pursesrc+pursedest+amount+period+pcode+desc+wminvid. Is used only with the WM Keeper WinPro (Classic) authorization method;
trans Transaction parameters  
trans\tranid Transaction number transaction number in the sender's accounting system; any positive integer; must be unique for the WMID that signs the request. It's not allowed to perform two transactions with the same 'tranid' from one WMID (from different purses of a WMID either). The uniqueness of tranid value is verified for the period not shorter than one year.
trans\pursesrc Sender’s WM purse number  
trans\pursedest Recipient’s purse number  
trans\amount Amount of the sum transferred A floating-point number, separated by a . (decimal point). Ten and a half, for example, is 10.5. Redundant zeros at the end, or decimal points if the number is a whole number, should not be used: 10.50 – invalid, 10.5 – valid, 9. – invalid, 9 – valid);
trans\period Protection period Maximum protection period allowed in days; An integer in the range 0 - 120; 0 - means that no protection will be used;
trans\pcode Protected payment Arbitrary string of 5 to 255 characters. No spaces may be used at the beginning or the end;
trans\desc Description of the purchased product or service Arbitrary string of 0 to 255 characters. No spaces may be used at the beginning or the end;
trans\wminvid Invoice number (in the WebMoney system) An integer > 0; 0 means that the transfer is made without an invoice. Maximum is 2 32 -1;
trans\onlyauth Consider recipient authorization obligatorily! 1 – the transfer will be made only if the recipient allows the transfer (otherwise the returned code will be - 35). The recepient can prohibit accepting payments in two cases. The first is when the sender is an authorized correspondent for the recepient for whom the latter had prohibited the possibility of making payments to his purses ('restrictions' section in the correspondent's properties). The second is when the sender isn't an authorized correspondent for the recepient, and the latter had prohibited the possibility of making payments to his purses for all unauthorized members.
wmb_denomination the denomination flag obligatorily! 1 – the transfer will be made only if the sender transmits the parameter

Important! trans\Amount (the sum being transferred) value may not be lower than the values specified in the table below:

Type Minimal allowed amount
WMZ 0.01
WME 0.01
WMR 0.01
WMU 0.01
WMB 0.01
WMG 0.01
WMX 0.01
  • Response format
<w3s.response>
    <reqn></reqn>
    <retval></retval>
    <retdesc>0</retdesc>
        <operation id="n1" ts="n2">
            <tranid></tranid>
            <pursesrc></pursesrc>
            <pursedest></pursedest>
            <amount></amount>
            <comiss></comiss>
            <opertype></opertype>
            <period></period>
            <wminvid></wminvid>
            <orderid></orderid>
            <desc></desc>
            <datecrt></dateupd>
            <dateupd></dateupd>
        </operation>
</w3s.response>
  • Response parameters
Name Purpose Description
reqn Request number  
retval Execution code "0" means that the request was executed successfully. Check the execution code table for detailed information;
retdesc Execution code description  
operation Transaction parameters id defines a unique invoice number in the WebMoney system;
the ts attribute is an internal number for the invoice within the WebMoney system;
operation\tranid Transaction number Transaction number set in the sender’s accounting system; an integer; it should be unique for each transaction (the same tranid may not be used for two transactions);
operation\pursesrc Sender’s WM purse number  
operation\pursedest Recipient’s WM purse number  
operation\amount Amount transferred A floating-point number, separated by a . (decimal point). Ten and a half, for example, is 10.5. Redundant zeros at the end, or decimal points if the number is a whole number, should not be used: 10.50 – invalid, 10.5 – valid, 9. – invalid, 9 – valid);
operation\comiss Fee charged A floating-point number, separated by a . (decimal point). Ten and a half, for example, is 10.5. Redundant zeros at the end, or decimal points if the number is a whole number, should not be used: 10.50 – invalid, 10.5 – valid, 9. – invalid, 9 – valid);
operation\opertype Transfer type 0 – simple; 4 – code-protected;
operation\period Protection period An integer in the range 0 - 255; zero means that protection is disabled;
operation\wminvid Invoice number (in the WebMoney system) An integer > 0; 0 means that transfer is made without an invoice;
operation\orderid Merchant's invoice number An integer > 0; 0 means that the transfer is made without an invoice;
operation\desc Description of the purchased product or service  
operation\datecrt Date and time of the transaction  
operation\dateupd Date and time of the latest transaction status change  
  • Execution/Error Codes
Code Description
-100 General parsing error. Incorrect request format.
-110 Requests are sent from a different IP address than the one specified during the registration of the interface with technical support
-1 Invalid value for w3s.request/reqn
-2 Invalid value for w3s.request/sign
-3 Invalid value for w3s.request/trans/tranid
-4 Invalid value for w3s.request/trans/pursesrc
-5 Invalid value for w3s.request/trans/pursedest
-6 Invalid value for w3s.request/trans/amount
-7 Invalid value for w3s.request/trans/desc
-8 Field for w3s.request/trans/pcode is too long
-9 Field w3s.request/trans/pcode should not be empty if w3s.request/trans/period > 0
-10 Field w3s.request/trans/pcode should be empty if w3s.request/trans/period = 0
-11 Invalid value for w3s.request/trans/wminvid
-12 Identifier sent for w3s.request/wmid is not registered
-14 Signature verification failed
-15 Invalid value for w3s.request/wmid
-17 the denomination flag hasn't been transmitted
102 The requirement for constant increase in the w3s.request/reqn parameter has not been met
103 A transaction with the submitted value for w3s.request/trans/tranid has already been executed
110 No access to interface
111 Attempt to transfer funds from a WM purse which does not belong to the WMID used to sign the request; Security trust has not been established.
4, 15, 19, 23 Internal error when creating transaction
5 Sender’s WMID not found
6 Correspondent not found
7 Recipient’s WM purse not found
11 Sender’s WM purse not found
13 Transaction amount should be >0
17 Insufficient amount of funds in the purse
21 The invoice for this transaction was not found
22 Code-protected transfer for this invoice is not available
25 The invoice validity period has expired
26 Different purses should be used for this operation
29 The types of purses are different
30 Purse doesn’t support direct transfers
34 Payer must inform their personal information on the web-site WebMoney Passport
35 Payer is not authorized by the correspondent to execute this operation
58 Funds limit for the recipient’s purses has been exceeded
72 Servicing of WME withdrawals temporarily suspended. Please read the WME guarantor identification rules
73 Service to the WME funds recipient has been temporarily suspended. Please read the WME guarantor identification rules
74 Service to the WME funds recipient has been temporarily suspended. Please read the WME guarantor identification rules
75 The protection code must be at least five characters long