Skip to content

查询批次关联门店列表

品牌方可以通过该接口分页查询商品券批次所关联的门店列表 前置条件:已创建商品券批次且批次的 store_scope 为 SPECIFIC

请求参数类型描述
product_coupon_idstring商品券ID
stock_idstring批次ID
queryobject声明请求的查询参数
page_sizeinteger分页大小
page_tokenstring分页Token
brand_idstring品牌ID
php
$instance->v3->marketing->partner->productCoupon->productCoupons->_product_coupon_id_->stocks->_stock_id_->associatedStores->getAsync([
  'product_coupon_id' => '1000000013',
  'stock_id' => '1000000013001',
  'query' => [
    'page_size'  => 20,
    'page_token' => 'MTIzMjUK',
    'brand_id'   => '120344',
  ],
])
->then(static function(\Psr\Http\Message\ResponseInterface $response) {
  print_r(json_decode((string) $response->getBody(), true));
})
->wait();
php
$instance->chain('v3/marketing/partner/product-coupon/product-coupons/{product_coupon_id}/stocks/{stock_id}/associated-stores')->getAsync([
  'product_coupon_id' => '1000000013',
  'stock_id' => '1000000013001',
  'query' => [
    'page_size'  => 20,
    'page_token' => 'MTIzMjUK',
    'brand_id'   => '120344',
  ],
])
->then(static function(\Psr\Http\Message\ResponseInterface $response) {
  print_r(json_decode((string) $response->getBody(), true));
})
->wait();
php
$instance['v3/marketing/partner/product-coupon/product-coupons/{product_coupon_id}/stocks/{stock_id}/associated-stores']->getAsync([
  'product_coupon_id' => '1000000013',
  'stock_id' => '1000000013001',
  'query' => [
    'page_size'  => 20,
    'page_token' => 'MTIzMjUK',
    'brand_id'   => '120344',
  ],
])
->then(static function(\Psr\Http\Message\ResponseInterface $response) {
  print_r(json_decode((string) $response->getBody(), true));
})
->wait();
php
$response = $instance->v3->marketing->partner->productCoupon->productCoupons->_product_coupon_id_->stocks->_stock_id_->associatedStores->get([
  'product_coupon_id' => '1000000013',
  'stock_id' => '1000000013001',
  'query' => [
    'page_size'  => 20,
    'page_token' => 'MTIzMjUK',
    'brand_id'   => '120344',
  ],
]);
print_r(json_decode((string) $response->getBody(), true));
php
$response = $instance->chain('v3/marketing/partner/product-coupon/product-coupons/{product_coupon_id}/stocks/{stock_id}/associated-stores')->get([
  'product_coupon_id' => '1000000013',
  'stock_id' => '1000000013001',
  'query' => [
    'page_size'  => 20,
    'page_token' => 'MTIzMjUK',
    'brand_id'   => '120344',
  ],
]);
print_r(json_decode((string) $response->getBody(), true));
php
$response = $instance['v3/marketing/partner/product-coupon/product-coupons/{product_coupon_id}/stocks/{stock_id}/associated-stores']->get([
  'product_coupon_id' => '1000000013',
  'stock_id' => '1000000013001',
  'query' => [
    'page_size'  => 20,
    'page_token' => 'MTIzMjUK',
    'brand_id'   => '120344',
  ],
]);
print_r(json_decode((string) $response->getBody(), true));
返回字典类型描述
total_countinteger总个数
next_page_tokenstring下一页Token
store_listobject[]门店列表
store_idstring门店ID

参阅 官方文档

Published on the GitHub by TheNorthMemory