Skip to content

查询与用户授权记录(授权协议号)

通过authorization_code,商户查询与用户授权关系

请求参数类型描述
authorization_codestring授权协议号
queryobject声明请求的查询参数
service_idstring服务ID
sub_mchidstring子商户号
php
$instance->v3->payscore->partner->permissions->authorizationCode->_authorization_code_->getAsync([
  'authorization_code' => '1234323JKHDFE1243252',
  'query' => [
    'service_id' => '500001',
    'sub_mchid'  => '1230000109',
  ],
])
->then(static function(\Psr\Http\Message\ResponseInterface $response) {
  print_r(json_decode((string) $response->getBody(), true));
})
->wait();
php
$instance->chain('v3/payscore/partner/permissions/authorization-code/{authorization_code}')->getAsync([
  'authorization_code' => '1234323JKHDFE1243252',
  'query' => [
    'service_id' => '500001',
    'sub_mchid'  => '1230000109',
  ],
])
->then(static function(\Psr\Http\Message\ResponseInterface $response) {
  print_r(json_decode((string) $response->getBody(), true));
})
->wait();
php
$instance['v3/payscore/partner/permissions/authorization-code/{authorization_code}']->getAsync([
  'authorization_code' => '1234323JKHDFE1243252',
  'query' => [
    'service_id' => '500001',
    'sub_mchid'  => '1230000109',
  ],
])
->then(static function(\Psr\Http\Message\ResponseInterface $response) {
  print_r(json_decode((string) $response->getBody(), true));
})
->wait();
php
$response = $instance->v3->payscore->partner->permissions->authorizationCode->_authorization_code_->get([
  'authorization_code' => '1234323JKHDFE1243252',
  'query' => [
    'service_id' => '500001',
    'sub_mchid'  => '1230000109',
  ],
]);
print_r(json_decode((string) $response->getBody(), true));
php
$response = $instance->chain('v3/payscore/partner/permissions/authorization-code/{authorization_code}')->get([
  'authorization_code' => '1234323JKHDFE1243252',
  'query' => [
    'service_id' => '500001',
    'sub_mchid'  => '1230000109',
  ],
]);
print_r(json_decode((string) $response->getBody(), true));
php
$response = $instance['v3/payscore/partner/permissions/authorization-code/{authorization_code}']->get([
  'authorization_code' => '1234323JKHDFE1243252',
  'query' => [
    'service_id' => '500001',
    'sub_mchid'  => '1230000109',
  ],
]);
print_r(json_decode((string) $response->getBody(), true));
返回字典类型描述
service_idstring服务ID
appidstring服务商应用ID
mchidstring商户号
openidstring服务商公众号下的用户标识
authorization_codestring授权协议号
authorization_statestring授权状态
notify_urlstring授权通知地址
cancel_authorization_timestring最近一次解除授权时间
authorization_success_timestring最近一次授权成功时间
sub_mchidstring子商户号
sub_appidstring子商户应用ID
sub_openidstring子商户公众号下的用户标识
user_risk_levelnumber用户分层
risk_level_versionnumber分层版本

参阅 官方文档 官方文档

Published on the GitHub by TheNorthMemory