Skip to content

预签约接口

一键绑卡不是支持所有银行卡,上线前请先测试是否支持该银行卡。

请求参数类型描述
jsonobject声明请求的JSON数据结构
business_namestring业务类型
facepay_userobject刷脸用户信息
out_user_idstring商户用户ID
identification_namestring刷脸用户名
organization_idstring机构ID
identificationobject证件信息
identification_typestring证件类型
IDCARD 枚举值
identification_numberstring证件ID
phonestring手机号码
limit_bank_cardobject签约指定银行卡
bank_card_numberstring银行卡号
identification_namestring开卡人姓名
identificationobject开卡人证件
identification_typestring证件类型
IDCARD 枚举值
identification_numberstring证件ID
valid_thrustring银行卡有效期
bank_typestring银行类型
phonestring开卡预留手机号
contract_modestring签约模式
LIMIT_BANK_CARD | PRIORITY_BANK_CARD | LIMIT_NONE 枚举值之一
headersobject声明请求的头参数
Wechatpay-Serialstring平台公钥ID/平台公钥证书序列号
php
$instance->v3->offlineface->contracts->presign->postAsync([
  'json' => [
    'business_name'   => '',
    'facepay_user'    => [
      'out_user_id'         => '',
      'identification_name' => '',
      'organization_id'     => '',
      'identification'      => [
        'identification_type'   => 'IDCARD',
        'identification_number' => '',
      ],
      'phone'               => '',
    ],
    'limit_bank_card' => [
      'bank_card_number'    => '',
      'identification_name' => '',
      'identification'      => [
        'identification_type'   => 'IDCARD',
        'identification_number' => '',
      ],
      'valid_thru'          => '',
      'bank_type'           => '',
      'phone'               => '',
    ],
    'contract_mode'   => 'LIMIT_BANK_CARD',
  ],
  'headers' => [
    'Wechatpay-Serial' => 'PUB_KEY_ID_0114232134912410000000000000',
  ],
])
->then(static function(\Psr\Http\Message\ResponseInterface $response) {
  print_r(json_decode((string) $response->getBody(), true));
})
->wait();
php
$instance->chain('v3/offlineface/contracts/presign')->postAsync([
  'json' => [
    'business_name'   => '',
    'facepay_user'    => [
      'out_user_id'         => '',
      'identification_name' => '',
      'organization_id'     => '',
      'identification'      => [
        'identification_type'   => 'IDCARD',
        'identification_number' => '',
      ],
      'phone'               => '',
    ],
    'limit_bank_card' => [
      'bank_card_number'    => '',
      'identification_name' => '',
      'identification'      => [
        'identification_type'   => 'IDCARD',
        'identification_number' => '',
      ],
      'valid_thru'          => '',
      'bank_type'           => '',
      'phone'               => '',
    ],
    'contract_mode'   => 'LIMIT_BANK_CARD',
  ],
  'headers' => [
    'Wechatpay-Serial' => 'PUB_KEY_ID_0114232134912410000000000000',
  ],
])
->then(static function(\Psr\Http\Message\ResponseInterface $response) {
  print_r(json_decode((string) $response->getBody(), true));
})
->wait();
php
$instance['v3/offlineface/contracts/presign']->postAsync([
  'json' => [
    'business_name'   => '',
    'facepay_user'    => [
      'out_user_id'         => '',
      'identification_name' => '',
      'organization_id'     => '',
      'identification'      => [
        'identification_type'   => 'IDCARD',
        'identification_number' => '',
      ],
      'phone'               => '',
    ],
    'limit_bank_card' => [
      'bank_card_number'    => '',
      'identification_name' => '',
      'identification'      => [
        'identification_type'   => 'IDCARD',
        'identification_number' => '',
      ],
      'valid_thru'          => '',
      'bank_type'           => '',
      'phone'               => '',
    ],
    'contract_mode'   => 'LIMIT_BANK_CARD',
  ],
  'headers' => [
    'Wechatpay-Serial' => 'PUB_KEY_ID_0114232134912410000000000000',
  ],
])
->then(static function(\Psr\Http\Message\ResponseInterface $response) {
  print_r(json_decode((string) $response->getBody(), true));
})
->wait();
php
$response = $instance->v3->offlineface->contracts->presign->post([
  'json' => [
    'business_name'   => '',
    'facepay_user'    => [
      'out_user_id'         => '',
      'identification_name' => '',
      'organization_id'     => '',
      'identification'      => [
        'identification_type'   => 'IDCARD',
        'identification_number' => '',
      ],
      'phone'               => '',
    ],
    'limit_bank_card' => [
      'bank_card_number'    => '',
      'identification_name' => '',
      'identification'      => [
        'identification_type'   => 'IDCARD',
        'identification_number' => '',
      ],
      'valid_thru'          => '',
      'bank_type'           => '',
      'phone'               => '',
    ],
    'contract_mode'   => 'LIMIT_BANK_CARD',
  ],
  'headers' => [
    'Wechatpay-Serial' => 'PUB_KEY_ID_0114232134912410000000000000',
  ],
]);
print_r(json_decode((string) $response->getBody(), true));
php
$response = $instance->chain('v3/offlineface/contracts/presign')->post([
  'json' => [
    'business_name'   => '',
    'facepay_user'    => [
      'out_user_id'         => '',
      'identification_name' => '',
      'organization_id'     => '',
      'identification'      => [
        'identification_type'   => 'IDCARD',
        'identification_number' => '',
      ],
      'phone'               => '',
    ],
    'limit_bank_card' => [
      'bank_card_number'    => '',
      'identification_name' => '',
      'identification'      => [
        'identification_type'   => 'IDCARD',
        'identification_number' => '',
      ],
      'valid_thru'          => '',
      'bank_type'           => '',
      'phone'               => '',
    ],
    'contract_mode'   => 'LIMIT_BANK_CARD',
  ],
  'headers' => [
    'Wechatpay-Serial' => 'PUB_KEY_ID_0114232134912410000000000000',
  ],
]);
print_r(json_decode((string) $response->getBody(), true));
php
$response = $instance['v3/offlineface/contracts/presign']->post([
  'json' => [
    'business_name'   => '',
    'facepay_user'    => [
      'out_user_id'         => '',
      'identification_name' => '',
      'organization_id'     => '',
      'identification'      => [
        'identification_type'   => 'IDCARD',
        'identification_number' => '',
      ],
      'phone'               => '',
    ],
    'limit_bank_card' => [
      'bank_card_number'    => '',
      'identification_name' => '',
      'identification'      => [
        'identification_type'   => 'IDCARD',
        'identification_number' => '',
      ],
      'valid_thru'          => '',
      'bank_type'           => '',
      'phone'               => '',
    ],
    'contract_mode'   => 'LIMIT_BANK_CARD',
  ],
  'headers' => [
    'Wechatpay-Serial' => 'PUB_KEY_ID_0114232134912410000000000000',
  ],
]);
print_r(json_decode((string) $response->getBody(), true));
返回字典类型描述
presign_tokenstring会话ID

参阅 官方文档

Published on the GitHub by TheNorthMemory