# 获取商户列表接口
接口地址: http://www.damaijia168.com/vv/external/listMerchant
请求方式:POST
返回格式:JSON
# 请求头参数
| 参数 | 类型 | 必选 | 值 | 示例 |
|---|---|---|---|---|
| Authorization | string | 是 | 授权 access_token | 1798c6aadec33d1bc2f5b707f1049aefexxxx |
# 请求参数
无
# 请求示例代码
cURL请求代码示例
curl --location --request POST 'http://www.damaijia168.com/vv/external/listMerchant' --header 'Authorization: 493d131b9e696dc897a4233e7ab8****'
PHP请求代码示例
<?php
$curl = curl_init();
curl_setopt_array($curl, array(
CURLOPT_URL => 'http://www.damaijia168.com/vv/external/listMerchant',
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => '',
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 0,
CURLOPT_FOLLOWLOCATION => true,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => 'POST',
CURLOPT_HTTPHEADER => array(
'Authorization: 493d131b9e696dc897a4233e7ab8****'
),
));
$response = curl_exec($curl);
curl_close($curl);
echo $response;
JAVA请求代码示例
OkHttpClient client = new OkHttpClient().newBuilder()
.build();
MediaType mediaType = MediaType.parse("text/plain");
RequestBody body = RequestBody.create(mediaType, "");
Request request = new Request.Builder()
.url("http://www.damaijia168.com/vv/external/listMerchant")
.method("POST", body)
.addHeader("Authorization", "493d131b9e696dc897a4233e7ab8****")
.build();
Response response = client.newCall(request).execute();
Python请求代码示例
import requests
import json
url = "http://www.damaijia168.com/vv/external/listMerchant"
headers = {
'Authorization': '1798c6aadec33d1bc2f5b707f1049aefexxxx',
'Content-Type': 'application/json'
}
response = requests.request("POST", url, headers=headers)
print(response.text)
# 返回数据
| 参数名 | 返回值类型 | 备注 | 其他信息 |
|---|---|---|---|
| status | string | 返回码描述 | |
| data | object [] | 数据信息 | 返回失败为空字符的字符串类型,成功则是数组 |
| ----merchantNum | string | 商户号 | |
| ----merchantName | string | 商户名称 | |
| ----accountDayMax | number | 当日上限金额 | |
| ----accountOneMax | number | 单笔上限金额 | |
| ----accountCheckStatus | number | 商户号状态 | 1:待审核 2:收款账号审核通过 2:收款账号审核拒绝 |
| ----accountPayType | number | 账户付款类型 | |
| ----amount | int | 消耗点券 | 单位:点券 |
# 返回示例代码
json格式返回代码示例
{
"data": [
{
"merchantNum": "2****2",
"accountDayMax": 100000,
"accountOneMax": 10000,
"accountPayType": 1,
"accountCheckStatus": 1,
"merchantName": "****"
}
],
"status": 0
}
# 错误码
| 状态码 | 错误说明 |
|---|---|
| 1003 | 用户不存在 |
| 132 | 请求格式必须为JSON |
| 422 | 参数列表不合法,在err中会给出提示 |
| 200 | 认证失败 |
| 202 | 商品id不合法 |
| 203 | 仓库id不合法 |
| 228 | 订单来源不合法 |
| 217 | 创建订单失败 |
| 212 | 包裹id不合法 |
| 209 | 账户余额不足 |
← 淘宝详情页 2_获取支付二维码v2接口 →