查询合作关系列表
该接口主要为商户提供合作关系列表的查询能力。
| 请求参数 | 类型 | 描述 |
|---|---|---|
| query | object | 声明请求的查询参数 |
| partner | string | 合作方信息JSON格式字符串 |
| type | string | 合作方类别APPID | MERCHANT 枚举值之一 |
| appid | string | 合作方APPID |
| merchant_id | string | 合作方商户ID |
| authorized_data | string | 被授权数据JSON格式字符串 |
| business_type | string | 授权业务类别FAVOR_STOCK | BUSIFAVOR_STOCK 枚举值之一 |
| stock_id | string | 授权批次ID |
| limit | integer | 分页大小 |
| offset | integer | 分页页码 |
php
$instance->v3->marketing->partnerships->getAsync([
'query' => [
'partner' => \json_encode([
'type' => 'APPID',
'appid' => 'wx4e1916a585d1f4e9',
'merchant_id' => '2480029552',
]),
'authorized_data' => \json_encode([
'business_type' => 'FAVOR_STOCK',
'stock_id' => '2433405',
]),
'limit' => 50,
'offset' => 0,
],
])
->then(static function(\Psr\Http\Message\ResponseInterface $response) {
print_r(json_decode((string) $response->getBody(), true));
})
->wait();php
$instance->chain('v3/marketing/partnerships')->getAsync([
'query' => [
'partner' => \json_encode([
'type' => 'APPID',
'appid' => 'wx4e1916a585d1f4e9',
'merchant_id' => '2480029552',
]),
'authorized_data' => \json_encode([
'business_type' => 'FAVOR_STOCK',
'stock_id' => '2433405',
]),
'limit' => 50,
'offset' => 0,
],
])
->then(static function(\Psr\Http\Message\ResponseInterface $response) {
print_r(json_decode((string) $response->getBody(), true));
})
->wait();php
$instance['v3/marketing/partnerships']->getAsync([
'query' => [
'partner' => \json_encode([
'type' => 'APPID',
'appid' => 'wx4e1916a585d1f4e9',
'merchant_id' => '2480029552',
]),
'authorized_data' => \json_encode([
'business_type' => 'FAVOR_STOCK',
'stock_id' => '2433405',
]),
'limit' => 50,
'offset' => 0,
],
])
->then(static function(\Psr\Http\Message\ResponseInterface $response) {
print_r(json_decode((string) $response->getBody(), true));
})
->wait();php
$response = $instance->v3->marketing->partnerships->get([
'query' => [
'partner' => \json_encode([
'type' => 'APPID',
'appid' => 'wx4e1916a585d1f4e9',
'merchant_id' => '2480029552',
]),
'authorized_data' => \json_encode([
'business_type' => 'FAVOR_STOCK',
'stock_id' => '2433405',
]),
'limit' => 50,
'offset' => 0,
],
]);
print_r(json_decode((string) $response->getBody(), true));php
$response = $instance->chain('v3/marketing/partnerships')->get([
'query' => [
'partner' => \json_encode([
'type' => 'APPID',
'appid' => 'wx4e1916a585d1f4e9',
'merchant_id' => '2480029552',
]),
'authorized_data' => \json_encode([
'business_type' => 'FAVOR_STOCK',
'stock_id' => '2433405',
]),
'limit' => 50,
'offset' => 0,
],
]);
print_r(json_decode((string) $response->getBody(), true));php
$response = $instance['v3/marketing/partnerships']->get([
'query' => [
'partner' => \json_encode([
'type' => 'APPID',
'appid' => 'wx4e1916a585d1f4e9',
'merchant_id' => '2480029552',
]),
'authorized_data' => \json_encode([
'business_type' => 'FAVOR_STOCK',
'stock_id' => '2433405',
]),
'limit' => 50,
'offset' => 0,
],
]);
print_r(json_decode((string) $response->getBody(), true));| 返回字典 | 类型 | 描述 |
|---|---|---|
| data | object[] | 合作关系结果集 |
| partner | object | 合作方信息 |
| type | string | 合作方类别 |
| appid | string | 合作方APPID |
| merchant_id | string | 合作方商户ID |
| authorized_data | object | 被授权数据 |
| business_type | string | 授权业务类别 |
| stock_id | string | 授权批次ID |
| build_time | string | 建立合作关系时间 |
| terminate_time | string | 终止合作关系时间 |
| create_time | string | 创建时间 |
| update_time | string | 更新时间 |
| limit | integer | 分页大小 |
| offset | integer | 分页页码 |
| total_count | integer | 总数量 |