Documentation/API Reference

API REFERENCE

Query a payment split

POSThttps://mapi.yabandpay.com/Payments
Live API
API PLAYGROUND · Live API

Query a payment split

POSThttps://mapi.yabandpay.com/Payments
Automatically signed with your credentials

Request parameters7

Required fields first

Query a payment split

commandRequiredstringdata.commandquerySplitPayment
nonce_stringRequiredstringdata.nonce_stringRandom string, no longer than 32 characters
reference_idRequiredstringdata.reference_idMerchant's payment split ID, no longer than 32 characters
split_idRequiredstringdata.split_idPayment split order number generated when the payment split is created
Optional parameters 3
split_typeOptionalstringdata.split_typePayment split type: 0: Split (payment split), 1: Return (payment split return). Only these 2 types are supported. If omitted, all payment splits and return information for split_id are queried.
split_detail_idOptionalstringdata.split_detail_idDetail of the payment split order generated when the payment split is created; can be used with split_type to query the corresponding payment split order details
refund_split_detail_idOptionalstringdata.refund_split_detail_idOnly effective when split_type indicates a payment split return; queries the corresponding payment split return order details

Credentials stay on this page. Your secret key is never stored or sent to the documentation server.

This API queries existing YabandPay payment split orders and payment split return orders.

ParameterTypeDescriptionRequired
userStringUID of the super administrator accountRequired
signStringSignatureRequired
methodStringv3.SplitPaymentRequired
timeLongTimestampRequired
  • Parameters
ParameterTypeDescriptionRequired
commandStringquerySplitPaymentRequired
nonce_stringStringRandom string, no longer than 32 charactersRequired
reference_idStringMerchant's payment split ID, no longer than 32 charactersRequired
split_idStringPayment split order number generated when the payment split is createdRequired
split_typeStringPayment split type: 0: Split (payment split), 1: Return (payment split return). Only these 2 types are supported. If omitted, all payment splits and return information for split_id are queried.Optional
split_detail_idStringDetail of the payment split order generated when the payment split is created; can be used with split_type to query the corresponding payment split order detailsOptional
refund_split_detail_idStringOnly effective when split_type indicates a payment split return; queries the corresponding payment split return order detailsOptional

Signature example:

Sorted parameters concatenated into a URL-style query string

"command=querySplitPayment&method=v3.SplitPayment&nonce_string=7vccb9qkplvtxl22km&reference_id=123456&split_id=20231229110618372777&time=1703836221&trade_id=67943b0b-ca6b-aa96-5fb1-e354975f1ec4&user=9212776037"

Sign stringA using secret_key

The resulting signature is:

"YOUR_SIGNATURE"

Request example:

{
    "user": "9212776037",
    "sign": "YOUR_SIGNATURE",
    "method": "v3.SplitPayment",
    "time": 1703836221,
    "data": {
        "command": "querySplitPayment",
        "nonce_string": "7vccb9qkplvtxl22km",
        "split_id": "20231229110618372777",
        "reference_id": "123456"
    }
}

Response example:

{
    "status": true,
    "code": "200",
    "data": {
        "split_id": "20231229110618372777",
        "state": "Success",
        "merchant_mid": "123",
        "merchant_name": "123",
        "reference_id": "123456",
        "reference": "5464654561",
        "split_solution_id": "104",
        "created_at": "1703819178",
        "notify_url": null,
        "currency": "EUR",
        "receivers": [
            {
                "merchant_mid": "222",
                "merchant_name": "222",
                "detail_reference_id": "123456-1",
                "split_detail_id": "20231229110618372777-2",
                "refund_split_detail_id": "20231229110618372777-2-1",
                "split_type": "Return",
                "split_amount": "1.00",
                "role": "1",
                "result": "Success",
                "description": "分账回退描述2",
                "error_msg": null
            },
            {
                "merchant_mid": "111",
                "merchant_name": "111",
                "detail_reference_id": "123456-1",
                "split_detail_id": "20231229110618372777-1",
                "refund_split_detail_id": "20231229110618372777-1-1",
                "split_type": "Return",
                "split_amount": "2.00",
                 "role": "2",
                "result": "Success",
                "description": "分账回退描述1",
                "error_msg": null
            },
            {
                "merchant_mid": "222",
                "merchant_name": "222",
                "detail_reference_id": "123456-2",
                "split_detail_id": "20231229110618372777-2",
                "refund_split_detail_id": "",
                "split_type": "Split",
                "split_amount": "5.00",
                "role": "1",
                "result": "Success",
                "description": "分账描述2",
                "error_msg": null
            },
            {
                "merchant_mid": "111",
                "merchant_name": "111",
                "detail_reference_id": "123456-1",
                "split_detail_id": "20231229110618372777-1",
                "refund_split_detail_id": "",
                "split_type": "Split",
                "split_amount": "10.00",
                "role": "2",
                "result": "Success",
                "description": "分账描述1",
                "error_msg": null
            }
        ],
        "split_completed": 1
    },
    "message": ""
}
  • Response parameters
ParameterTypeDescription
userStringUID of the cashier account
split_idStringPayment split order number generated when the payment split is created
trade_idStringtrade_id of the YabandPay order
split_solution_idStringPayment split solution ID
stateStringStatus: Processing, Success, Failed, Cancelled
merchant_midStringmid of the merchant splitting the payment
merchant_nameStringName of the merchant splitting the payment
created_atStringCreation timestamp
currencyStringOrder settlement currency, Settlement Currency
notify_urlStringAsynchronous notification URL
split_completedStringWhether the payment split is complete: 0: No, 1: Yes
reference_idStringMerchant's payment split ID, no longer than 32 characters
referenceStringDescription, no longer than 128 characters
receiversStringPayment split recipient information in JSON format
receivers.merchant_midStringmid of the payment split recipient
receivers.merchant_nameStringMerchant name of the payment split recipient
receivers.split_detail_idStringPayment split detail number generated when the payment split is created
receivers.detail_reference_idStringMerchant's payment split detail number
receivers.split_typeStringPayment split type: Split or Return
receivers.split_amountStringPayment split amount
receivers.roleStringPayment split recipient role
receivers.resultStringStatus: Processing, Success, Failed, Cancelled
receivers.descriptionStringPayment split detail description
receivers.error_msgStringError message for the payment split detail; populated when result is Failed