Skip to content

查询子商户(融合钱包)

用于机构查询子商户创建是否成功,接口只提供单个子商户信息查询。

请求参数类型描述
base_uristring声明接入点https://apihk.mch.weixin.qq.com/(香港接入)
sub_mchidstring子商户号
queryobject声明请求的查询参数
sp_appidstring机构appid
sp_mchidstring机构商户号
php
$instance->v3->global->merchants->_sub_mchid_->getAsync([
  'base_uri' => 'https://apihk.mch.weixin.qq.com/', // 接入点(香港接入)
  'sub_mchid' => '20000100',
  'query' => [
    'sp_appid' => 'wx8888888888888888',
    'sp_mchid' => '3200000001',
  ],
])
->then(static function(\Psr\Http\Message\ResponseInterface $response) {
  print_r(json_decode((string) $response->getBody(), true));
})
->wait();
php
$instance->chain('v3/global/merchants/{sub_mchid}')->getAsync([
  'base_uri' => 'https://apihk.mch.weixin.qq.com/', // 接入点(香港接入)
  'sub_mchid' => '20000100',
  'query' => [
    'sp_appid' => 'wx8888888888888888',
    'sp_mchid' => '3200000001',
  ],
])
->then(static function(\Psr\Http\Message\ResponseInterface $response) {
  print_r(json_decode((string) $response->getBody(), true));
})
->wait();
php
$instance['v3/global/merchants/{sub_mchid}']->getAsync([
  'base_uri' => 'https://apihk.mch.weixin.qq.com/', // 接入点(香港接入)
  'sub_mchid' => '20000100',
  'query' => [
    'sp_appid' => 'wx8888888888888888',
    'sp_mchid' => '3200000001',
  ],
])
->then(static function(\Psr\Http\Message\ResponseInterface $response) {
  print_r(json_decode((string) $response->getBody(), true));
})
->wait();
php
$response = $instance->v3->global->merchants->_sub_mchid_->get([
  'base_uri' => 'https://apihk.mch.weixin.qq.com/', // 接入点(香港接入)
  'sub_mchid' => '20000100',
  'query' => [
    'sp_appid' => 'wx8888888888888888',
    'sp_mchid' => '3200000001',
  ],
]);
print_r(json_decode((string) $response->getBody(), true));
php
$response = $instance->chain('v3/global/merchants/{sub_mchid}')->get([
  'base_uri' => 'https://apihk.mch.weixin.qq.com/', // 接入点(香港接入)
  'sub_mchid' => '20000100',
  'query' => [
    'sp_appid' => 'wx8888888888888888',
    'sp_mchid' => '3200000001',
  ],
]);
print_r(json_decode((string) $response->getBody(), true));
php
$response = $instance['v3/global/merchants/{sub_mchid}']->get([
  'base_uri' => 'https://apihk.mch.weixin.qq.com/', // 接入点(香港接入)
  'sub_mchid' => '20000100',
  'query' => [
    'sp_appid' => 'wx8888888888888888',
    'sp_mchid' => '3200000001',
  ],
]);
print_r(json_decode((string) $response->getBody(), true));
返回字典类型描述
sub_mchidstring子商户号
namestring子商户全称
shortnamestring子商户简称
office_phonestring公司联系方式
merchant_country_codestring册国家或区域
business_categoryinteger类目
contactobject联系人信息
namestring联系人名称
phonestring联系人电话
emailstring联系人邮箱
merchant_typestring商户类型
registration_certificate_numberstring公司注册文件编号
registration_certificate_datestring公司注册文件过期时间
settlement_bank_numberstring子商户结算账户
businessobject业务信息
business_typestring业务类型
app_downloadstringAPP下载地址
websitestring业务网站
office_accountstring公众号
mini_programstring小程序
store_addressstring门店地址
mccstringMCC码
directorobject董事信息
namestring董事姓名
numberstring董事证件号码
principalobject负责人信息
namestring负责人姓名
numberstring负责人证件号码

参阅 官方文档

修改子商户(融合钱包)

用于机构子商户创建成功后,接口提供子商户信息修改

