冲红电子发票
商户对已开具的电子发票进行冲红(开具红票),并将其从微信用户的卡包中删除。
请求参数 | 类型 | 描述 |
---|---|---|
fapiao_apply_id | string | 发票申请单号 |
json | object | 声明请求的JSON 数据结构 |
sub_mchid | string | 子商户号 |
reverse_reason | string | 冲红原因 |
fapiao_information | object[] | 需要冲红的发票信息 |
fapiao_id | string | 商户发票单号 |
fapiao_code | string | 发票代码 |
fapiao_number | string | 发票号码 |
php
$instance->v3->newTaxControlFapiao->fapiaoApplications->_fapiao_apply_id_->reverse->postAsync([
'fapiao_apply_id' => '4200000444201910177461284488',
'json' => [
'sub_mchid' => '1900000109',
'reverse_reason' => '退款',
'fapiao_information' => [[
'fapiao_id' => '20200701123456',
'fapiao_code' => '044001911211',
'fapiao_number' => '12897794',
],],
],
])
->then(static function(\Psr\Http\Message\ResponseInterface $response) {
print_r($response->getStatusCode() === 202);
})
->wait();
php
$instance->chain('v3/new-tax-control-fapiao/fapiao-applications/{fapiao_apply_id}/reverse')->postAsync([
'fapiao_apply_id' => '4200000444201910177461284488',
'json' => [
'sub_mchid' => '1900000109',
'reverse_reason' => '退款',
'fapiao_information' => [[
'fapiao_id' => '20200701123456',
'fapiao_code' => '044001911211',
'fapiao_number' => '12897794',
],],
],
])
->then(static function(\Psr\Http\Message\ResponseInterface $response) {
print_r($response->getStatusCode() === 202);
})
->wait();
php
$instance['v3/new-tax-control-fapiao/fapiao-applications/{fapiao_apply_id}/reverse']->postAsync([
'fapiao_apply_id' => '4200000444201910177461284488',
'json' => [
'sub_mchid' => '1900000109',
'reverse_reason' => '退款',
'fapiao_information' => [[
'fapiao_id' => '20200701123456',
'fapiao_code' => '044001911211',
'fapiao_number' => '12897794',
],],
],
])
->then(static function(\Psr\Http\Message\ResponseInterface $response) {
print_r($response->getStatusCode() === 202);
})
->wait();
php
$response = $instance->v3->newTaxControlFapiao->fapiaoApplications->_fapiao_apply_id_->reverse->post([
'fapiao_apply_id' => '4200000444201910177461284488',
'json' => [
'sub_mchid' => '1900000109',
'reverse_reason' => '退款',
'fapiao_information' => [[
'fapiao_id' => '20200701123456',
'fapiao_code' => '044001911211',
'fapiao_number' => '12897794',
],],
],
]);
print_r($response->getStatusCode() === 202);
php
$response = $instance->chain('v3/new-tax-control-fapiao/fapiao-applications/{fapiao_apply_id}/reverse')->post([
'fapiao_apply_id' => '4200000444201910177461284488',
'json' => [
'sub_mchid' => '1900000109',
'reverse_reason' => '退款',
'fapiao_information' => [[
'fapiao_id' => '20200701123456',
'fapiao_code' => '044001911211',
'fapiao_number' => '12897794',
],],
],
]);
print_r($response->getStatusCode() === 202);
php
$response = $instance['v3/new-tax-control-fapiao/fapiao-applications/{fapiao_apply_id}/reverse']->post([
'fapiao_apply_id' => '4200000444201910177461284488',
'json' => [
'sub_mchid' => '1900000109',
'reverse_reason' => '退款',
'fapiao_information' => [[
'fapiao_id' => '20200701123456',
'fapiao_code' => '044001911211',
'fapiao_number' => '12897794',
],],
],
]);
print_r($response->getStatusCode() === 202);
返回字典 | 类型 | 描述 |
---|
参阅 官方文档