建筑企业工程项目信息查询
请求Header:
| 名称 | 值 | |
|---|---|---|
| Content-Type | application/x-www-form-urlencoded |
请求参数说明:
| 名称 | 必填 | 类型 | 说明 | |
|---|---|---|---|---|
| key | 是 | string | 在个人中心->我的数据,接口名称上方查看 | |
| pageSize | 否 | Number | 每页条数(默认20条,最大20条) | |
| keyword | 是 | String | 搜索关键字(公司名称、公司id、注册号或社会统一信用代码) | |
| pageNum | 否 | Number | 当前页数(默认第1页) |
请求代码示例:
curl -k -i "https://v.juhe.cn/opens/App/bqProject/query?key=key&pageSize=&keyword=xxx&pageNum=1"
<?php
/**
* 1655-建筑企业工程项目信息查询 - 代码参考(根据实际业务情况修改)
*/
// 基本参数配置
$apiUrl = "https://v.juhe.cn/opens/App/bqProject/query"; // 接口请求URL
$method = "GET"; // 接口请求方式
$headers = ["Content-Type: application/x-www-form-urlencoded"]; // 接口请求header
$apiKey = "您申请的调用APIkey"; // 在个人中心->我的数据,接口名称上方查看
// 接口请求入参配置
$requestParams = [
'key' => $apiKey,
'pageSize'=> '',
'keyword'=> 'xxx',
'pageNum'=> '1',
];
$requestParamsStr = http_build_query($requestParams);
// 发起接口网络请求
$curl = curl_init();
curl_setopt($curl, CURLOPT_CUSTOMREQUEST, $method);
curl_setopt($curl, CURLOPT_URL, $apiUrl . '?' . $requestParamsStr);
curl_setopt($curl, CURLOPT_HTTPHEADER, $headers);
curl_setopt($curl, CURLOPT_FAILONERROR, false);
curl_setopt($curl, CURLOPT_RETURNTRANSFER, true);
if (1 == strpos("$" . $apiUrl, "https://")) {
curl_setopt($curl, CURLOPT_SSL_VERIFYPEER, false);
curl_setopt($curl, CURLOPT_SSL_VERIFYHOST, false);
}
$response = curl_exec($curl);
$httpInfo = curl_getinfo($curl);
curl_close($curl);
// 解析响应结果
$responseResult = json_decode($response, true);
if ($responseResult) {
// 网络请求成功。可依据业务逻辑和接口文档说明自行处理。
var_dump($responseResult);
} else {
// 网络异常等因素,解析结果异常。可依据业务逻辑自行处理。
// var_dump($httpInfo);
var_dump("请求异常");
}
import requests
# 1655-建筑企业工程项目信息查询 - 代码参考(根据实际业务情况修改)
# 基本参数配置
apiUrl = 'https://v.juhe.cn/opens/App/bqProject/query' # 接口请求URL
apiKey = '您申请的调用APIkey' # 在个人中心->我的数据,接口名称上方查看
# 接口请求入参配置
requestParams = {
'key': apiKey,
'pageSize': '',
'keyword': 'xxx',
'pageNum': '1',
}
# 发起接口网络请求
response = requests.get(apiUrl, params=requestParams)
# 解析响应结果
if response.status_code == 200:
responseResult = response.json()
# 网络请求成功。可依据业务逻辑和接口文档说明自行处理。
print(responseResult)
else:
# 网络异常等因素,解析结果异常。可依据业务逻辑自行处理。
print('请求异常')
package main
import (
"encoding/json"
"fmt"
"net/http"
"net/url"
)
func main() {
// 基本参数配置
apiUrl := "https://v.juhe.cn/opens/App/bqProject/query"
apiKey := "您申请的调用APIkey"
// 接口请求入参配置
requestParams := url.Values{}
requestParams.Set("key", apiKey)
requestParams.Set("pageSize", "")
requestParams.Set("keyword", "xxx")
requestParams.Set("pageNum", "1")
// 发起接口网络请求
resp, err := http.Get(apiUrl + "?" + requestParams.Encode())
if err != nil {
fmt.Println("网络请求异常:", err)
return
}
defer resp.Body.Close()
var responseResult map[string]interface{}
err = json.NewDecoder(resp.Body).Decode(&responseResult)
if err != nil {
fmt.Println("解析响应结果异常:", err)
return
}
fmt.Println(responseResult)
}
using System;
using System.Net;
using Newtonsoft.Json;
using System.Collections.Generic;
using System.Linq;
namespace Common_API_Test.Test_Demo
{
class Csharp_get
{
static void Main(string[] args)
{
string url = "https://v.juhe.cn/opens/App/bqProject/query";
string apiKey = "您申请的调用APIkey";
Dictionary<string, string> data = new Dictionary<string, string>();
data.Add("key", apiKey);
data.Add( "pageSize", "");
data.Add( "keyword", "xxx");
data.Add( "pageNum", "1");
using (WebClient client = new WebClient())
{
string fullUrl = url + "?" + string.Join("&", data.Select(x => x.Key + "=" + x.Value));
try
{
string responseContent = client.DownloadString(fullUrl);
dynamic responseData = JsonConvert.DeserializeObject(responseContent);
if (responseData != null)
{
Console.WriteLine("Return Code: " + responseData["error_code"]);
Console.WriteLine("Return Message: " + responseData["reason"]);
}
else
{
Console.WriteLine("json解析异常!");
}
}
catch (Exception)
{
Console.WriteLine("请检查其它错误");
}
}
}
}
}
const axios = require('axios'); // npm install axios
// 基本参数配置
const apiUrl = 'https://v.juhe.cn/opens/App/bqProject/query'; // 接口请求URL
const apiKey = '您申请的调用APIkey'; // 在个人中心->我的数据,接口名称上方查看
// 接口请求入参配置
const requestParams = {
key: apiKey,
pageSize: '',
keyword: 'xxx',
pageNum: '1',
};
// 发起接口网络请求
axios.get(apiUrl, {params: requestParams})
.then(response => {
// 解析响应结果
if (response.status === 200) {
const responseResult = response.data;
// 网络请求成功。可依据业务逻辑和接口文档说明自行处理。
console.log(responseResult);
} else {
// 网络异常等因素,解析结果异常。可依据业务逻辑自行处理。
console.log('请求异常');
}
})
.catch(error => {
// 网络请求失败,可以根据实际情况进行处理
console.log('网络请求失败:', error);
});
package cn.juhe.test;
import java.io.BufferedReader;
import java.io.InputStreamReader;
import java.net.URL;
import java.net.URLEncoder;
import java.nio.charset.StandardCharsets;
import java.util.HashMap;
import java.util.Map;
import java.util.stream.Collectors;
public class JavaGet {
public static void main(String[] args) throws Exception {
String apiKey = "你申请的key";
String apiUrl = "https://v.juhe.cn/opens/App/bqProject/query";
HashMap<String, String> map = new HashMap<>();
map.put("key", apiKey);
map.put("pageSize", "");
map.put("keyword", "xxx");
map.put("pageNum", "1");
URL url = new URL(String.format("%s?%s", apiUrl, params(map)));
BufferedReader in = new BufferedReader(new InputStreamReader((url.openConnection()).getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
response.append(inputLine);
}
in.close();
System.out.println(response);
}
public static String params(Map<String, String> map) {
return map.entrySet().stream()
.map(entry -> {
try {
return entry.getKey() + "=" + URLEncoder.encode(entry.getValue(), StandardCharsets.UTF_8.toString());
} catch (Exception e) {
e.printStackTrace();
return entry.getKey() + "=" + entry.getValue();
}
})
.collect(Collectors.joining("&"));
}
}
// 基本参数配置
NSString *apiUrl = @"https://v.juhe.cn/opens/App/bqProject/query"; // 接口请求URL
NSString *apiKey = @"您申请的调用APIkey"; // 在个人中心->我的数据,接口名称上方查看
// 接口请求入参配置
NSDictionary *requestParams = @{
@"key": apiKey,
@"pageSize": @"",
@"keyword": @"xxx",
@"pageNum": @"1",
};
// 发起接口网络请求
NSURLComponents *components = [NSURLComponents componentsWithString:apiUrl];
NSMutableArray *queryItems = [NSMutableArray array];
[requestParams enumerateKeysAndObjectsUsingBlock:^(NSString *key, NSString *value, BOOL *stop) {
[queryItems addObject:[NSURLQueryItem queryItemWithName:key value:value]];
}];
components.queryItems = queryItems;
NSURL *url = components.URL;
NSMutableURLRequest *request = [NSMutableURLRequest requestWithURL:url];
NSURLSession *session = [NSURLSession sharedSession];
NSURLSessionDataTask *task = [session dataTaskWithRequest:request completionHandler:^(NSData *data, NSURLResponse *response, NSError *error) {
if (error) {
// 网络请求异常处理
NSLog(@"请求异常");
} else {
NSError *jsonError;
NSDictionary *responseResult = [NSJSONSerialization JSONObjectWithData:data options:0 error:&jsonError];
if (!jsonError) {
// 网络请求成功处理
// NSLog(@"%@", [responseResult objectForKey:@"error_code"]);
NSLog(@"%@", responseResult);
} else {
// 解析结果异常处理
NSLog(@"解析结果异常");
}
}
}];
[task resume];
返回参数说明:
| 名称 | 类型 | 说明 | |
|---|---|---|---|
| total | Number | 总数 | |
| pageNum | Number | 当前页 | |
| pageSize | Number | 每页条数 | |
| filter | Array | 无用 | |
| error_code | string | 状态码 | |
| reason | string | 说明 | |
| result | object | 结果 | |
JSON返回示例:JSON在线格式化工具 >
{
"result": {
"filter": [],
"total": 783,
"pageSize": 20,
"pageNum": 1,
"items": [
{
"proNum": "3101010806049901",
"proType": "其他",
"buildCompany": "上海福星实业有限公司",
"buildCompanyId": 752207064,
"businessId": "5d43b94c478d18a66bdd61f6",
"proName": "7号会所装修",
"base": "上海市-市辖区-黄浦区"
},
{
"proNum": "3101050909289901",
"proType": "其他",
"buildCompany": "上海市长宁区住宅建设管理中心",
"buildCompanyId": null,
"businessId": "5d43b959478d18a66bdd622f",
"proName": "长宁区迎世博600天行动计划旧居住小区二次供水改造工程",
"base": "上海市-市辖区-长宁区"
},
{
"proNum": "3101051104209901",
"proType": "其他",
"buildCompany": "史泰博(上海)有限公司",
"buildCompanyId": 22866905,
"businessId": "5d43b933478d18a66bdd6134",
"proName": "史泰博新办公室装修工程",
"base": "上海市-市辖区-长宁区"
},
{
"proNum": "3101151409049901",
"proType": "其他",
"buildCompany": "上海世邦机器有限公司",
"buildCompanyId": 36909989,
"businessId": "5d41717ff23e4be3bb6d1f5a",
"proName": "上海世邦高端矿机研制项目",
"base": "上海市-市辖区-浦东新区"
},
{
"proNum": "3608811807230001",
"proType": "市政工程",
"buildCompany": "井冈山市城市建设投资开发有限公司",
"buildCompanyId": 2340266006,
"businessId": "5d437449478d18a66bdbafb7",
"proName": "井冈山市红军大道新建工程",
"base": "江西省-吉安市-井冈山市"
},
{
"proNum": "3610291712240201",
"proType": "市政工程",
"buildCompany": "东乡县红星垦殖场",
"buildCompanyId": null,
"businessId": "5d43b144478d18a66bdd29a5",
"proName": "东乡县红星垦殖场生活垃圾填埋处理场工程",
"base": "江西省-抚州市-东乡县"
},
{
"proNum": "3611231708010102",
"proType": "房屋建筑工程",
"buildCompany": "玉山县城市建设综合开发公司",
"buildCompanyId": 1091149429,
"businessId": "5d4122f3f23e4be3bb6adad5",
"proName": "银海御庭1#商住楼",
"base": "江西省-上饶市-玉山县"
},
{
"proNum": "3715241904270001",
"proType": "房屋建筑工程",
"buildCompany": "东阿阿胶股份有限公司",
"buildCompanyId": 181541556,
"businessId": "5d42d993478d18a66bd8592e",
"proName": "养生体验酒店",
"base": "山东省-聊城市-东阿县"
},
{
"proNum": "4101011704260102",
"proType": "房屋建筑工程",
"buildCompany": "郑州港荣实业有限公司",
"buildCompanyId": 197100796,
"businessId": "5d411dc2f23e4be3bb6ab562",
"proName": "大运城白鹭源五号地块住宅项目施工",
"base": "河南省-郑州市"
},
{
"proNum": "4101011707060101",
"proType": "房屋建筑工程",
"buildCompany": "河南省郑州新区建设投资有限公司",
"buildCompanyId": 254532118,
"businessId": "5d43668f478d18a66bdb4b2d",
"proName": "郑东新区合村并城祭城南安置区项目八标",
"base": "河南省-郑州市"
},
{
"proNum": "4101011707210201",
"proType": "市政工程",
"buildCompany": "郑州新郑综合保税区(郑州航空港区)建设投资有限公司",
"buildCompanyId": 421586359,
"businessId": "5d42d1d6478d18a66bd81e57",
"proName": "郑州新郑综合保税区(郑州航空港区)跨南水北调总干渠桥梁工程",
"base": "河南省-郑州市"
},
{
"proNum": "4101011712300201",
"proType": "市政工程",
"buildCompany": "郑州市公共交通总公司",
"buildCompanyId": 461593970,
"businessId": "5d43b0ac478d18a66bdd24f9",
"proName": "郑州市公共交通总公司商都路郑港大道公交场站",
"base": "河南省-郑州市"
},
{
"proNum": "4101011808160025",
"proType": "市政工程",
"buildCompany": "郑州市城乡建设委员会",
"buildCompanyId": 4453197807,
"businessId": "5d42cbfa478d18a66bd7f4cc",
"proName": "开元路(江山路-天河路)排水管道改造工程",
"base": "河南省-郑州市"
},
{
"proNum": "4101011808160027",
"proType": "市政工程",
"buildCompany": "郑州市市政工程管理处",
"buildCompanyId": 782277093,
"businessId": "5d43b0ca478d18a66bdd25cc",
"proName": "盛豪帝湖国际广场硬质铺装工程",
"base": "河南省-郑州市"
},
{
"proNum": "4101011808160053",
"proType": "市政工程",
"buildCompany": "郑州市建设投资集团有限公司",
"buildCompanyId": 139882462,
"businessId": "5d411dbdf23e4be3bb6ab539",
"proName": "月季公园休闲广场硬质铺装工程",
"base": "河南省-郑州市"
},
{
"proNum": "4101021508180101",
"proType": "房屋建筑工程",
"buildCompany": "河南运昌置业有限公司",
"buildCompanyId": 726418160,
"businessId": "5d408e4bf23e4be3bb66d838",
"proName": "和昌湾景公寓",
"base": "河南省-郑州市-中原区"
},
{
"proNum": "4101021601080101",
"proType": "房屋建筑工程",
"buildCompany": "郑州华瑞紫韵置业有限公司",
"buildCompanyId": 1549217442,
"businessId": "5d411dc1f23e4be3bb6ab55c",
"proName": "华瑞紫韵城丽园",
"base": "河南省-郑州市-中原区"
},
{
"proNum": "4101021601080102",
"proType": "房屋建筑工程",
"buildCompany": "郑州华瑞紫韵置业有限公司",
"buildCompanyId": 1549217442,
"businessId": "5d40aeeaf23e4be3bb67d23b",
"proName": "华瑞紫韵城景园",
"base": "河南省-郑州市-中原区"
},
{
"proNum": "4101021608220101",
"proType": "房屋建筑工程",
"buildCompany": "河南荣威置业有限公司",
"buildCompanyId": 1468116601,
"businessId": "5d408c6ef23e4be3bb66cab4",
"proName": "永威微棠大厦",
"base": "河南省-郑州市-中原区"
},
{
"proNum": "4101021608220102",
"proType": "房屋建筑工程",
"buildCompany": "河南荣威置业有限公司",
"buildCompanyId": 1468116601,
"businessId": "5d408c6ff23e4be3bb66cabe",
"proName": "永威金桂苑",
"base": "河南省-郑州市-中原区"
}
]
},
"reason": "success",
"error_code": 0
}
服务级错误码参照(error_code):
| 错误码 | 说明 | |
|---|---|---|
| 265400 | 网络超时,请稍后再试 | |
| 265401 | 参数缺失 | |
| 265402 | 参数不合法 | |
| 265403 | 请求失败 | |
| 265404 | 查询无结果 | |
| 265405 | 未知错误 |
系统级错误码参照:
| 错误码 | 说明 | 旧版本(resultcode) | |
|---|---|---|---|
| 10001 | 错误的请求KEY | 101 | |
| 10002 | 该KEY无请求权限 | 102 | |
| 10003 | KEY过期 | 103 | |
| 10004 | 错误的OPENID | 104 | |
| 10005 | 应用未审核超时,请提交认证 | 105 | |
| 10007 | 未知的请求源 | 107 | |
| 10008 | 被禁止的IP | 108 | |
| 10009 | 被禁止的KEY | 109 | |
| 10011 | 当前IP请求超过限制 | 111 | |
| 10012 | 请求超过次数限制 | 112 | |
| 10013 | 测试KEY超过请求限制 | 113 | |
| 10014 | 系统内部异常(调用充值类业务时,请务必联系客服或通过订单查询接口检测订单,避免造成损失) | 114 | |
| 10020 | 接口维护 | 120 | |
| 10021 | 接口停用 | 121 |
错误码格式说明(示例:200201):
| 2 | 002 | 01 | |
|---|---|---|---|
| 服务级错误(1为系统级错误) | 服务模块代码(即数据ID) | 具体错误代码 |
接口文档下载
苏公网安备 32059002001776号