Skip to content

查询可供垫付退款实时余额

若商户想对一笔分账支付单的已经解冻出境部分发起退款,境外机构商可通过该接口获取当前【可垫付退款】额度。

请求参数类型描述
base_uristring声明接入点https://apihk.mch.weixin.qq.com/(香港接入)
php
$instance->v3->global->profitSharing->refunds->refundableBalance->getAsync([
  'base_uri' => 'https://apihk.mch.weixin.qq.com/', // 接入点(香港接入)
])
->then(static function(\Psr\Http\Message\ResponseInterface $response) {
  print_r(json_decode((string) $response->getBody(), true));
})
->wait();
php
$instance->chain('v3/global/profit-sharing/refunds/refundable-balance')->getAsync([
  'base_uri' => 'https://apihk.mch.weixin.qq.com/', // 接入点(香港接入)
])
->then(static function(\Psr\Http\Message\ResponseInterface $response) {
  print_r(json_decode((string) $response->getBody(), true));
})
->wait();
php
$instance['v3/global/profit-sharing/refunds/refundable-balance']->getAsync([
  'base_uri' => 'https://apihk.mch.weixin.qq.com/', // 接入点(香港接入)
])
->then(static function(\Psr\Http\Message\ResponseInterface $response) {
  print_r(json_decode((string) $response->getBody(), true));
})
->wait();
php
$response = $instance->v3->global->profitSharing->refunds->refundableBalance->get([
  'base_uri' => 'https://apihk.mch.weixin.qq.com/', // 接入点(香港接入)
]);
print_r(json_decode((string) $response->getBody(), true));
php
$response = $instance->chain('v3/global/profit-sharing/refunds/refundable-balance')->get([
  'base_uri' => 'https://apihk.mch.weixin.qq.com/', // 接入点(香港接入)
]);
print_r(json_decode((string) $response->getBody(), true));
php
$response = $instance['v3/global/profit-sharing/refunds/refundable-balance']->get([
  'base_uri' => 'https://apihk.mch.weixin.qq.com/', // 接入点(香港接入)
]);
print_r(json_decode((string) $response->getBody(), true));
返回字典类型描述
sponsor_mchidstring出资方商户号
balanceinteger可供垫付分账退款的实时余额
currencystring货币类型

参阅 官方文档

Published on the GitHub by TheNorthMemory