Skip to main content

Documentation

Creating a Split Payment

Learn how to pay multiple wallets from a single payment method. You can divide the funds among the wallets either by amount or by percentage.

For example, you might pay the price of an item to one wallet and the tax to another wallet. Or you might pay the cost of an item to one wallet and an additional percentage to an agent's wallet.

Prerequisites

Procedure

Create a payment. For each wallet in the wallets array, specify an amount or percentage. See Create Payment.

Note

  • You must choose amount for all wallets or percentage for all wallets. You cannot mix these options.

  • If the total amount of the payment is not fully accounted for, the balance appears in the client wallet.

{
//         . . .

    "ewallets": [
        {
            "ewallet": "ewallet_c67c44ec60d5c2e62480aa7c76b3f8b4",
            "amount": 200
        }, 
        {
            "ewallet": "ewallet_3cd928611934717f283df049a2c7c17e",
            "amount": 50
        }
    ]
}

The response shows how the funds are distributed.

Code Examples

For full code examples, see Create Payment:

  • Payment split by amount

  • Payment split by percentage