1. Distribution Module API
API URL
post {HTTP(S)host}/api/{version}/distribution
1.1. Distributor Recharge Interface
1.1.1. SERVICE_TYPE
DISTRIBUTION_RECHARGE_REFUND
1.1.2. Request
| Params | Require | DataType | Sample | Description |
|---|---|---|---|---|
| distributorCustomerName | Y | String | "QY12345" | Distributor user account |
| distributorEnv | Y | String | "DOMESTIC" | Distributor environment DOMESTIC: domestic; CROSSBORDER: overseas |
| type | Y | String | "RECHARGE" | Transaction type: RECHARGE: recharge; REFUND: refund |
| payChannel | N | String | "ALIPAY" | Payment method: ALIPAY: Alipay; BANK_TRANSFER: bank transfer; CASH: cash; WECHAT_PAY: WeChat |
| distributorAccount | N | String | Distributor recharge account | |
| transactionCompleteTime | N | String | "2024-05-20 15:40:30+08:00" | Transaction completion time (recharge/refund time) |
| totalPrice | Y | Decimal | 100 | Transaction amount, positive number |
| supplierAccount | N | String | Our receiving account | |
| remark | N | String | "remark" | Description |
1.1.3. Response
| Params | Require | DataType | Sample | Description |
|---|---|---|---|---|
| errorCode | Y | String | “DATA_INPUT_ERROR” | Error Code |
| errorMsg | Y | String | “The input of Params is incorrect” | Business Error Messages |
| state | Y | String | success | Response State |
Request:
curl --location --request POST 'https://gerp-test1.800best.com/api/v1/distribution' \
--form 'appId="TEST"' \
--form 'serviceType="DISTRIBUTION_RECHARGE_REFUND"' \
--form 'bizParam="{
\"distributorCustomerName\": \"QY123456\",
\"distributorEnv\": \"DOMESTIC\",
\"type\": \"RECHARGE\",
\"payChannel\": \"ALIPAY\",
\"distributorAccount\": \"distributorAccount\",
\"transactionCompleteTime\": \"2026-07-17 10:00:00\",
\"totalPrice\": 10,
\"supplierAccount\": \"supplierAccount\",
\"remark\": \"remark\"
}"' \
--form 'timestamp="1731742317"' \
--form 'sign="39c2cacfe7a6afb55e2cc62ee5a8d738"'
Response:
{
"state": "success",
"errorCode": "",
"errorMsg": "",
"bizContent": "{\"notSuccess\":false,\"state\":\"success\",\"traceId\":\"4c4fede89f504d6b986df52fbd034da0\"}",
"requestId": "cdeac7da-54c8-4939-998e-c8316e82b196"
}