
车型大全
企业用户实名使用个人用户实名使用个人用户无法使用
第一步加载所有车品牌,根据车品牌查车系,根据车系查车型,根据车型查车辆详情信息
价格
¥0元/10次
新用户免费体验,自购买起有效期1个月
选择套餐:

接口名称:车品牌查询
描述:查询所有车辆品牌
请求地址 url:https://api.shuxuntech.com/v1/car_brand/query
请求方式 method:get/post
参数:
| 名称 | 参数位置 | 类型 | 是否必填 | 说明 |
|---|---|---|---|---|
| appKey | head | string | 是 | 数勋分配appKey |
| timestamp | head | string | 是 | 当前时间的毫秒数 |
| sign | head | string | 是 | 签名,说明 |
签名算法说明:
数勋分配的appKey、当前unix时间毫秒数timestamp、数勋分配的appSecret、 按顺序拼接sha256加密得到sign,查看如下示例
appKey = aaa;
timestamp = 1682476904289;
appSecret = bbb;
sign = sha256(appKey+timestamp+appSecret)
正确返回:
{
"code": "0",
"msg": "成功",
"isFee": 1,
"seqNo": "5m25xyvkvrasa17kgkwag2cofhj864rj",
"data": [
{
"initial": "A", //品牌首字母
"name": "ASKA", //品牌名称
"logo": "http://dev.img.shuxuntech.com/car_brand/202412/1734094124710.png", //品牌logo
"id": "167417" //品牌ID,可根据该ID查车系信息
},
{
"initial": "A",
"name": "ABT",
"logo": "http://dev.img.shuxuntech.com/car_brand/202412/1734094125070.png",
"id": "47641"
},
{
"initial": "A",
"name": "埃安",
"logo": "http://dev.img.shuxuntech.com/car_brand/202412/1734094126533.png",
"id": "42109"
},
{
"initial": "A",
"name": "Adria",
"logo": "http://dev.img.shuxuntech.com/car_brand/202412/1734094126622.png",
"id": "180610"
},
{
"initial": "A",
"name": "安培",
"logo": "http://dev.img.shuxuntech.com/car_brand/202412/1734094126709.png",
"id": "177149"
},
{
"initial": "A",
"name": "AKXY2",
"logo": "http://dev.img.shuxuntech.com/car_brand/202412/1734094126849.png",
"id": "167418"
},
{
"initial": "A",
"name": "阿尔特",
"logo": "http://dev.img.shuxuntech.com/car_brand/202412/1734094126963.png",
"id": "167415"
},
{
"initial": "A",
"name": "阿尔法·罗密欧",
"logo": "http://dev.img.shuxuntech.com/car_brand/202412/1734094128509.png",
"id": "3"
},
{
"initial": "A",
"name": "奥迪",
"logo": "http://dev.img.shuxuntech.com/car_brand/202412/1734094128597.png",
"id": "1"
},
{
"initial": "A",
"name": "阿斯顿·马丁",
"logo": "http://dev.img.shuxuntech.com/car_brand/202412/1734094128741.png",
"id": "2"
},
...
]
}
错误返回:
{
"code": "1",
"msg": "请输入合法的名字",
"isFee": 0,
"seqNo": null,
"data": null
}
返回字段描述:
| 字段名 | 类型 | 描述 |
|---|---|---|
| code | string | 错误码 |
| msg | string | 错误描述 |
| isFee | int | 是否计费(1:计费,0:不计费) |
| seqNo | string | 调用流水号 |
| data | object | 返回数据 |
data对象说明
| 字段名 | 类型 | 描述 |
|---|---|---|
| initial | string | 品牌首字母 |
| name | string | 品牌名称 |
| logo | string | 品牌logo |
| id | string | 品牌ID,根据该ID查车系信息 |
code错误码说明
| code | 说明 |
|---|---|
| 0 | 成功 |
| 1 | 参数错误 |
| 2 | 无记录 |
| 3 | 第三方服务异常 |
| 4 | 签名错误 |
| 5 | 余额不足 |
| 6 | 调用频率超限 |
| 7 | 账号停用 |
| 8 | 接口已停用 |
| 9 | 联系服务商开通接口权限 |
| 10 | ip不在白名单 |
| 11 | 系统异常 |
| 12 | 实名状态错误 |
| 99 | 其他异常,具体返回为准 |
示例代码
package com.shuxun.data.impl.demo;
import com.shuxun.common.core.util.HttpUtil;
import org.apache.commons.codec.digest.DigestUtils;
import java.util.HashMap;
import java.util.Map;
public class CarBrandQueryDemo {
private static final String APP_KEY = "您的appKey";
private static final String APP_SECRET = "您的appSecret";
private static final String API_URL = "https://api.shuxuntech.com/v1/car_brand/query";
public static void main(String[] args) {
String timestamp = System.currentTimeMillis()+"";
String sign = DigestUtils.sha256Hex(APP_KEY + timestamp + APP_SECRET);
Map<String, String> header = new HashMap<>(4);
header.put("appKey", APP_KEY);
header.put("timestamp", timestamp);
header.put("sign", sign);
Map<String, String> params = new HashMap<>(2);
// 工具类下载地址 https://file.shuxuntech.com/other/code/util.zip
String result = HttpUtil.get(API_URL, header, params);
System.out.println("返回结果="+result);
}
}
import requests
import time
import hashlib
appKey = "您的appKey"
appSecret = "您的appSecret"
url = "https://api.shuxuntech.com/v1/car_brand/query"
method = 'POST'
time = time.time()
timestamp = str(round(time * 1000))
print (timestamp)
tmp = appKey + timestamp + appSecret
sign = hashlib.sha256(tmp.encode("utf8")).hexdigest()
headers = {
'Content-Type': 'application/x-www-form-urlencoded; charset=UTF-8'
'appKey': appKey
'timestamp': timestamp
'sign': sign
}
params = {}
response = requests.post(url, data = params, headers = headers)
print (response.text)
<?php
$appKey = "您的appKey";
$appSecret= "您的appSecret";
$url = "https://api.shuxuntech.com/v1/car_brand/query";
$method = "POST";
$timestamp = getUnixTimestamp();
var_dump($timestamp);
$sign = hash('sha256',$appKey . $timestamp . $appSecret);
var_dump($sign);
$headers = array();
array_push($headers, "Content-Type" . ":" . "application/x-www-form-urlencoded; charset=UTF-8");
array_push($headers, "appKey" . ":" . $appKey);
array_push($headers, "timestamp" . ":" . $timestamp);
array_push($headers, "sign" . ":" . $sign);
$bodys = ;
$curl = curl_init();
curl_setopt($curl, CURLOPT_CUSTOMREQUEST, $method);
curl_setopt($curl, CURLOPT_URL, $url);
curl_setopt($curl, CURLOPT_HTTPHEADER, $headers);
curl_setopt($curl, CURLOPT_POSTFIELDS, $bodys);
curl_setopt($curl, CURLOPT_FAILONERROR, false);
curl_setopt($curl, CURLOPT_RETURNTRANSFER, true);
if (1 == strpos("$".$url, "https://")) {
curl_setopt($curl, CURLOPT_SSL_VERIFYPEER, false);
curl_setopt($curl, CURLOPT_SSL_VERIFYHOST, false);
}
var_dump(curl_exec($curl));
function getUnixTimestamp () {
list($s1, $s2) = explode(' ', microtime());
return sprintf('%.0f',(floatval($s1) + floatval($s2)) * 1000);
}
using System;
using System.IO;
using System.Net;
using System.Net.Security;
using System.Security.Cryptography;
using System.Security.Cryptography.X509Certificates;
using System.Text;
public class ApiDemo {
private const String url = "https://api.shuxuntech.com/v1/car_brand/query";
private const String method = "POST";
private const String appKey = "您的appKey";
private const String appSecret = "您的appSecret";
public static void Main(string[] args) {
TimeSpan ts = DateTime.UtcNow - new DateTime(1970, 1, 1, 0, 0, 0, 0);
String timestamp = Convert.ToInt64(ts.TotalMilliseconds).ToString();
String sign = SHA256(appKey + timestamp + appSecret);
HttpWebRequest httpRequest = null;
HttpWebResponse httpResponse = null;
httpRequest = (HttpWebRequest) WebRequest.CreateDefault(new Uri(url));
httpRequest.Method = method;
httpRequest.ContentType = "application/x-www-form-urlencoded; charset=UTF-8";
httpRequest.Headers.Add("appKey", appKey);
httpRequest.Headers.Add("timestamp", timestamp);
httpRequest.Headers.Add("sign", sign);
String params = "";
byte[] data = Encoding.UTF8.GetBytes(params);
using (Stream stream = httpRequest.GetRequestStream()) {
stream.Write(data, 0, data.Length);
}
httpResponse = (HttpWebResponse) httpRequest.GetResponse();
Console.WriteLine(httpResponse.StatusCode);
Stream st = httpResponse.GetResponseStream();
StreamReader reader = new StreamReader(st, Encoding.GetEncoding("utf-8"));
Console.WriteLine(reader.ReadToEnd());
}
public static string SHA256(string str) {
byte[] SHA256Data = Encoding.UTF8.GetBytes(str);
SHA256Managed Sha256 = new SHA256Managed();
byte[] by = Sha256.ComputeHash(SHA256Data);
return BitConverter.ToString(by).Replace("-", "").ToLower();
}
}
java
python
php
c#
接口名称:根据车品牌查车系
描述:输入车品牌ID,返回车系信息
请求地址 url:https://api.shuxuntech.com/v1/car_series/query
请求方式 method:get/post
参数:
| 名称 | 参数位置 | 类型 | 是否必填 | 说明 |
|---|---|---|---|---|
| appKey | head | string | 是 | 数勋分配appKey |
| timestamp | head | string | 是 | 当前时间的毫秒数 |
| sign | head | string | 是 | 签名,说明 |
| brandId | query | string | 是 | 车品牌ID |
签名算法说明:
数勋分配的appKey、当前unix时间毫秒数timestamp、数勋分配的appSecret、 按顺序拼接sha256加密得到sign,查看如下示例
appKey = aaa;
timestamp = 1682476904289;
appSecret = bbb;
sign = sha256(appKey+timestamp+appSecret)
正确返回:
{
"code": "0",
"msg": "成功",
"isFee": 1,
"seqNo": "zxn7vwtxriq56e16zkd3ehf1ggv230aw",
"data": [
{
"initial": "A", //品牌首字母
"name": "一汽奥迪", //子公司
"id": "219", //子公司ID
"list": [ // 子公司下车系列表
{
"name": "奥迪A3", //车系名称
"logo": "http://dev.img.shuxuntech.com/car_series/202412/1734096265662.png", //车系照片
"id": "220", //车系ID,根据该ID查车型
"fullName": "奥迪A3", //车系全称
"saleState": "在销" //销售状态
},
{
"name": "奥迪A4L",
"logo": "http://dev.img.shuxuntech.com/car_series/202412/1734096265662.png",
"id": "221",
"fullName": "奥迪A4L",
"saleState": "在销"
},
…
]
},
{
"initial": "A",
"name": "进口奥迪(进口)",
"id": "228",
"list": [
{
"name": "奥迪A1",
"logo": "http://dev.img.shuxuntech.com/car_series/202412/1734096285288.png",
"id": "229",
"fullName": "奥迪A1",
"saleState": "停销"
},
{
"name": "奥迪A3(进口)",
"logo": "http://dev.img.shuxuntech.com/car_series/202412/1734096285288.png",
"id": "230",
"fullName": "奥迪A3(进口)",
"saleState": "停销"
},
…
]
},
…
]
}
错误返回:
{
"code": "1",
"msg": "参数错误",
"isFee": 0,
"seqNo": null,
"data": null
}
返回字段描述:
| 字段名 | 类型 | 描述 |
|---|---|---|
| code | string | 错误码 |
| msg | string | 错误描述 |
| isFee | int | 是否计费(1:计费,0:不计费) |
| seqNo | string | 调用流水号 |
| data | array | 车品牌下子公司数组 |
data车品牌下子公司数组
| 字段名 | 类型 | 描述 |
|---|---|---|
| initial | string | 品牌首字母 |
| name | string | 子公司名称 |
| id | string | 子公司ID |
| list | array | 子公司下车系列表 |
list子公司下车系列表
| 字段名 | 类型 | 描述 |
|---|---|---|
| id | string | 车系ID,可根据该ID查车型 |
| name | string | 车系名称 |
| fullName | string | 车系全称 |
| saleState | string | 销售状态 |
| logo | string | 车系照片 |
code错误码说明
| code | 说明 |
|---|---|
| 0 | 成功 |
| 1 | 参数错误 |
| 2 | 无记录 |
| 3 | 第三方服务异常 |
| 4 | 签名错误 |
| 5 | 余额不足 |
| 6 | 调用频率超限 |
| 7 | 账号停用 |
| 8 | 接口已停用 |
| 9 | 联系服务商开通接口权限 |
| 10 | ip不在白名单 |
| 11 | 系统异常 |
| 12 | 实名状态错误 |
| 99 | 其他异常,具体返回为准 |
示例代码
package com.shuxun.data.impl.demo;
import com.shuxun.common.core.util.HttpUtil;
import org.apache.commons.codec.digest.DigestUtils;
import java.util.HashMap;
import java.util.Map;
public class CarSeriesQueryDemo {
private static final String APP_KEY = "您的appKey";
private static final String APP_SECRET = "您的appSecret";
private static final String API_URL = "https://api.shuxuntech.com/v1/car_series/query";
public static void main(String[] args) {
String timestamp = System.currentTimeMillis()+"";
String sign = DigestUtils.sha256Hex(APP_KEY + timestamp + APP_SECRET);
Map<String, String> header = new HashMap<>(4);
header.put("appKey", APP_KEY);
header.put("timestamp", timestamp);
header.put("sign", sign);
Map<String, String> params = new HashMap<>(2);
params.put("brandId", "");
// 工具类下载地址 https://file.shuxuntech.com/other/code/util.zip
String result = HttpUtil.get(API_URL, header, params);
System.out.println("返回结果="+result);
}
}
import requests
import time
import hashlib
appKey = "您的appKey"
appSecret = "您的appSecret"
url = "https://api.shuxuntech.com/v1/car_series/query"
method = 'POST'
time = time.time()
timestamp = str(round(time * 1000))
print (timestamp)
tmp = appKey + timestamp + appSecret
sign = hashlib.sha256(tmp.encode("utf8")).hexdigest()
headers = {
'Content-Type': 'application/x-www-form-urlencoded; charset=UTF-8'
'appKey': appKey
'timestamp': timestamp
'sign': sign
}
params = {}
params['brandId'] = ''
response = requests.post(url, data = params, headers = headers)
print (response.text)
<?php
$appKey = "您的appKey";
$appSecret= "您的appSecret";
$url = "https://api.shuxuntech.com/v1/car_series/query";
$method = "POST";
$timestamp = getUnixTimestamp();
var_dump($timestamp);
$sign = hash('sha256',$appKey . $timestamp . $appSecret);
var_dump($sign);
$headers = array();
array_push($headers, "Content-Type" . ":" . "application/x-www-form-urlencoded; charset=UTF-8");
array_push($headers, "appKey" . ":" . $appKey);
array_push($headers, "timestamp" . ":" . $timestamp);
array_push($headers, "sign" . ":" . $sign);
$brandId = "";
$bodys = "brandId=" . $brandId;
$curl = curl_init();
curl_setopt($curl, CURLOPT_CUSTOMREQUEST, $method);
curl_setopt($curl, CURLOPT_URL, $url);
curl_setopt($curl, CURLOPT_HTTPHEADER, $headers);
curl_setopt($curl, CURLOPT_POSTFIELDS, $bodys);
curl_setopt($curl, CURLOPT_FAILONERROR, false);
curl_setopt($curl, CURLOPT_RETURNTRANSFER, true);
if (1 == strpos("$".$url, "https://")) {
curl_setopt($curl, CURLOPT_SSL_VERIFYPEER, false);
curl_setopt($curl, CURLOPT_SSL_VERIFYHOST, false);
}
var_dump(curl_exec($curl));
function getUnixTimestamp () {
list($s1, $s2) = explode(' ', microtime());
return sprintf('%.0f',(floatval($s1) + floatval($s2)) * 1000);
}
using System;
using System.IO;
using System.Net;
using System.Net.Security;
using System.Security.Cryptography;
using System.Security.Cryptography.X509Certificates;
using System.Text;
public class ApiDemo {
private const String url = "https://api.shuxuntech.com/v1/car_series/query";
private const String method = "POST";
private const String appKey = "您的appKey";
private const String appSecret = "您的appSecret";
public static void Main(string[] args) {
TimeSpan ts = DateTime.UtcNow - new DateTime(1970, 1, 1, 0, 0, 0, 0);
String timestamp = Convert.ToInt64(ts.TotalMilliseconds).ToString();
String sign = SHA256(appKey + timestamp + appSecret);
HttpWebRequest httpRequest = null;
HttpWebResponse httpResponse = null;
httpRequest = (HttpWebRequest) WebRequest.CreateDefault(new Uri(url));
httpRequest.Method = method;
httpRequest.ContentType = "application/x-www-form-urlencoded; charset=UTF-8";
httpRequest.Headers.Add("appKey", appKey);
httpRequest.Headers.Add("timestamp", timestamp);
httpRequest.Headers.Add("sign", sign);
String brandId = "";
String params = "brandId=" + brandId;
byte[] data = Encoding.UTF8.GetBytes(params);
using (Stream stream = httpRequest.GetRequestStream()) {
stream.Write(data, 0, data.Length);
}
httpResponse = (HttpWebResponse) httpRequest.GetResponse();
Console.WriteLine(httpResponse.StatusCode);
Stream st = httpResponse.GetResponseStream();
StreamReader reader = new StreamReader(st, Encoding.GetEncoding("utf-8"));
Console.WriteLine(reader.ReadToEnd());
}
public static string SHA256(string str) {
byte[] SHA256Data = Encoding.UTF8.GetBytes(str);
SHA256Managed Sha256 = new SHA256Managed();
byte[] by = Sha256.ComputeHash(SHA256Data);
return BitConverter.ToString(by).Replace("-", "").ToLower();
}
}
java
python
php
c#
接口名称:根据车系查车型
描述:输入车系ID,查询车型信息
请求地址 url:https://api.shuxuntech.com/v1/car_type/query
请求方式 method:get/post
参数:
| 名称 | 参数位置 | 类型 | 是否必填 | 说明 |
|---|---|---|---|---|
| appKey | head | string | 是 | 数勋分配appKey |
| timestamp | head | string | 是 | unix时间毫秒值 |
| sign | head | string | 是 | 签名,说明 |
| seriesId | query | string | 是 | 车系ID |
| sort | query | string | 否 | 排序,默认不排序; year按年份、 yearr按年份逆序,productionstate按生产状态、 productionstater按生产状态逆序 |
签名算法说明:
数勋分配的appKey、当前unix时间毫秒值timestamp、数勋分配的appSecret、 按顺序拼接sha256加密得到sign,查看如下示例
appKey = aaa;
timestamp = 1682476904289;
appSecret = bbb;
sign = sha256(appKey+timestamp+appSecret)
正面返回:
{
"code": "0",
"msg": "成功",
"isFee": 1,
"seqNo": "b5y4kra9c5sdsy2xknnm1988qjwq2ccu",
"data": [
{
"initial": "A", //品牌首字母
"name": "奥迪A3",//车系名称
"id": "220", //车系ID
"list": [
{
"id": "2571", //车型ID,可根据该ID查车辆详情
"productionState": "停产", //生产状态
"listDate": "2016-04-06",// 上市年月
"yearType": "2016", //年款
"sizeType": "紧凑型车", //尺寸类型
"price": "18.49万", //价格
"name": "2016款 Sportback 35TFSI 进取型", //车型名称
"gearType": "双离合(DCT)", //变速箱类型
"logo": "http://dev.img.shuxuntech.com/car_type/202412/1734140910877.png", //车型图片
"displacement": "1.4T", //排量
"saleState": "停销" // 销售状态
},
{
"productionState": "停产",
"listDate": "2015-01-30",
"yearType": "2015",
"sizeType": "紧凑型车",
"price": "18.49万",
"name": "2015款 Sportback 35TFSI 手动 进取型",
"gearType": "手动(MT)",
"logo": "http://dev.img.shuxuntech.com/car_type/202412/1734140910877.png",
"displacement": "1.4T",
"id": "2577",
"saleState": "停销"
},
...
]
}
]
}
错误返回:
{
"code": "1",
"msg": "参数错误",
"isFee": 0,
"seqNo": null,
"data": null
}
返回字段描述:
| 字段名 | 类型 | 描述 |
|---|---|---|
| code | string | 错误码 |
| msg | string | 错误描述 |
| isFee | int | 是否计费(1:计费,0:不计费) |
| seqNo | string | 调用流水号 |
| data | object | 返回数据 |
data对象说明
| 字段名 | 类型 | 描述 |
|---|---|---|
| initial | string | 品牌首字母 |
| name | string | 车系名称 |
| id | string | 车系ID |
| list | array | 车型信息数组 |
list车型信息数组
| 字段名 | 类型 | 描述 |
|---|---|---|
| id | string | 车型ID,可根据该ID查车辆详情 |
| name | string | 车型名称 |
| productionState | string | 生产状态 |
| saleState | string | 销售状态 |
| listDate | string | 上市年月 |
| yearType | string | 年款 |
| sizeType | string | 尺寸类型 |
| gearType | string | 变速箱类型 |
| displacement | string | 排量 |
| logo | string | 车型照片 |
| price | string | 价格 |
code错误码说明
| code | 说明 |
|---|---|
| 0 | 成功 |
| 1 | 参数错误 |
| 2 | 无记录 |
| 3 | 第三方服务异常 |
| 4 | 签名错误 |
| 5 | 余额不足 |
| 6 | 调用频率超限 |
| 7 | 账号停用 |
| 8 | 接口已停用 |
| 9 | 联系服务商开通接口权限 |
| 10 | ip不在白名单 |
| 11 | 系统异常 |
| 12 | 实名状态错误 |
| 99 | 其他异常,具体返回为准 |
示例代码
package com.shuxun.data.impl.demo;
import com.shuxun.common.core.util.HttpUtil;
import org.apache.commons.codec.digest.DigestUtils;
import java.util.HashMap;
import java.util.Map;
public class CarTypeQueryDemo {
private static final String APP_KEY = "您的appKey";
private static final String APP_SECRET = "您的appSecret";
private static final String API_URL = "https://api.shuxuntech.com/v1/car_type/query";
public static void main(String[] args) {
String timestamp = System.currentTimeMillis()+"";
String sign = DigestUtils.sha256Hex(APP_KEY + timestamp + APP_SECRET);
Map<String, String> header = new HashMap<>(4);
header.put("appKey", APP_KEY);
header.put("timestamp", timestamp);
header.put("sign", sign);
Map<String, String> params = new HashMap<>(2);
params.put("seriesId", "");
params.put("sort", "");
// 工具类下载地址 https://file.shuxuntech.com/other/code/util.zip
String result = HttpUtil.get(API_URL, header, params);
System.out.println("返回结果="+result);
}
}
import requests
import time
import hashlib
appKey = "您的appKey"
appSecret = "您的appSecret"
url = "https://api.shuxuntech.com/v1/car_type/query"
method = 'POST'
time = time.time()
timestamp = str(round(time * 1000))
print (timestamp)
tmp = appKey + timestamp + appSecret
sign = hashlib.sha256(tmp.encode("utf8")).hexdigest()
headers = {
'Content-Type': 'application/x-www-form-urlencoded; charset=UTF-8'
'appKey': appKey
'timestamp': timestamp
'sign': sign
}
params = {}
params['seriesId'] = ''
params['sort'] = ''
response = requests.post(url, data = params, headers = headers)
print (response.text)
<?php
$appKey = "您的appKey";
$appSecret= "您的appSecret";
$url = "https://api.shuxuntech.com/v1/car_type/query";
$method = "POST";
$timestamp = getUnixTimestamp();
var_dump($timestamp);
$sign = hash('sha256',$appKey . $timestamp . $appSecret);
var_dump($sign);
$headers = array();
array_push($headers, "Content-Type" . ":" . "application/x-www-form-urlencoded; charset=UTF-8");
array_push($headers, "appKey" . ":" . $appKey);
array_push($headers, "timestamp" . ":" . $timestamp);
array_push($headers, "sign" . ":" . $sign);
$seriesId = "";
$sort = "";
$bodys = "seriesId=" . $seriesId . "&sort=" . $sort ;
$curl = curl_init();
curl_setopt($curl, CURLOPT_CUSTOMREQUEST, $method);
curl_setopt($curl, CURLOPT_URL, $url);
curl_setopt($curl, CURLOPT_HTTPHEADER, $headers);
curl_setopt($curl, CURLOPT_POSTFIELDS, $bodys);
curl_setopt($curl, CURLOPT_FAILONERROR, false);
curl_setopt($curl, CURLOPT_RETURNTRANSFER, true);
if (1 == strpos("$".$url, "https://")) {
curl_setopt($curl, CURLOPT_SSL_VERIFYPEER, false);
curl_setopt($curl, CURLOPT_SSL_VERIFYHOST, false);
}
var_dump(curl_exec($curl));
function getUnixTimestamp () {
list($s1, $s2) = explode(' ', microtime());
return sprintf('%.0f',(floatval($s1) + floatval($s2)) * 1000);
}
using System;
using System.IO;
using System.Net;
using System.Net.Security;
using System.Security.Cryptography;
using System.Security.Cryptography.X509Certificates;
using System.Text;
public class ApiDemo {
private const String url = "https://api.shuxuntech.com/v1/car_type/query";
private const String method = "POST";
private const String appKey = "您的appKey";
private const String appSecret = "您的appSecret";
public static void Main(string[] args) {
TimeSpan ts = DateTime.UtcNow - new DateTime(1970, 1, 1, 0, 0, 0, 0);
String timestamp = Convert.ToInt64(ts.TotalMilliseconds).ToString();
String sign = SHA256(appKey + timestamp + appSecret);
HttpWebRequest httpRequest = null;
HttpWebResponse httpResponse = null;
httpRequest = (HttpWebRequest) WebRequest.CreateDefault(new Uri(url));
httpRequest.Method = method;
httpRequest.ContentType = "application/x-www-form-urlencoded; charset=UTF-8";
httpRequest.Headers.Add("appKey", appKey);
httpRequest.Headers.Add("timestamp", timestamp);
httpRequest.Headers.Add("sign", sign);
String seriesId = "";
String sort = "";
String params = "seriesId=" + seriesId + "&sort=" + sort;
byte[] data = Encoding.UTF8.GetBytes(params);
using (Stream stream = httpRequest.GetRequestStream()) {
stream.Write(data, 0, data.Length);
}
httpResponse = (HttpWebResponse) httpRequest.GetResponse();
Console.WriteLine(httpResponse.StatusCode);
Stream st = httpResponse.GetResponseStream();
StreamReader reader = new StreamReader(st, Encoding.GetEncoding("utf-8"));
Console.WriteLine(reader.ReadToEnd());
}
public static string SHA256(string str) {
byte[] SHA256Data = Encoding.UTF8.GetBytes(str);
SHA256Managed Sha256 = new SHA256Managed();
byte[] by = Sha256.ComputeHash(SHA256Data);
return BitConverter.ToString(by).Replace("-", "").ToLower();
}
}
java
python
php
c#
接口名称:根据车型查车辆详情
描述:输入carid,返回车辆详情
请求地址 url:https://api.shuxuntech.com/v1/car_detail/query
请求方式 method:post
参数:
| 名称 | 参数位置 | 类型 | 是否必填 | 说明 |
|---|---|---|---|---|
| appKey | head | string | 是 | 数勋分配appKey |
| timestamp | head | string | 是 | unix时间毫秒值 |
| sign | head | string | 是 | 签名,说明 |
| carid | query | string | 是 | 车辆ID |
签名算法说明:
数勋分配的appKey、当前unix时间毫秒值timestamp、数勋分配的appSecret、 按顺序拼接sha256加密得到sign,查看如下示例
appKey = aaa;
timestamp = 1682476904289;
appSecret = bbb;
sign = sha256(appKey+timestamp+appSecret)
正面返回:
{
"code": "0",
"msg": "成功",
"isFee": 1,
"seqNo": "tpvo4l7il70zzayuyvf4yj38pwqbt7jm",
"data": {
"result": 1,
"info": {
"id": 2571,//车型ID
"name": "2016款 Sportback 35 TFSI 进取型", //名称
"parentname": "奥迪A3",//上级名称
"brandname": "奥迪",//品牌
"initial": "A",//首字母
"parentid": 220,//上级ID
"logo": "https://img.shuxuntech.com/vin_logo/202407/1722393364472.png",//LOGO
"price": "18.49万",//厂家指导价
"yeartype": "2016",//年款
"listdate": "2016.04",//上市年月
"productionstate": "停产",//生产状态
"salestate": "停销",//销售状态
"sizetype": "紧凑型车",//尺寸类型
"depth": 4,//深度 1品牌 2子公司 3车型 4具体车型
"displacement": "1.4T",//排量(L)
"displacement2": "1.4",//排量不带L
"gearnum": "7",//挡位个数
"geartype": "干式双离合变速箱(DCT)",//变速箱类型
"geartype2": 1,//变数箱类型 1自动 2手动
"seatnum": "5",//乘员人数(区间)(个)
"drivemode": "前置前驱",//驱动方式
"drivemode2": 2,//驱动模式 2两驱 4驱 6驱 8驱
"environmentalstandards": "国IV(国V)",//环保标准
"environmentalstandards2": "5",//环保标准 数字型
"compartnum": 2,//车厢数
"groupid": "2762",//组名id(汽配接口用)
"groupname": "A3",//组名(汽配接口用)
"basic": {//基本参数
"price": "18.49万",//厂家指导价
"saleprice": "暂无报价",//商家报价
"warrantypolicy": "● 三年或10万公里",//保修政策
"vechiletax": "",//车船税减免
"displacement": "1.4T",//排量(L)
"gearbox": "7挡干式双离合",//变速箱
"gearnum": "7",//挡位个数
"geartype": "干式双离合变速箱(DCT)",//变速箱类型
"comfuelconsumption": "5.5",//综合工况油耗(L/100km)
"userfuelconsumption": "-",//网友油耗(L/100km)
"officialaccelerationtime100": "8.4",//官方0-100公里加速时间(s)
"testaccelerationtime100": "-",//实测0-100公里加速时间(s)
"maxspeed": "213",//最高车速(km/h)
"seatnum": "5",//乘员人数(区间)(个)
"mixfuelconsumption": "5.5",//混合工况油耗[L/100km]
"lowchargefuelconsumption": null,//最低荷电状态油耗[L/100km]
"electricfuelconsumption": null,//电能当量燃料消耗量[L/100km]
"nedcfuelconsumption": "5.5",//NEDC综合油耗[L/100km]
"firstownerwarrantypolicy": null //首任车主质保政策
},
"body": {//车身
"color": "#C7C8CA,水晶银|#F6F6F6,冰川白|#D37201,萨摩亚橙|#374A4A,季风灰|#D91624,米萨诺红|#482807,白鲸棕|#59222B,希纳兹红|#000000,深黑|#FFFFFF,阿玛菲白|#3F6383,海南蓝|#462807,钛金米|#5D6159,莲花灰",//车身颜色
"len": "4319",//车长(mm)
"width": "1785",//车宽(mm)
"height": "1426",//车高(mm)
"wheelbase": "2629",//轴距(mm)
"fronttrack": "-",//前轮距(mm)
"reartrack": "-",//后轮距(mm)
"weight": "1340",//整备质量(kg)
"fullweight": "",//满载质量(kg)
"mingroundclearance": "-",//最小离地间隙(mm)
"approachangle": "",//接近角(°)
"departureangle": "",//离去角(°)
"luggagevolume": "380-1220",//行李厢容积(L)
"luggagemode": "",//行李厢盖开合方式
"luggageopenmode": "无",//行李厢打开方式
"inductionluggage": "",//感应行李厢
"doornum": "5",//车门数(个)
"rooftype": "",//车顶型式
"hoodtype": "",//车篷型式
"roofluggagerack": "-",//车顶行李箱架
"sportpackage": "-",//运动外观套件
"totalweight": null,//总质量(kg)
"ratedloadweight": null,//额定载质量(kg)
"loadweightfactor": null,//载质量利用系数
"rampangle": null,//通过角[°]
"maxwadingdepth": null,//最大涉水深度[mm]
"minturndiameter": null,//最小转弯直径[m]
"electricluggage": "无",//电动行李厢
"bodytype": "两厢车",//车身型式
"fronttrunkvolume": null,//前备厢容积[L]
"dragcoefficient": null,//风阻系数[Cd]
"trunkpositionmemory": null//电动后备厢位置记忆
},
"engine": {//发动机
"position": "",//发动机位置
"model": "",//产品型号
"displacement": "1.4T",//排量(L)
"displacementml": "1395",//排量(mL)
"intakeform": "涡轮增压",//进气形式
"cylinderarrangetype": "L",//气缸排列型式
"cylindernum": "4",//气缸数(个)
"valvetrain": "4",//每缸气门数(个)
"valvestructure": "DOHC",//气门结构
"compressionratio": "-",//压缩比
"bore": "-",//缸径(mm)
"stroke": "-",//行程(mm)
"maxhorsepower": "150",//最大马力(Ps)
"maxpower": "110",//最大功率(kW)
"maxpowerspeed": "5000-6000",//最大功率转速(rpm)
"maxtorque": "250",//最大扭矩(Nm)
"maxtorquespeed": "1750-3000",//最大扭矩转速(rpm)
"fueltype": "汽油",//燃料类型
"fuelgrade": "95号",//燃油标号
"fuelmethod": "直喷",//供油方式
"fueltankcapacity": "50",//燃油箱容积(L)
"cylinderheadmaterial": "铝合金",//缸盖材料
"cylinderbodymaterial": "铝合金",//缸体材料
"environmentalstandards": "国IV(国V)",//环保标准
"startstopsystem": "●",//启停系统
},
"electricmotor": {//电动机
"frontmodel": null,//前电动机型号
"rearmodel": null,//后电动机型号
"frontbrand": null,//前电动机品牌
"rearbrand": null,//后电动机品牌
"motorpower": null,//电动机总功率[kW]
"motortorque": null,//电动机总扭矩[N.m]
"integratedpower": null,//系统综合功率[kW]
"integratedtorque": null,//系统综合扭矩[N.m]
"frontmaxpower": null,//前电动机最大功率[kW]
"frontmaxtorque": null,//前电动机最大扭矩[N.m]
"rearmaxpower": null,//后电动机最大功率[kW]
"rearmaxtorque": null,//后电动机最大扭矩[N.m]
"batterycapacity": null,//电池容量[kwh]
"powerconsumption": null,//耗电量[kwh/100km]
"maxmileage": null,//最大续航里程[km]
"batterywarranty": null,//电池组质保
"batteryfastchargetime": null,//电池快充充电时间
"batteryslowchargetime": null,//电池慢充充电时间
"cltcmaxmileage": null,//CLTC纯电续航[km]
"nedcmaxmileage": null,//NEDC最大续航里程[km]
"wltcmaxmileage": null,//WLTC纯电续航里程[km]
"wltccomprehensivemileage": null,//WLTC综合续航[km]
"cltccomprehensivemileage": null,//CLTC综合续航[km]
"motornum": null,//驱动电机数
"motorlayout": null,//电机布局
"motortype": null,//电机类型
"motormaxhorsepower": null,//电动机总马力[Ps]
"batterytype": null,//电池类型
"batterybrand": null,//电芯品牌
"highvoltagecharging": null,//高压快充平台
"fastchargingpercent": null,//快充电量[%]
"slowchargingpercent": null,//慢充电量[%]
"slowchargingpower": null,//慢充功率[kW]
"fastchargingpower": null,//快充功率[kW]
"batteryenergydensity": null,//电池能量密度[Wh/kg]
"threeelectricwarranty": null,//三电系统质保
"fastcharging": null,//快充功能
"highvoltagefastcharging": null,//高压快充
"chargingpileprice": null,//充电桩价格[元]
"slowchargingportlocation": null,//慢充接口位置
"fastchargingportlocation": null,//快充接口位置
"externalacdischargepower": null//对外交流放电功率[kW]
},
"gearbox": {//变速箱
"gearbox": "7挡干式双离合",//变速箱
"gearnum": "7",//挡位个数
"geartype": "干式双离合变速箱(DCT)",//变速箱类型
"shiftpaddles": "",//换挡拨片
"gearboxmodel": null,//变速箱型号
"fourwheeldrive": null,//四驱形式
"centraldifferential": null,//中央差速器结构
"gearshifting": null//换挡形式
},
"chassissteer": {//底盘转向
"bodystructure": "承载式",//车体结构
"powersteering": "● 电动助力",//转向助力
"frontbraketype": "● 通风盘式",//前制动类型
"rearbraketype": "● 盘式",//后制动类型
"parkingbraketype": "● 电子驻车",//驻车制动类型
"drivemode": "前置前驱",//驱动方式
"airsuspension": "-",//空气悬挂
"adjustablesuspension": "无",//可调悬挂
"frontsuspensiontype": "● 麦弗逊式独立悬架",//前悬挂类型
"rearsuspensiontype": "● 多连杆式独立悬架",//后悬挂类型
"centerdifferentiallock": "-",//中央差速器锁
"chassistype": null,//底盘类别
"axlenum": null,//轴数
"axleload": null,//轴荷
"leafspringnum": null,//钢板弹簧片数(前/后)
"frontsuspension": null,//前悬(mm)
"rearsuspension": null//后悬
},
"wheelbrake": {//车轮制动
"fronttiresize": "● 205/55 R16",//前轮胎规格
"reartiresize": "● 205/55 R16",//后轮胎规格
"sparetiretype": "● ",//备胎类型非全尺寸
"hubmaterial": "● ",//轮毂材料铝合金
"fronttrack": "-",//前轮距(mm)
"reartrack": "-",//后轮距(mm)
"tirenum": null,//轮胎个数
"frontbraketype": "●", //前制动类型通风盘式
"rearbraketype": "●", //后制动类型盘式
"parkingbraketype": "●", //驻车制动类型电子驻车
"sparetireplacement": null//备胎放置方式
},
"activesafety": {//主动安全
"abs": "●",//刹车防抱死(ABS)
"ebd": "●",//电子制动力分配系统(EBD)
"brakeassist": "●",//刹车辅助(EBA/BAS/BA/EVA等)
"tractioncontrol": "●",//牵引力控制(ASR/TCS/TRC/ATC等)
"esp": "●",//动态稳定控制系统(ESP)
"tirepressuremonitoring": "●",//胎压监测装置
"safetybeltprompt": "●",//安全带未系提示
"childseatfixdevice": "●",//儿童安全座椅固定装置
"ldws": "○",//车道偏离预警系统
"activebraking": "○",//主动刹车/主动安全系统
"fatiguereminder": null,//疲劳提醒
"dooropeningwarning": null,//DOW开门预警
"forwardcollisionwarning": null,//前方碰撞预警
"rearcollisionwarning": null,//后方碰撞预警
"drivingrecorder": null,//车载行车记录仪
"roadrescue": null,//紧急道路救援
"sentrymode": null,//哨兵模式/千里眼
"lowspeedwarning": null//低速行车警告
},
"passivesafety": {//被动安全
"airbagdrivingposition": "主●",//驾驶位安全气囊
"airbagfrontpassenger": "副●",//副驾驶位安全气囊
"airbagfrontside": "前●",//前排侧安全气囊
"airbagfronthead": null,//前排头部气囊(气帘)
"airbagknee": "● 主驾膝部气囊",//膝部气囊
"airbagrearside": "后○",//后排侧安全气囊
"airbagrearhead": "前● / 后●",//后排头部气囊(气帘)
"airbagfrontcenter": null,//前排中间气囊
"passivepedestrianprotection": null//被动行人保护
},
"4wdoffroad": {//四驱/越野
"centerdifferentiallock": "-",//中央差速器锁
"differentiallocktype": null,//限滑差速器/差速锁
"lowspeedfourwheeldrive": null,//低速四驱
"creepmode": null,//蠕行模式
"tankturn": null,//坦克转弯
"towhook": null,//拖挂钩
"trailerpowerport": null//拖车取电口
},
"drivingcontrol": {//驾驶操控
"drivemodechoose": null,//驾驶模式选择
"startstopsystem": "●",//启停系统
"automaticparking": "●",//自动驻车
"hillstartassist": "●",//上坡辅助
"hilldescent": "-",//陡坡缓降
"variablesteeringratio": null,//可变转向比
"adjustablesuspension": null,//可调悬挂
"airsuspension": "-",//空气悬挂
"towingmode": null,//拖挂模式
"energyrecovery": null//能量回收系统
},
"drivinghardware": {//驾驶硬件
"frontparkingradar": "前○",//泊车雷达(车前)
"reversingradar": "后●",//倒车雷达(车后)
"reverseimage": "○",//倒车影像倒车影像
"frontperceptioncamera": null,//前方感知摄像头
"camerasnum": null,//摄像头数量
"camerasnumincar": null,//车内摄像头数量
"ultrasonicradarsnum": "100",//超声波雷达数量
"millimeterwaveradarnum": null,//毫米波雷达数量
"maxdetectiondistanceahead": null,//前方最大探测距离
"transparentchassis": "-",//透明底盘/540度影像
"assisteddrivingchip": null,//辅助驾驶芯片
"totalchipcomputingpower": null,//芯片总算力
"frontperceptioncamerapixel": null,//前方感知摄像头像素
"environmentalawarenesscamerapixel": null,//环境感知摄像头像素
"surroundviewcamerapixel": null,//环视摄像头像素
"lidarbrand": null,//激光雷达品牌
"lidarmodel": null,//激光雷达型号
"lidarnum": null,//激光雷达数量
"lidarlinenum": null,//激光雷达线数
"lidardetectiondistance": null,//激光雷达10%反射率探测距离
"lidarpointcloudnum": null//激光雷达点云数量
},
"drivingfunction": {//驾驶功能
"cruisecontrol": "○ 定速巡航,○ 自适应巡航",//巡航系统
"driverassistancesystem": null,//辅助驾驶系统
"driverassistancelevel": null,//辅助驾驶等级
"reversesidewarning": null,//倒车车侧预警系统
"satellitenavigationsystem": "○",//卫星导航系统
"navigationtrafficinfo": null,//导航路况信息显示
"mapbrand": "○ 选配",//地图品牌
"parallelaid": "○",//并线辅助
"lanekeep": "○",//车道保持
"lanecentering": null,//车道居中保持
"roadtrafficsignrecog": null,//道路交通标识识别
"automaticparkingintoplace": "○",//自动泊车入位
"remoteparking": null,//遥控泊车
"memoryparking": null,//记忆泊车
"trackingreverse": null,//循迹倒车
"autolanechangeassist": null,//自动变道辅助
"autorampentryexit": null,//匝道自动驶出/入
"trafficlightrecog": null,//信号灯识别
"remotesummon": null,//远程召唤
"handsoffdetection": null,//方向盘离手检测
"startreminder": null,//起步提醒
"autodrivingsection": null,//自动驾驶辅助路段
"highprecisionmap": null//高精地图
},
"appearanceantitheft": {//外观/防盗
"rearwing": null,//尾翼/扰流板
"hubmaterial": "● 铝合金",//轮毂材料
"electricpulldoor": null,//电动吸合门
"framelessdoor": null,//无框设计车门
"electricluggage": null,//电动行李厢
"trunkpositionmemory": null,//电动后备厢位置记忆
"centrallocking": "●",//中控门锁
"remotekey": "● 遥控钥匙",//钥匙类型
"keylessentry": "○",//无钥匙启动系统
"activeclosedgrille": null,//主动闭合式进气格栅
"remotecontrol": null,//远程遥控功能
"batterypreheating": null,//电池预加热
"discharge": null,//对外放电
"appearancekit": null,//外观套件
"engineantitheft": "●",//发动机电子防盗
"roofluggagerack": "-",//车顶行李箱架
"sidepedal": null,//车侧脚踏板
"hiddendoorhandle": null//隐藏电动门把手
},
"exteriorlight": {//车外灯光
"lowbeamtype": "● 卤素,○ 氙气",//近光灯光源
"headlighttype": "● 卤素,○ 氙气",//远光灯光源
"lightingfeature": null,//灯光特色功能
"daytimerunninglight": "○",//日间行车灯
"adaptivehighandlowbeam": "○",//自适应远近光
"headlightautomaticopen": "○",//自动头灯
"lightsteeringassist": "-",//转向辅助灯
"frontfoglight": "●",//前雾灯
"adjustableheadlight": "●",//大灯高度可调
"headlightdelayoff": "-",//前大灯延时关闭
"headlightrainfogmode": null,//前大灯雨雾模式
"headlightcleaning": null,//大灯清洗装置
"turnheadlight": null,//转向头灯
"scenelightlanguage": null//场景灯语
},
"sunroofglass": {//天窗/玻璃
"skylightopeningmode": "○ 电动天窗",//天窗开合方式
"frontelectricwindow": "●",//前电动车窗
"rearelectricwindow": "●",//后电动车窗
"onetouchwindowlifting": null,//车窗一键升降功能
"antipinchwindow": "●",//车窗防夹手功能
"privacyglass": "●",//隐私玻璃
"sunvisormirror": "●",//遮阳板化妆镜
"rearwiper": "●",//后雨刷器
"sensingwiper": "○",//感应雨刷
"sidewindowsoundproofglass": null,//侧窗多层隔音玻璃
"rearwindowsunshade": "-",//后窗遮阳帘
"heatedwaternozzle": null//可加热喷水嘴
},
"externalrearmirror": {//外后视镜
"electricadjustment": null,//外后视镜功能
"electricfolding": null,//电动折叠
"rearviewmirrormemory": null,//后视镜记忆
"heatedrearviewmirror": null,//后视镜加热
"reversingtiltdown": null,//倒车自动下翻
"foldinglockingcar": null//锁车自动折叠
},
"screensystem": {//屏幕/系统
"consolelcdscreen": "●",//中控台液晶屏
"lcdscreensize": null,//液晶仪表尺寸
"consolelcdscreenresolution": null,//中控屏幕尺寸
"consolelcdscreenpixeldensity": null,//中控屏幕像素密度
"bluetooth": "○",//蓝牙系统
"phoneconnect": null,//手机互联(Carplay&Android)
"voicecontrol": null,//语音控制
"assistantwakeupword": null,//语音助手唤醒词
"wakeupwordfree": null,//语音免唤醒词
"wakeupregion": null,//语音分区域唤醒识别
"continuousspeech": null,//语音连续识别
"seeandsay": null,//可见即可说
"voiceprintrecognition": null,//声纹识别
"carapp": null,//车载APP应用
"intelligentsystem": null,//车载智能系统
"carintelligentchip": null,//车机智能芯片
"rearlcdscreen": null,//后排液晶屏
"rearlcdscreensize": null,//后排液晶屏幕尺寸
"rearscreensnum": null,//后排多媒体屏幕数量
"rearmultimediacontrol": null,//后排控制多媒体
"undercenterscreensize": null,//中控下屏幕尺寸
"carsystemmemory": null,//车机系统内存[GB]
"carsystemstorage": null,//车机系统存储[GB]
"multifingerscreen": null,//多指飞屏操控
"entertainmentscreensize": null,//副驾娱乐屏尺寸
"passengerscreentype": null,//副驾屏幕类型
"facialrecognition": null,//面部识别
"privacyshield": null//隐私声盾
},
"intelligentconfig": {//智能化配置
"internetofvehicle": null,//车联网
"4g": null,//4G/5G网络
"ota": null,//OTA升级
"wifi": null,//Wi-Fi热点
"appremote": null,//手机APP远程功能
"simulatesoundwave": null,//模拟声浪
"ktv": null,//车载KTV
"activenoisecancellation": null//主动降噪
},
"incarcharge": {//车内充电
"chargingport": "● ",//多媒体/充电接口
"usbnum": null,//USB/Type-C接口数量
"usbmaxchargingpower": null,//USB/Type-C最大充电功率
"wirelesscharge": null,//手机无线充电功能
"phonewirelesschargingpower": null,//手机无线充电功率
"luggagepowersocket": null,//行李厢12V电源接口
"powersupply": null//220V/230V电源
},
"seat": {//座椅配置
"sportseat": "-",//运动座椅
"seatmaterial": "● 织物,○ 真皮",//座椅材料
"seatheightadjustment": "",//座椅高低调节
"driverseatadjustmentmode": "● 前后调节,● 靠背调节,● 高低调节",//驾驶座座椅调节方式
"auxiliaryseatadjustmentmode": "● 前后调节,● 靠背调节",//副驾驶座椅调节方式
"driverseatlumbarsupportadjustment": "",//驾驶座腰部支撑调节
"driverseatshouldersupportadjustment": "",//驾驶座肩部支撑调节
"frontseatheadrestadjustment": "",//前座椅头枕调节
"rearseatadjustmentmode": "",//后排座椅调节方式
"rearseatreclineproportion": "",//后排座位放倒比例
"rearseatangleadjustment": "",//后排座椅角度调节
"frontseatcenterarmrest": "有",//前座中央扶手
"rearseatcenterarmrest": "前● / 后●",//后座中央扶手
"seatventilation": "",//座椅通风
"seatheating": "○//座椅加热加热",
"seatmassage": "",//座椅按摩功能
"electricseatmemory": "",//电动座椅记忆
"childseatfixdevice": "●",//儿童安全座椅固定装置
"thirdrowseat": "无",//第三排座椅
"driverseatelectricadjustment": "-",//主座椅电动调节
"auxiliaryseatelectricadjustment": "-",//副座椅电动调节
"secondrowseatelectricadjustment": "无",//第二排座椅电动调节
"frontseatfunction": "无",//前排座椅功能
"rearseatfunction": "无",//后排座椅功能
"secondrowseatadjustment": "主○ / 副○",//第二排座椅调节方式
"seatadjustablebutton": null,//副驾驶位后排可调节按钮
"secondrowseatfunctions": null,//第二排座椅功能
"seatrecliningmethod": "● 比例放倒"//座椅放倒方式
},
"soundinteriorlight": {//音响/车内灯光
"audiobrand": "○ Bang & Olufsen",//音响品牌
"speakernum": "● 8-9喇叭,○ 10-11喇叭,○ ",//扬声器数量
"dolbyatmos": null,//杜比全景声
"interiorairlight": null,//车内氛围灯
"readinglight": "-",//阅读灯
"activeinteriorairlight": null//主动式环境氛围灯
},
"aircondrefrigerator": {//空调/冰箱
"airconditioningcontrolmode": "● 手动空调,○ 自动空调",//空调控制方式
"tempzonecontrol": "○",//温度分区控制
"rearairconditioning": "-",//后排独立空调
"reardischargeoutlet": "○",//后排出风口
"airconditioning": "",//空气调节/花粉过滤
"airpurifyingdevice": "-",//车内空气净化装置
"carrefrigerator": "-",//车载冰箱
"frontairconditioning": "● 手动空调",//前排空调
"fragrance": "无",//香氛系统
"heatpumpairconditioner": null //热泵空调
},
"featuredconfig": {//特色配置
"configname": null,//配置选项
"configcontent": null//配置内容
},
"color": {//车身颜色
"color": "#C7C8CA,水晶银|#F6F6F6,冰川白|#D37201,萨摩亚橙|#374A4A,季风灰|#D91624,米萨诺红|#482807,白鲸棕|#59222B,希纳兹红|#000000,深黑|#FFFFFF,阿玛菲白|#3F6383,海南蓝|#462807,钛金米|#5D6159,莲花灰",//车身颜色
"interiorcolor": "#000000,黑色|#000000/#A8AAA9,黒色/钛灰色|#000000/#DBCBA7,黑色/开士米色|#000000/#DE7838,黑色/卡普里橙|#000000/#544540,黑色/栗棕色"//内饰颜色
},
"optionalpackage": {//选装包
"packagename": "前排座椅电动调整和腰部支撑",//选装配置名称
"packagecontent": "包含:前排座椅电动调节、腰部支撑 ○ 6000元 选配"//选装内容
}
}
}
}
错误返回:
{
"code": "1",
"msg": "参数错误",
"isFee": 0,
"seqNo": null,
"data": null
}
返回字段描述:
| 字段名 | 类型 | 描述 |
|---|---|---|
| code | string | 错误码 |
| msg | string | 错误描述 |
| isFee | int | 是否计费(1:计费,0:不计费) |
| seqNo | string | 调用流水号 |
| data | object | 返回数据 |
data对象说明
| 字段名 | 类型 | 描述 |
|---|---|---|
| result | int | 查询结果,1:查询成功,2:无记录 |
| info | object | 车辆信息,注释请看返回示例 |
code错误码说明
| code | 说明 |
|---|---|
| 0 | 成功 |
| 1 | 参数错误 |
| 2 | 无记录 |
| 3 | 第三方服务异常 |
| 4 | 签名错误 |
| 5 | 余额不足 |
| 6 | 调用频率超限 |
| 7 | 账号停用 |
| 8 | 接口已停用 |
| 9 | 联系服务商开通接口权限 |
| 10 | ip不在白名单 |
| 11 | 系统异常 |
| 12 | 实名状态错误 |
| 99 | 其他异常,具体返回为准 |
示例代码
package com.shuxun.data.impl.demo;
import com.shuxun.common.core.util.HttpUtil;
import org.apache.commons.codec.digest.DigestUtils;
import java.util.HashMap;
import java.util.Map;
public class VinQueryDemo {
private static final String APP_KEY = "您的appKey";
private static final String APP_SECRET = "您的appSecret";
private static final String API_URL = "https://api.shuxuntech.com/v1/car_detail/query";
public static void main(String[] args) {
String timestamp = System.currentTimeMillis()+"";
String sign = DigestUtils.sha256Hex(APP_KEY + timestamp + APP_SECRET);
Map<String, String> header = new HashMap<>(4);
header.put("appKey", APP_KEY);
header.put("timestamp", timestamp);
header.put("sign", sign);
Map<String, String> params = new HashMap<>(2);
params.put("carid", "");
// 工具类下载地址 https://file.shuxuntech.com/other/code/util.zip
String result = HttpUtil.get(API_URL, header, params);
System.out.println("返回结果="+result);
}
}
import requests
import time
import hashlib
appKey = "您的appKey"
appSecret = "您的appSecret"
url = "https://api.shuxuntech.com/v1/car_detail/query"
method = 'POST'
time = time.time()
timestamp = str(round(time * 1000))
print (timestamp)
tmp = appKey + timestamp + appSecret
sign = hashlib.sha256(tmp.encode("utf8")).hexdigest()
headers = {
'Content-Type': 'application/x-www-form-urlencoded; charset=UTF-8'
'appKey': appKey
'timestamp': timestamp
'sign': sign
}
params = {}
params['carid'] = ''
response = requests.post(url, data = params, headers = headers)
print (response.text)
<?php
$appKey = "您的appKey";
$appSecret= "您的appSecret";
$url = "https://api.shuxuntech.com/v1/car_detail/query";
$method = "POST";
$timestamp = getUnixTimestamp();
var_dump($timestamp);
$sign = hash('sha256',$appKey . $timestamp . $appSecret);
var_dump($sign);
$headers = array();
array_push($headers, "Content-Type" . ":" . "application/x-www-form-urlencoded; charset=UTF-8");
array_push($headers, "appKey" . ":" . $appKey);
array_push($headers, "timestamp" . ":" . $timestamp);
array_push($headers, "sign" . ":" . $sign);
$carid = "";
$bodys = "carid=" . $carid;
$curl = curl_init();
curl_setopt($curl, CURLOPT_CUSTOMREQUEST, $method);
curl_setopt($curl, CURLOPT_URL, $url);
curl_setopt($curl, CURLOPT_HTTPHEADER, $headers);
curl_setopt($curl, CURLOPT_POSTFIELDS, $bodys);
curl_setopt($curl, CURLOPT_FAILONERROR, false);
curl_setopt($curl, CURLOPT_RETURNTRANSFER, true);
if (1 == strpos("$".$url, "https://")) {
curl_setopt($curl, CURLOPT_SSL_VERIFYPEER, false);
curl_setopt($curl, CURLOPT_SSL_VERIFYHOST, false);
}
var_dump(curl_exec($curl));
function getUnixTimestamp () {
list($s1, $s2) = explode(' ', microtime());
return sprintf('%.0f',(floatval($s1) + floatval($s2)) * 1000);
}
using System;
using System.IO;
using System.Net;
using System.Net.Security;
using System.Security.Cryptography;
using System.Security.Cryptography.X509Certificates;
using System.Text;
public class ApiDemo {
private const String url = "https://api.shuxuntech.com/v1/car_detail/query";
private const String method = "POST";
private const String appKey = "您的appKey";
private const String appSecret = "您的appSecret";
public static void Main(string[] args) {
TimeSpan ts = DateTime.UtcNow - new DateTime(1970, 1, 1, 0, 0, 0, 0);
String timestamp = Convert.ToInt64(ts.TotalMilliseconds).ToString();
String sign = SHA256(appKey + timestamp + appSecret);
HttpWebRequest httpRequest = null;
HttpWebResponse httpResponse = null;
httpRequest = (HttpWebRequest) WebRequest.CreateDefault(new Uri(url));
httpRequest.Method = method;
httpRequest.ContentType = "application/x-www-form-urlencoded; charset=UTF-8";
httpRequest.Headers.Add("appKey", appKey);
httpRequest.Headers.Add("timestamp", timestamp);
httpRequest.Headers.Add("sign", sign);
String carid = "";
String params = "carid=" + carid;
byte[] data = Encoding.UTF8.GetBytes(params);
using (Stream stream = httpRequest.GetRequestStream()) {
stream.Write(data, 0, data.Length);
}
httpResponse = (HttpWebResponse) httpRequest.GetResponse();
Console.WriteLine(httpResponse.StatusCode);
Stream st = httpResponse.GetResponseStream();
StreamReader reader = new StreamReader(st, Encoding.GetEncoding("utf-8"));
Console.WriteLine(reader.ReadToEnd());
}
public static string SHA256(string str) {
byte[] SHA256Data = Encoding.UTF8.GetBytes(str);
SHA256Managed Sha256 = new SHA256Managed();
byte[] by = Sha256.ComputeHash(SHA256Data);
return BitConverter.ToString(by).Replace("-", "").ToLower();
}
}
java
python
php
c#
车品牌查询
根据车品牌查车系
根据车系查车型
根据车型查车辆详情
产品详情
API文档
产品价格










