发起进件请求
开发环境
http://dev-cn.your-api-server.com
开发环境
http://dev-cn.your-api-server.com
POST
https://developer.toutiao.com/api/apps/ecpay/saas/create_merchant
如果进件接口没有返回 merchant_id,请使用原参数重新进件。
接口频次
20QPS(小程序app_id维度或thirdparty_id维度)
名称 | 类型 | 是否必填 | 最大长度 | 描述 | 示例值 |
---|---|---|---|---|---|
id_type | number | 是 | - | 证件类型枚举值 1: 身份证 2: 户口本 3: 护照 4: 军官证 5: 士兵证 6: 香港居民来往内地通行证 7: 台湾同胞来往内地通行证 8: 临时身份证 9: 外国人居留证 10: 警官证 11: 澳门同胞来往内地通行证 12: 港澳居住证 13: 台湾居住证 100: 其他证件类型(上面没有枚举的) | 1 |
id_no | string | 是 | 20 | 证件号 与id_type对应 | 110000199001011234 |
name | string | 是 | 64 | 证件人名字 | 张三 |
front_pic_url | string | 是 | 256 | 证件照主照片, 图片id, 通过图片上传接口获取 | "1.jpeg" |
back_pic_url | string | 条件选填 | 256 | 证件照副照片部分, 身份证的话,是国徽面 营业照可以不传副照 ,图片id, 通过图片上传接口获取 | "2.jpeg" |
begin_date | string | 是 | 64 | 证件照开始时间yyyymmdd 20211231 | 20211231 |
exp_date | string | 是 | 64 | 证件照过期时间yyyymmdd 20211231 长期填: 99991231 | 20211231 |
address | string | 条件选填 | 256 | 1.当所选渠道包含微信、商户类型为企业时,需要填写此项 2.请按照证件上住址填写,若证件上无住址则按照实际住址填写 | 浙江省杭州市 |
错误码
错误码 err_code | 描述 err_tips | 排查建议 |
---|---|---|
0 | 受理成功 | 受理成功 |
1000 | 内部错误 | 系统异常,请使用相同参数稍后重试 |
1004 | 未知异常 | 请原参数重试 |
1005 | 频率控制 | 请降低调用频率 |
1007 | 参数错误:channels参数不合法,请检查 | channels传参说明: 开通支付宝和抖音支付:[ "alipay" , "hz"] 开通支付宝、抖音支付、微信:[ "wx" , "alipay" , "hz"] |
2008 | 签名校验异常,请使用正确的签名和 json 传参 | 请检查参数,详见签名DEMO |
2010 | 参数错误: 参数MerchantType不正确 | 请使用正确的参数重新调用 |
参数错误: 进件渠道为空 | ||
参数错误: 未知类型(Invalid Type) | ||
参数错误:maAppID或者sub_merchant_id为空 | ||
参数错误:thirdPartyID为空 | ||
参数错误:thirdPartyID或maAppID或sub_merchant_id为空 | ||
参数错误:thirdPartyID或sub_merchant_id为空 | ||
参数错误: 参数:MerchantName 为空 | ||
参数错误: 参数:MerchantShortName 为空 | ||
参数错误: 没有合众营业执照 | ||
参数错误: 没有微信营业执照 | ||
参数错误: 没有支付宝营业执照 | ||
参数错误: 营业执照有效期起止时间错误 | ||
参数错误: 进件微信、合众或者进件支付宝且支付宝结算类型为银行卡时,开户银行不可为空 | ||
参数错误: 参数:店铺名称 为空 | ||
参数错误: 参数:店铺链接 为空 | ||
参数错误: 参数:签约的支付宝账户 为空 | ||
参数错误: 参数:OutOrderId 为空 | ||
参数错误:当管理员类型为法人时,管理员姓名和身份证号需要和法人的姓名和身份证号一致 | ||
7001 | 存在流程进行中的申请单或者已经进件成功 | 可通过查询申请单状态查看此申请单的申请状态 |
7002 | 申请单不存在 | 确认入参,传入正确的申请单编号 |
7003 | 商户重复入驻 | 商户更换文件后,重新调用 |
7025 | 当前小程序所归属的服务类目,暂不支持开通支付功能 | 详情请查看小程序交易能力接入规范 |
请求示例请求示例
Shell
JavaScript
Java
Swift
curl --location --request POST 'https://developer.toutiao.com/api/apps/ecpay/saas/create_merchant' \
--header 'Content-Type: application/json' \
--data-raw '{
"app_id": "ttcfdbb96650e33350",
"access_token": "abc123czxhc84392s123ahdbz9213cdnzujncjznuqh12389834bhdb8bchzj8182jdsjaju123",
"thirdparty_id": "",
"component_access_token": "",
"sub_merchant_id": "test_receive_92",
"type": 2,
"callback_url": "https://www.bytedance.com/cn",
"channels": ["alipay" , "hz"],
"merchant_type": 2,
"merchant_name": "北京字节跳动有限公司",
"merchant_short_name": "字节跳动",
"province_code": "110000",
"city_code": "110100",
"district_code": "110107",
"registered_addr": "北京市海淀区北三环西路43号2号楼三层303室",
"business_license": {
"business_license_type": 3,
"business_license_code": "130429199205274617",
"business_license_picurl": {
"hz": "tos-cn-i-01omznotxb/565352443d7c44b79aa135583ad64d11",
"alipay": "tos-cn-i-01omznotxb/565352443d7c44b79aa135583ad64d23"
},
"begin_date": "20211231",
"end_date": "99991231",
"address": "浙江省杭州市"
},
"legal_person": {
"id_type": 1,
"id_no": "13213429731104601X",
"name": "张三",
"front_pic_url": {
"hz": "tos-cn-i-01omznotxb/565352443d7c44b79aa135583ad64d11",
"alipay": "tos-cn-i-01omznotxb/565352443d7c44b79aa135583ad64d23"
},
"back_pic_url": {
"hz": "tos-cn-i-01omznotxb/565352443d7c44b79aa135583ad64d11",
"alipay": "tos-cn-i-01omznotxb/565352443d7c44b79aa135583ad64d23"
},
"begin_date": "20211231",
"exp_date": "99991231",
"address": "北京市海淀区北三环西路43号2号楼三层303室"
},
"merchant_card_info": {
"account_name": "北京字节跳动有限公司",
"account_no": "110932121411301",
"bank_full_name": "招商银行股份有限公司北京首体支行",
"settle_type": 2,
"card_type": "DC",
"settlement_cert_pic": "tos-cn-i-01omznotxb/1e19e6ba8b1e4755a886ab6a7447496c",
"relation_cert_pic": "tos-cn-i-01omznotxb/1e19e6ba8b1e4755a886ab6a7447496c",
"other_cert_pics": [
"tos-cn-i-01omznotxb/1e19e6ba8b1e4755a886ab6a7447496c",
"tos-cn-i-01omznotxb/1e19e6ba8b1e4755a886ab6a7447496c"
]
},
"merchant_operation_info": {
"manage_name": "张三",
"manage_mobile": "18388888888",
"manage_person_type": 2,
"manage_id_no": "110101199003078531",
"manage_email": "bytedance@163.com",
"shop_name": "字节跳动",
"shop_url": "http://www.bytedance.com",
"id_type": 1,
"id_begin_date": "20211231",
"id_exp_date": "99991231",
"id_front_pic_url": "tos-cn-i-01omznotxb/1e19e6ba8b1e4755a886ab6a7447496c",
"id_back_pic_url": "tos-cn-i-01omznotxb/1e19e6ba8b1e4755a886ab6a7447496c",
"business_authorization_letter": "tos-cn-i-01omznotxb/1e19e6ba8b1e4755a886ab6a7447496c"
},
"industry_code": ["1520"],
"sign": "5ee5474aff4e5623f464fd6bf12322bf",
"out_order_id": "s90219201291021920121212x-02",
"create_name": "李四",
"beneficiary_type": "LEGAL"
}'
响应示例响应示例
200 - 示例 1
{
"err_no": 0,
"err_tips": "string",
"apply_id": "string",
"merchant_id": "string"
}
请求参数
Header 参数
Content-Type
string
必需
Body 参数application/json