Skip to content

查询用户在品牌下所有会员卡

通过此接口可查询用户在当前品牌下领取的所有会员卡

请求参数类型描述
queryobject声明请求的查询参数
openidstring用户标识
appidstring商户AppId
offsetinteger分页页码
limitinteger分页大小
php
$instance->v3->marketing->membercardOpen->user->cards->getAsync([
  'query' => [
    'openid' => 'obLatjnx9gnqzS4myYGmLZ7LgLBA',
    'appid' => 'wxea9c30890f48d5ae',
    'offset' => 0,
    'limit' => 0,
  ],
])
->then(static function(\Psr\Http\Message\ResponseInterface $response) {
  print_r(json_decode((string) $response->getBody(), true));
})
->wait();
php
$instance->chain('v3/marketing/membercard-open/user/cards')->getAsync([
  'query' => [
    'openid' => 'obLatjnx9gnqzS4myYGmLZ7LgLBA',
    'appid' => 'wxea9c30890f48d5ae',
    'offset' => 0,
    'limit' => 0,
  ],
])
->then(static function(\Psr\Http\Message\ResponseInterface $response) {
  print_r(json_decode((string) $response->getBody(), true));
})
->wait();
php
$instance['v3/marketing/membercard-open/user/cards']->getAsync([
  'query' => [
    'openid' => 'obLatjnx9gnqzS4myYGmLZ7LgLBA',
    'appid' => 'wxea9c30890f48d5ae',
    'offset' => 0,
    'limit' => 0,
  ],
])
->then(static function(\Psr\Http\Message\ResponseInterface $response) {
  print_r(json_decode((string) $response->getBody(), true));
})
->wait();
php
$response = $instance->v3->marketing->membercardOpen->user->cards->get([
  'query' => [
    'openid' => 'obLatjnx9gnqzS4myYGmLZ7LgLBA',
    'appid' => 'wxea9c30890f48d5ae',
    'offset' => 0,
    'limit' => 0,
  ],
]);
print_r(json_decode((string) $response->getBody(), true));
php
$response = $instance->chain('v3/marketing/membercard-open/user/cards')->get([
  'query' => [
    'openid' => 'obLatjnx9gnqzS4myYGmLZ7LgLBA',
    'appid' => 'wxea9c30890f48d5ae',
    'offset' => 0,
    'limit' => 0,
  ],
]);
print_r(json_decode((string) $response->getBody(), true));
php
$response = $instance['v3/marketing/membercard-open/user/cards']->get([
  'query' => [
    'openid' => 'obLatjnx9gnqzS4myYGmLZ7LgLBA',
    'appid' => 'wxea9c30890f48d5ae',
    'offset' => 0,
    'limit' => 0,
  ],
]);
print_r(json_decode((string) $response->getBody(), true));
返回字典类型描述
dataobject[]会员卡列表
card_idstring会员卡id
codestring会员卡code
total_countinteger总数量
offsetinteger分页页码
limitinteger分页大小

参阅 官方文档

Published on the GitHub by TheNorthMemory