Core API has various optional parameters that can be utilized to integrate with more advanced use cases. This section will explain advance features specific for Partner Solutions, other general features can be seen on this docss docs
Transaction Split
With this feature, as a partner, you can split the gross amount and MDR fee of a transaction to your merchants.
GlossaryIn this context, gross amount is the amount that will be added on your withdrawable balance.
MDR fee is transaction fee that is deducted for each transaction.
You can add transaction_split_settings parameter to define how will you split the transaction.
{
...
"transaction_split_settings": {
"gross_amount_split": {
"type": "percentage",
"split_rules": [
{
"merchant_id": "G000002",
"value": "85"
},
{
"merchant_id": "G000003",
"value": "15"
}
]
},
"fee_split": {
"type": "percentage",
"split_rules": [
{
"merchant_id": "G000002",
"value": "50"
},
{
"merchant_id": "G000003",
"value": "50"
}
]
}
},
...
}| Parameter | Description | Type | Required |
|---|---|---|---|
gross_amount_split | Define the rules for splitting the transaction amount | Object | Optional*required when fee_split is not defined |
gross_amount_split.type | Type of the split, possible values are percentage | String | Required |
gross_amount_split.split_rules | Define the detail of the split | Array of Object | Required |
gross_amount_split.split_rules.*.merchant_id | Merchant ID which will receive amount of the transaction | String | Required |
gross_amount.split_rules.*.value | Value of the split based on type.
| String | Required |
fee_split | Define the rules for splitting the transaction fee | Object | Optional*required when gross_amount_split is not defined |
fee_split.type | Type of the split, possible values are percentage | String | Required |
fee_split.split_rules | Define the detail of the split | Array of Object | Required |
fee_split.split_rules.*.merchant_id | Merchant ID which will bear the transaction fee | String | Required |
fee_split.split_rules.*.value | Value of the split based on type.
| String | Required |
Things to Note
- You can split only the gross amount, only the fee, or both.
- When the
typeispercentage, the total value must be equals to 100%. - Specified
merchant_idmust be registered under your Partner setup.
Sample Calculation
With transaction amount Rp 100.000, transaction fee Rp 4.440, and this split configuration:
{
...
"transaction_split_settings": {
"gross_amount_split": {
"type": "percentage",
"split_rules": [
{
"merchant_id": "G000002",
"value": "85"
},
{
"merchant_id": "G000003",
"value": "15"
}
]
},
"fee_split": {
"type": "percentage",
"split_rules": [
{
"merchant_id": "G000002",
"value": "50"
},
{
"merchant_id": "G000003",
"value": "50"
}
]
}
},
...
}The split result will be:
- Merchant
G000002:- Receive Rp 82.780 (85% * 100.000 - 2.220)
- Bear Rp 2.220 of the fee (50% * 4.440)
- Merchant
G000003:- Receive Rp 12.780 (15% * 100.000 - 2.220)
- Bear Rp 2.220 of the fee (50% * 4.440)