请求及查询售后服务分账结果
请求售后服务分账
请求参数 | 类型 | 描述 |
---|---|---|
json | object | 声明请求的JSON 数据结构 |
sub_mchid | string | 二级商户号 |
transaction_id | string | 微信订单号 |
amount | integer | 回退金额 |
type | string | 类型SERVICE_FEE_INCOME 枚举值 |
scene | string | 场景REFUND_TICKET | CHANGE_TICKET | RETURN_GOODS 枚举值之一 |
refund_id | string | 微信退款单号 |
php
$instance->v3->ecommerce->profitsharing->afterSalesOrders->postAsync([
'json' => [
'sub_mchid' => '1900000109',
'transaction_id' => '3008450740201411110007820472',
'amount' => 10,
'type' => 'SERVICE_FEE_INCOME',
'scene' => 'REFUND_TICKET',
'refund_id' => '',
],
])
->then(static function(\Psr\Http\Message\ResponseInterface $response) {
print_r(json_decode((string) $response->getBody(), true));
})
->wait();
php
$instance->chain('v3/ecommerce/profitsharing/after-sales-orders')->postAsync([
'json' => [
'sub_mchid' => '1900000109',
'transaction_id' => '3008450740201411110007820472',
'amount' => 10,
'type' => 'SERVICE_FEE_INCOME',
'scene' => 'REFUND_TICKET',
'refund_id' => '',
],
])
->then(static function(\Psr\Http\Message\ResponseInterface $response) {
print_r(json_decode((string) $response->getBody(), true));
})
->wait();
php
$instance['v3/ecommerce/profitsharing/after-sales-orders']->postAsync([
'json' => [
'sub_mchid' => '1900000109',
'transaction_id' => '3008450740201411110007820472',
'amount' => 10,
'type' => 'SERVICE_FEE_INCOME',
'scene' => 'REFUND_TICKET',
'refund_id' => '',
],
])
->then(static function(\Psr\Http\Message\ResponseInterface $response) {
print_r(json_decode((string) $response->getBody(), true));
})
->wait();
php
$response = $instance->v3->ecommerce->profitsharing->afterSalesOrders->post([
'json' => [
'sub_mchid' => '1900000109',
'transaction_id' => '3008450740201411110007820472',
'amount' => 10,
'type' => 'SERVICE_FEE_INCOME',
'scene' => 'REFUND_TICKET',
'refund_id' => '',
],
]);
print_r(json_decode((string) $response->getBody(), true));
php
$response = $instance->chain('v3/ecommerce/profitsharing/after-sales-orders')->post([
'json' => [
'sub_mchid' => '1900000109',
'transaction_id' => '3008450740201411110007820472',
'amount' => 10,
'type' => 'SERVICE_FEE_INCOME',
'scene' => 'REFUND_TICKET',
'refund_id' => '',
],
]);
print_r(json_decode((string) $response->getBody(), true));
php
$response = $instance['v3/ecommerce/profitsharing/after-sales-orders']->post([
'json' => [
'sub_mchid' => '1900000109',
'transaction_id' => '3008450740201411110007820472',
'amount' => 10,
'type' => 'SERVICE_FEE_INCOME',
'scene' => 'REFUND_TICKET',
'refund_id' => '',
],
]);
print_r(json_decode((string) $response->getBody(), true));
返回字典 | 类型 | 描述 |
---|---|---|
sub_mchid | string | 二级商户号 |
transaction_id | string | 微信订单号 |
amount | integer | 分账金额 |
参阅 官方文档
查询售后服务分账结果
请求参数 | 类型 | 描述 |
---|---|---|
query | object | 声明请求的查询参数 |
sub_mchid | string | 二级商户号 |
transaction_id | string | 微信订单号 |
php
$instance->v3->ecommerce->profitsharing->afterSalesOrders->getAsync([
'query' => [
'sub_mchid' => '',
'transaction_id' => '',
],
])
->then(static function(\Psr\Http\Message\ResponseInterface $response) {
print_r(json_decode((string) $response->getBody(), true));
})
->wait();
php
$instance->chain('v3/ecommerce/profitsharing/after-sales-orders')->getAsync([
'query' => [
'sub_mchid' => '',
'transaction_id' => '',
],
])
->then(static function(\Psr\Http\Message\ResponseInterface $response) {
print_r(json_decode((string) $response->getBody(), true));
})
->wait();
php
$instance['v3/ecommerce/profitsharing/after-sales-orders']->getAsync([
'query' => [
'sub_mchid' => '',
'transaction_id' => '',
],
])
->then(static function(\Psr\Http\Message\ResponseInterface $response) {
print_r(json_decode((string) $response->getBody(), true));
})
->wait();
php
$response = $instance->v3->ecommerce->profitsharing->afterSalesOrders->get([
'query' => [
'sub_mchid' => '',
'transaction_id' => '',
],
]);
print_r(json_decode((string) $response->getBody(), true));
php
$response = $instance->chain('v3/ecommerce/profitsharing/after-sales-orders')->get([
'query' => [
'sub_mchid' => '',
'transaction_id' => '',
],
]);
print_r(json_decode((string) $response->getBody(), true));
php
$response = $instance['v3/ecommerce/profitsharing/after-sales-orders']->get([
'query' => [
'sub_mchid' => '',
'transaction_id' => '',
],
]);
print_r(json_decode((string) $response->getBody(), true));
返回字典 | 类型 | 描述 |
---|---|---|
sub_mchid | string | 二级商户号 |
transaction_id | string | 微信分账单号 |
amount | integer | 分账金额 |
result | string | 分账结果PROCESSING | SUCCESS | FAILED 枚举值之一 |
fail_reason | string | 分账失败原因ACCOUNT_ABNORMAL | NO_RELATION | RECEIVER_HIGH_RISK 枚举值之一 |
finish_time | string | 分账完成时间 |
参阅 官方文档