Remaining Refundable Amount Query
Update Time:2025.03.03If a merchant initiates funds-distribution several times for a funds-distribution payment order, this API can be used to query the remaining refundable amount of this order.
|
1. API Instructions
Applicable to:Common mode Institutional mode
Request URL: https://apihk.mch.weixin.qq.com/v3/global/profit-sharing/transactions/{transaction_id}/refundable-amounts
Request method:GET
Path parameter is a path parameter.
Query parameter needs to be passed in the request URL.
Body parameter needs to be passed in the request JSON.
2. Request Parameters
Name | Variable Name | Type | Required | Description |
---|---|---|---|---|
Sub-Merchant ID | sub_mchid | string[1, 32] | No | Query indicates the merchant ID assigned by WeChat Pay, which should be consistent with the Sub-Merchant ID of the WeChat Pay order. (Not required for directly linked merchants, required for service providers/institutions) |
WeChat Pay Order Number | transaction_id | string[1, 32] | Yes | Path indicates WeChat Pay order number |
Request Example:
URL
3. Return Parameters
Name | Variable Name | Type | Required | Description |
---|---|---|---|---|
WeChat Pay Order Number | transaction_id | string[1, 32] | Yes | WeChat Pay order number Example: 4208450740201411110007820472 |
Remaining Refundable Order Amount | refundable_amount | int | Yes | The order amount frozen in the merchant account for refund, which can only be an integer in the smallest unit of currency (currently in CNY Fen). Note: Using frozen order amount as refund will decrease its remaining distributable amount. Example: 1000 |
Currency Type | currency | string[1, 10] | Yes | Only the Chinese yuan "CNY" is supported. Example: CNY |
The amount of the remaining advance refund available for an order | funds_refundable_amount | int | No | The amount of the remaining Advance Refund quota available for an order(CNY, in Fen). Note: Initiating advance refund for an order will decrease its remaining available advance refund amount. Example:100 |
Response Example:
SUCCESS
4. Error Codes
Error Codes | Error Message | Description | Solution |
---|---|---|---|
400 | INVALID_REQUEST | This order does not support ledger splitting | Please check if the WeChat payment order number is filled in incorrectly and confirm that the call to the order API has been successful before executing call to the accounting mark API |
403 | NO_AUTH | The merchant has not signed up for the overseas funds-distribution function. | See the product process and preparation before access, and check that the merchant has funds-distribution permission before initiating a request. |
403 | NO_AUTH | The merchant has enabled the funds-distribution function and is waiting for it to take effect. (In most cases, the function will take effect only on the next day.) | You cannot initiate a funds-distribution on the day that you enable the function. Initiate the request on the next day. |
403 | NO_AUTH | The merchant parent-child relationship does not exist. Initiate the request with the correct Sub-Merchant ID. | Check if the Sub-Merchant ID (sub_mchid) is correct. |
400 | INVALID_REQUEST | The merchant information is inconsistent with the order merchant information. | Check if the Sub-Merchant ID (sub_mchid) or WeChat Pay Order Number (transaction_id) is correct. |
500 | SYSYTEM_ERROR | The WeChat Pay order fund freezing process specified by the merchant's funds-distribution initiation request has not been completed. Try again later. | The fund freezing process for the funds-distribution payment order will be triggered once the user's payment is completed. It is recommended that the merchant try it after 3 to 5 min. | |