Skip to content

取消补差

对带有补差标识的订单,如果不需要补差,可在发起发起分账前,可调用这个接口进行取消补差。

请求参数类型描述
jsonobject声明请求的JSON数据结构
sub_mchidstring二级商户号
transaction_idstring微信订单号
descriptionstring取消补差描述
php
$instance->v3->ecommerce->subsidies->cancel->postAsync([
  'json' => [
    'sub_mchid'      => '1900000109',
    'transaction_id' => '4208450740201411110007820472',
    'description'    => '订单退款',
  ],
])
->then(static function(\Psr\Http\Message\ResponseInterface $response) {
  print_r(json_decode((string) $response->getBody(), true));
})
->wait();
php
$instance->chain('v3/ecommerce/subsidies/cancel')->postAsync([
  'json' => [
    'sub_mchid'      => '1900000109',
    'transaction_id' => '4208450740201411110007820472',
    'description'    => '订单退款',
  ],
])
->then(static function(\Psr\Http\Message\ResponseInterface $response) {
  print_r(json_decode((string) $response->getBody(), true));
})
->wait();
php
$instance['v3/ecommerce/subsidies/cancel']->postAsync([
  'json' => [
    'sub_mchid'      => '1900000109',
    'transaction_id' => '4208450740201411110007820472',
    'description'    => '订单退款',
  ],
])
->then(static function(\Psr\Http\Message\ResponseInterface $response) {
  print_r(json_decode((string) $response->getBody(), true));
})
->wait();
php
$response = $instance->v3->ecommerce->subsidies->cancel->post([
  'json' => [
    'sub_mchid'      => '1900000109',
    'transaction_id' => '4208450740201411110007820472',
    'description'    => '订单退款',
  ],
]);
print_r(json_decode((string) $response->getBody(), true));
php
$response = $instance->chain('v3/ecommerce/subsidies/cancel')->post([
  'json' => [
    'sub_mchid'      => '1900000109',
    'transaction_id' => '4208450740201411110007820472',
    'description'    => '订单退款',
  ],
]);
print_r(json_decode((string) $response->getBody(), true));
php
$response = $instance['v3/ecommerce/subsidies/cancel']->post([
  'json' => [
    'sub_mchid'      => '1900000109',
    'transaction_id' => '4208450740201411110007820472',
    'description'    => '订单退款',
  ],
]);
print_r(json_decode((string) $response->getBody(), true));
返回字典类型描述
sub_mchidstring二级商户号
transaction_idstring微信订单号
resultstring取消补差结果
descriptionstring取消补差描述

参阅 官方文档

Published on the GitHub by TheNorthMemory