Split Payments and Commission

Overview

MoneyHash split payments let you divide a single payment across multiple sub-merchants in one request, and optionally apply a commission to each sub-merchant's share. This is built for marketplaces, platforms, and aggregators that collect one payment from a customer but settle it to several parties.

Splitting happens at intent creation - you add a split_data array to a standard payment intent. No separate call, no post-payment transfers to orchestrate.

What you can do

  • Split one customer payment across multiple sub-merchants in a single intent
  • Define each sub-merchant's exact share of the total
  • Apply an optional commission per sub-merchant - fixed, percentage-based, or both
  • Mix sub-merchants with and without commission in the same request
  • Receive the outcome on your existing webhook, like any other payment

How it works


The customer makes one payment for the full amount. MoneyHash divides it according to split_data, applies each sub-merchant's commission (if any), and routes the shares accordingly.


Creating a split payment

POST /api/v1.4/payments/intent/

Split payments use the standard create-intent endpoint with a split_data array added. The non-split fields below behave exactly as they do for any intent - see Create a Payment for their full definitions.

FieldTypeDescription
amountnumberTotal amount the customer is charged
amount_currencystringCurrency of the payment (e.g. usd)
payment_methodstringPayment method for the intent (e.g. CARD)
operationstringOperation type (e.g. purchase)
webhook_urlstringOptional. URL to receive the payment webhook
split_dataarrayThe split definition - one object per sub-merchant (see below)
Split amounts must add up to the total

The sum of every amount inside split_data should equal the top-level amount. In the example below, 30 + 10 + 10 = 50.


The split_data array

Each object in split_data represents one sub-merchant's share of the payment.

FieldTypeRequiredDescription
sub_merchant_idstringYesIdentifier of the sub-merchant receiving this share
amountnumberYesThis sub-merchant's portion of the total
commission_typestringNoFIXED, VARIABLE, or COMPOUND (see below). Omit for no commission
commission_amountnumberConditionalRequired when commission_type is FIXED or COMPOUND
commission_percentagenumberConditionalRequired when commission_type is VARIABLE or COMPOUND
Commission is optional

A sub-merchant with no commission only needs sub_merchant_id and amount. Omit commission_type and the commission fields entirely for that entry.


Commission types

commission_typeUsesBehavior
FIXEDcommission_amountA flat commission of the given amount
VARIABLEcommission_percentageA commission calculated as a percentage of the share
COMPOUNDcommission_amount and commission_percentageBoth a flat amount and a percentage, combined

Example request

{
  "amount": 50,
  "amount_currency": "usd",
  "payment_method": "CARD",
  "operation": "purchase",
  "webhook_url": "https://webhook.site/b8954509-f628-4805-a4b4-58a0fb2be958",
  "split_data": [
    {
      "sub_merchant_id": "122",
      "amount": 30,
      "commission_type": "FIXED",
      "commission_amount": 2
    },
    {
      "sub_merchant_id": "123",
      "amount": 10,
      "commission_type": "VARIABLE",
      "commission_percentage": 1
    },
    {
      "sub_merchant_id": "124",
      "amount": 10,
      "commission_type": "COMPOUND",
      "commission_amount": 1,
      "commission_percentage": 1
    }
  ]
}

The response returns a standard payment intent. The customer then completes the payment as they would for any intent, and the split is applied to the settled funds.

Base URL & Authentication

Prepend your environment base URL and authenticate every request as described in Authentication. The examples use a placeholder Authorization header - use the scheme from the Authentication page.


Did this page help you?