请求参数类型描述
base_uristring声明接入点https://apihk.mch.weixin.qq.com/(香港接入)
jsonobject声明请求的JSON数据结构
sp_appidstring机构appid
sp_mchidstring机构商户号
namestring子商户全称
sub_mchidstring子商户号
shortnamestring子商户简称
office_phonestring公司电话
contactobject联系人信息
namestring联系人名称
phonestring联系人电话
emailstring联系人邮箱
business_categoryinteger类目
channel_idstring渠道号
merchant_country_codestring注册国家或区域
merchant_typestring商户类型
registration_certificate_numberstring公司注册文件编号
registration_certificate_datestring公司注册文件过期时间
registration_certificate_copystring公司注册文件照片
settlement_bank_numberstring子商户银行结算账户信息
businessobject业务信息
business_typestring业务类型
app_downloadstringAPP下载链接
websitestring业务网站
office_accountstring公众号
mini_programstring小程序
store_addressstring门店地址
store_photosstring门店照片
mccstringMCC码
directorobject董事信息
namestring董事姓名
numberstring董事证件号
principalobject负责人信息
namestring负责人姓名
numberstring负责人证件号
apply_h5_paymentboolean是否申请H5支付权限
h5_payment_apply_infoobjectH5支付申请资料资料
website_urlstringH5经营网址
domainsstring[]H5支付域名
php
$instance->v3->global->merchants->_sub_mchid_->patchAsync([
  'base_uri' => 'https://apihk.mch.weixin.qq.com/', // 接入点(香港接入)
  'json' => [
    'sp_appid'                        => 'wx8888888888888888',
    'sp_mchid'                        => '3200000001',
    'name'                            => 'Merchant name',
    'sub_mchid'                       => '示例值: 20000100',
    'shortname'                       => 'Merchant shortname',
    'office_phone'                    => '075586010000',
    'contact'                         => [
      'name'  => '李先生',
      'phone' => '075586010000',
      'email' => 'test@test.com',
    ],
    'business_category'               => 644,
    'channel_id'                      => '3200000001',
    'merchant_country_code'           => '344',
    'merchant_type'                   => 'ENTERPRISE',
    'registration_certificate_number' => '5555-8888',
    'registration_certificate_date'   => '2020-10-16',
    'registration_certificate_copy'   => 'w7yQFawBtja5uEdm_aoXokv2SDoEmHIPs',
    'settlement_bank_number'          => '555588889999',
    'business'                        => [
      'business_type'  => 'BOTH',
      'app_download'   => 'https://download.qq.com',
      'website'        => 'https://www.qq.com',
      'office_account' => 'wx8888888888888888',
      'mini_program'   => 'wx8888888888888888',
      'store_address'  => '10F World Finance Centre (South Office), 11 Canton Road, Tsim Sha Tsui, Hong Kong',
      'store_photos'   => '[Media_id1, Media_id2, Media_id3]',
      'mcc'            => '4214',
    ],
    'director'                        => [
      'name'   => 'Bob',
      'number' => '5555-8888',
    ],
    'principal'                       => [
      'name'   => 'Bob',
      'number' => '5555-8888',
    ],
    'apply_h5_payment'                => true,
    'h5_payment_apply_info'           => [
      'website_url' => 'https://qq.com',
      'domains'     => ['string'],
    ],
  ],
])
->then(static function(\Psr\Http\Message\ResponseInterface $response) {
  print_r(json_decode((string) $response->getBody(), true));
})
->wait();
php
$instance->chain('v3/global/merchants/{sub_mchid}')->patchAsync([
  'base_uri' => 'https://apihk.mch.weixin.qq.com/', // 接入点(香港接入)
  'json' => [
    'sp_appid'                        => 'wx8888888888888888',
    'sp_mchid'                        => '3200000001',
    'name'                            => 'Merchant name',
    'sub_mchid'                       => '示例值: 20000100',
    'shortname'                       => 'Merchant shortname',
    'office_phone'                    => '075586010000',
    'contact'                         => [
      'name'  => '李先生',
      'phone' => '075586010000',
      'email' => 'test@test.com',
    ],
    'business_category'               => 644,
    'channel_id'                      => '3200000001',
    'merchant_country_code'           => '344',
    'merchant_type'                   => 'ENTERPRISE',
    'registration_certificate_number' => '5555-8888',
    'registration_certificate_date'   => '2020-10-16',
    'registration_certificate_copy'   => 'w7yQFawBtja5uEdm_aoXokv2SDoEmHIPs',
    'settlement_bank_number'          => '555588889999',
    'business'                        => [
      'business_type'  => 'BOTH',
      'app_download'   => 'https://download.qq.com',
      'website'        => 'https://www.qq.com',
      'office_account' => 'wx8888888888888888',
      'mini_program'   => 'wx8888888888888888',
      'store_address'  => '10F World Finance Centre (South Office), 11 Canton Road, Tsim Sha Tsui, Hong Kong',
      'store_photos'   => '[Media_id1, Media_id2, Media_id3]',
      'mcc'            => '4214',
    ],
    'director'                        => [
      'name'   => 'Bob',
      'number' => '5555-8888',
    ],
    'principal'                       => [
      'name'   => 'Bob',
      'number' => '5555-8888',
    ],
    'apply_h5_payment'                => true,
    'h5_payment_apply_info'           => [
      'website_url' => 'https://qq.com',
      'domains'     => ['string'],
    ],
  ],
])
->then(static function(\Psr\Http\Message\ResponseInterface $response) {
  print_r(json_decode((string) $response->getBody(), true));
})
->wait();
php
$instance['v3/global/merchants/{sub_mchid}']->patchAsync([
  'base_uri' => 'https://apihk.mch.weixin.qq.com/', // 接入点(香港接入)
  'json' => [
    'sp_appid'                        => 'wx8888888888888888',
    'sp_mchid'                        => '3200000001',
    'name'                            => 'Merchant name',
    'sub_mchid'                       => '示例值: 20000100',
    'shortname'                       => 'Merchant shortname',
    'office_phone'                    => '075586010000',
    'contact'                         => [
      'name'  => '李先生',
      'phone' => '075586010000',
      'email' => 'test@test.com',
    ],
    'business_category'               => 644,
    'channel_id'                      => '3200000001',
    'merchant_country_code'           => '344',
    'merchant_type'                   => 'ENTERPRISE',
    'registration_certificate_number' => '5555-8888',
    'registration_certificate_date'   => '2020-10-16',
    'registration_certificate_copy'   => 'w7yQFawBtja5uEdm_aoXokv2SDoEmHIPs',
    'settlement_bank_number'          => '555588889999',
    'business'                        => [
      'business_type'  => 'BOTH',
      'app_download'   => 'https://download.qq.com',
      'website'        => 'https://www.qq.com',
      'office_account' => 'wx8888888888888888',
      'mini_program'   => 'wx8888888888888888',
      'store_address'  => '10F World Finance Centre (South Office), 11 Canton Road, Tsim Sha Tsui, Hong Kong',
      'store_photos'   => '[Media_id1, Media_id2, Media_id3]',
      'mcc'            => '4214',
    ],
    'director'                        => [
      'name'   => 'Bob',
      'number' => '5555-8888',
    ],
    'principal'                       => [
      'name'   => 'Bob',
      'number' => '5555-8888',
    ],
    'apply_h5_payment'                => true,
    'h5_payment_apply_info'           => [
      'website_url' => 'https://qq.com',
      'domains'     => ['string'],
    ],
  ],
])
->then(static function(\Psr\Http\Message\ResponseInterface $response) {
  print_r(json_decode((string) $response->getBody(), true));
})
->wait();
php
$response = $instance->v3->global->merchants->_sub_mchid_->patch([
  'base_uri' => 'https://apihk.mch.weixin.qq.com/', // 接入点(香港接入)
  'json' => [
    'sp_appid'                        => 'wx8888888888888888',
    'sp_mchid'                        => '3200000001',
    'name'                            => 'Merchant name',
    'sub_mchid'                       => '示例值: 20000100',
    'shortname'                       => 'Merchant shortname',
    'office_phone'                    => '075586010000',
    'contact'                         => [
      'name'  => '李先生',
      'phone' => '075586010000',
      'email' => 'test@test.com',
    ],
    'business_category'               => 644,
    'channel_id'                      => '3200000001',
    'merchant_country_code'           => '344',
    'merchant_type'                   => 'ENTERPRISE',
    'registration_certificate_number' => '5555-8888',
    'registration_certificate_date'   => '2020-10-16',
    'registration_certificate_copy'   => 'w7yQFawBtja5uEdm_aoXokv2SDoEmHIPs',
    'settlement_bank_number'          => '555588889999',
    'business'                        => [
      'business_type'  => 'BOTH',
      'app_download'   => 'https://download.qq.com',
      'website'        => 'https://www.qq.com',
      'office_account' => 'wx8888888888888888',
      'mini_program'   => 'wx8888888888888888',
      'store_address'  => '10F World Finance Centre (South Office), 11 Canton Road, Tsim Sha Tsui, Hong Kong',
      'store_photos'   => '[Media_id1, Media_id2, Media_id3]',
      'mcc'            => '4214',
    ],
    'director'                        => [
      'name'   => 'Bob',
      'number' => '5555-8888',
    ],
    'principal'                       => [
      'name'   => 'Bob',
      'number' => '5555-8888',
    ],
    'apply_h5_payment'                => true,
    'h5_payment_apply_info'           => [
      'website_url' => 'https://qq.com',
      'domains'     => ['string'],
    ],
  ],
]);
print_r(json_decode((string) $response->getBody(), true));
php
$response = $instance->chain('v3/global/merchants/{sub_mchid}')->patch([
  'base_uri' => 'https://apihk.mch.weixin.qq.com/', // 接入点(香港接入)
  'json' => [
    'sp_appid'                        => 'wx8888888888888888',
    'sp_mchid'                        => '3200000001',
    'name'                            => 'Merchant name',
    'sub_mchid'                       => '示例值: 20000100',
    'shortname'                       => 'Merchant shortname',
    'office_phone'                    => '075586010000',
    'contact'                         => [
      'name'  => '李先生',
      'phone' => '075586010000',
      'email' => 'test@test.com',
    ],
    'business_category'               => 644,
    'channel_id'                      => '3200000001',
    'merchant_country_code'           => '344',
    'merchant_type'                   => 'ENTERPRISE',
    'registration_certificate_number' => '5555-8888',
    'registration_certificate_date'   => '2020-10-16',
    'registration_certificate_copy'   => 'w7yQFawBtja5uEdm_aoXokv2SDoEmHIPs',
    'settlement_bank_number'          => '555588889999',
    'business'                        => [
      'business_type'  => 'BOTH',
      'app_download'   => 'https://download.qq.com',
      'website'        => 'https://www.qq.com',
      'office_account' => 'wx8888888888888888',
      'mini_program'   => 'wx8888888888888888',
      'store_address'  => '10F World Finance Centre (South Office), 11 Canton Road, Tsim Sha Tsui, Hong Kong',
      'store_photos'   => '[Media_id1, Media_id2, Media_id3]',
      'mcc'            => '4214',
    ],
    'director'                        => [
      'name'   => 'Bob',
      'number' => '5555-8888',
    ],
    'principal'                       => [
      'name'   => 'Bob',
      'number' => '5555-8888',
    ],
    'apply_h5_payment'                => true,
    'h5_payment_apply_info'           => [
      'website_url' => 'https://qq.com',
      'domains'     => ['string'],
    ],
  ],
]);
print_r(json_decode((string) $response->getBody(), true));
php
$response = $instance['v3/global/merchants/{sub_mchid}']->patch([
  'base_uri' => 'https://apihk.mch.weixin.qq.com/', // 接入点(香港接入)
  'json' => [
    'sp_appid'                        => 'wx8888888888888888',
    'sp_mchid'                        => '3200000001',
    'name'                            => 'Merchant name',
    'sub_mchid'                       => '示例值: 20000100',
    'shortname'                       => 'Merchant shortname',
    'office_phone'                    => '075586010000',
    'contact'                         => [
      'name'  => '李先生',
      'phone' => '075586010000',
      'email' => 'test@test.com',
    ],
    'business_category'               => 644,
    'channel_id'                      => '3200000001',
    'merchant_country_code'           => '344',
    'merchant_type'                   => 'ENTERPRISE',
    'registration_certificate_number' => '5555-8888',
    'registration_certificate_date'   => '2020-10-16',
    'registration_certificate_copy'   => 'w7yQFawBtja5uEdm_aoXokv2SDoEmHIPs',
    'settlement_bank_number'          => '555588889999',
    'business'                        => [
      'business_type'  => 'BOTH',
      'app_download'   => 'https://download.qq.com',
      'website'        => 'https://www.qq.com',
      'office_account' => 'wx8888888888888888',
      'mini_program'   => 'wx8888888888888888',
      'store_address'  => '10F World Finance Centre (South Office), 11 Canton Road, Tsim Sha Tsui, Hong Kong',
      'store_photos'   => '[Media_id1, Media_id2, Media_id3]',
      'mcc'            => '4214',
    ],
    'director'                        => [
      'name'   => 'Bob',
      'number' => '5555-8888',
    ],
    'principal'                       => [
      'name'   => 'Bob',
      'number' => '5555-8888',
    ],
    'apply_h5_payment'                => true,
    'h5_payment_apply_info'           => [
      'website_url' => 'https://qq.com',
      'domains'     => ['string'],
    ],
  ],
]);
print_r(json_decode((string) $response->getBody(), true));
返回字典类型描述
sub_mchidstring子商户号
h5_authorization_statestringH5支付权限状态

参阅 官方文档

Published on the GitHub by TheNorthMemory