Skip to content

报关重推

如果订单附加信息已请求报送海关,但电子口岸丢单,则可以使用报关重推接口重新向海关推送(订单附加信息的state必须为SUCCESS或者EXCEPT)。

请求参数类型描述
base_uristring声明接入点https://apihk.mch.weixin.qq.com/global/(香港接入)
jsonobject声明请求的JSON数据结构
appidstring机构APPID
mchidstring商户号
out_trade_nostring商户订单号
transaction_idstring微信订单号
sub_order_nostring商户子单号
sub_order_idstring微信子单号
customsstring海关编码
merchant_customs_nostring商户海关备案号
php
$instance->v3->customs->redeclare->postAsync([
  'base_uri' => 'https://apihk.mch.weixin.qq.com/global/', // 接入点(香港接入)
  'json' => [
    'appid' => 'wxd678efh567hg6787',
    'mchid' => '1230000109',
    'out_trade_no' => '20150806125346',
    'transaction_id' => '1000320306201511078440737890',
    'sub_order_no' => '20150806125346',
    'sub_order_id' => '1000320306201511078440737891',
    'customs' => 'SHANGHAI_ZS',
    'merchant_customs_no' => '123456',
  ],
])
->then(static function(\Psr\Http\Message\ResponseInterface $response) {
  print_r(json_decode((string) $response->getBody(), true));
})
->wait();
php
$instance->chain('v3/customs/redeclare')->postAsync([
  'base_uri' => 'https://apihk.mch.weixin.qq.com/global/', // 接入点(香港接入)
  'json' => [
    'appid' => 'wxd678efh567hg6787',
    'mchid' => '1230000109',
    'out_trade_no' => '20150806125346',
    'transaction_id' => '1000320306201511078440737890',
    'sub_order_no' => '20150806125346',
    'sub_order_id' => '1000320306201511078440737891',
    'customs' => 'SHANGHAI_ZS',
    'merchant_customs_no' => '123456',
  ],
])
->then(static function(\Psr\Http\Message\ResponseInterface $response) {
  print_r(json_decode((string) $response->getBody(), true));
})
->wait();
php
$instance['v3/customs/redeclare']->postAsync([
  'base_uri' => 'https://apihk.mch.weixin.qq.com/global/', // 接入点(香港接入)
  'json' => [
    'appid' => 'wxd678efh567hg6787',
    'mchid' => '1230000109',
    'out_trade_no' => '20150806125346',
    'transaction_id' => '1000320306201511078440737890',
    'sub_order_no' => '20150806125346',
    'sub_order_id' => '1000320306201511078440737891',
    'customs' => 'SHANGHAI_ZS',
    'merchant_customs_no' => '123456',
  ],
])
->then(static function(\Psr\Http\Message\ResponseInterface $response) {
  print_r(json_decode((string) $response->getBody(), true));
})
->wait();
php
$response = $instance->v3->customs->redeclare->post([
  'base_uri' => 'https://apihk.mch.weixin.qq.com/global/', // 接入点(香港接入)
  'json' => [
    'appid' => 'wxd678efh567hg6787',
    'mchid' => '1230000109',
    'out_trade_no' => '20150806125346',
    'transaction_id' => '1000320306201511078440737890',
    'sub_order_no' => '20150806125346',
    'sub_order_id' => '1000320306201511078440737891',
    'customs' => 'SHANGHAI_ZS',
    'merchant_customs_no' => '123456',
  ],
]);
print_r(json_decode((string) $response->getBody(), true));
php
$response = $instance->chain('v3/customs/redeclare')->post([
  'base_uri' => 'https://apihk.mch.weixin.qq.com/global/', // 接入点(香港接入)
  'json' => [
    'appid' => 'wxd678efh567hg6787',
    'mchid' => '1230000109',
    'out_trade_no' => '20150806125346',
    'transaction_id' => '1000320306201511078440737890',
    'sub_order_no' => '20150806125346',
    'sub_order_id' => '1000320306201511078440737891',
    'customs' => 'SHANGHAI_ZS',
    'merchant_customs_no' => '123456',
  ],
]);
print_r(json_decode((string) $response->getBody(), true));
php
$response = $instance['v3/customs/redeclare']->post([
  'base_uri' => 'https://apihk.mch.weixin.qq.com/global/', // 接入点(香港接入)
  'json' => [
    'appid' => 'wxd678efh567hg6787',
    'mchid' => '1230000109',
    'out_trade_no' => '20150806125346',
    'transaction_id' => '1000320306201511078440737890',
    'sub_order_no' => '20150806125346',
    'sub_order_id' => '1000320306201511078440737891',
    'customs' => 'SHANGHAI_ZS',
    'merchant_customs_no' => '123456',
  ],
]);
print_r(json_decode((string) $response->getBody(), true));
返回字典类型描述
appidstring机构APPID
mchidstring商户号
statestring报关状态
out_trade_nostring商户订单号
transaction_idstring微信订单号
sub_order_nostring商户子订单号
sub_order_idstring微信子订单号
modify_timestring最后更新时间
explanationstring申报结果说明

参阅 官方文档

Published on the GitHub by TheNorthMemory