<?php
require_once 'curl.func.php';
$appkey = 'your_appkey_here';//你的appkey
$company = '小米科技有限责任公司'; //utf-8 以下三项任选一个
$creditno = '91110108551385082Q';
$legalperson= '雷军';
$url = "https://api.jisuapi.com/enterpriseverify3/query?company=小米科技有限责任公司&creditno=91110108551385082Q&legalperson=雷&appkey=$appkey";
$result = curlOpen($url, ['ssl'=>true]);
$jsonarr = json_decode($result, true);
//exit(var_dump($jsonarr));
if($jsonarr['status'] != 0)
{
echo $jsonarr['msg'];
exit();
}
$result = $jsonarr['result'];
var_dump($result);
import requests
appkey = 'your_appkey_here'
company = '小米科技有限责任公司'
creditno = '91110108551385082Q'
legalperson = '雷军'
url = f"https://api.jisuapi.com/enterpriseverify3/query?company={company}&creditno={creditno}&legalperson={legalperson}&appkey={appkey}"
result = requests.get(url).text
jsonarr = requests.get(url).json()
if jsonarr['status'] != 0:
print(jsonarr['msg'])
exit()
result = jsonarr['result']
print(result)
// 1. 安装 axios(如果未安装)
// 在终端执行: npm install axios
const axios = require('axios');
// 2. 直接配置参数
const url = 'https://api.jisuapi.com/enterpriseverify3/query';
const params = {
appkey: 'your_appkey_here', // 替换成你的真实appkey
company: '小米科技有限责任公司',
creditno: '91110108551385082Q',
legalperson: '雷军',
};
// 3. 立即发送请求
axios.get(url, { params })
.then(response => {
// 检查API业务状态码
if (response.data.status !== 0) {
console.error('API返回错误:', response.data.status+"-"+response.data.msg);
return;
}
// 输出结果
if (response.data.result.verifystatus === 1) console.log('全匹配!');
else if (response.data.result.verifystatus === 2) console.log('公司名和法人均不匹配!');
else if (response.data.result.verifystatus === 12) console.log('公司匹配,法人不匹配!');
else if (response.data.result.verifystatus === 13) console.log('公司不匹配,法人匹配!');
else if (response.data.result.verifystatus === -1) console.log('无法核验!');
})
.catch(error => {
// 统一错误处理
console.error('请求失败!');
});