接口地址
https://www.chuangxinwu.cn/public/api/dns_api.php?domain=www.chuangxinwu.cn
接口状态
正常 (HTTP 200) 上次检测:2026-05-18 01:16:09
📝 接口描述
============ 调用方式 ============
1. 查询域名解析(默认):/dns_api.php?domain=www.baidu.com
2. 查询指定记录类型:/dns_api.php?domain=www.baidu.com&type=A
3. 获取详细信息:/dns_api.php?domain=www.baidu.com&detail=1
4. JSONP调用:/dns_api.php?domain=www.baidu.com&callback=jsonpCallback
5. 批量查询多个域名:/dns_api.php?domains=baidu.com,qq.com,taobao.com
📋 请求示例
【基础请求】
GET https://www.chuangxinwu.cn/public/api/dns_api.php?domain=www.chuangxinwu.cn
【请求头】
Content-Type: application/json
Accept: application/json
【参数说明】
GET请求参数通过URL传递:
https://www.chuangxinwu.cn/public/api/dns_api.php?domain=www.chuangxinwu.cn?参数名1=参数值1&参数名2=参数值2
【调用示例】
# cURL
curl -X GET 'https://www.chuangxinwu.cn/public/api/dns_api.php?domain=www.chuangxinwu.cn' \
-H 'Content-Type: application/json'
# JavaScript (Fetch)
fetch('https://www.chuangxinwu.cn/public/api/dns_api.php?domain=www.chuangxinwu.cn', {
method: 'GET',
headers: { 'Content-Type': 'application/json' }
})
.then(res => res.json())
.then(data => console.log(data));
# PHP (cURL)
<?php
$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, 'https://www.chuangxinwu.cn/public/api/dns_api.php?domain=www.chuangxinwu.cn');
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_CUSTOMREQUEST, 'GET');
curl_setopt($ch, CURLOPT_HTTPHEADER, ['Content-Type: application/json']);
$response = curl_exec($ch);
curl_close($ch);
echo $response;
?>
# Python (requests)
import requests
url = 'https://www.chuangxinwu.cn/public/api/dns_api.php?domain=www.chuangxinwu.cn'
response = requests.get(url)
print(response.json())
📤 真实返回示例
{
"code": 200,
"success": true,
"domain": "www.chuangxinwu.cn",
"type": "A",
"data": [
{
"host": "www.chuangxinwu.cn",
"ttl": 900,
"type": "A",
"ip": "154.12.23.73"
}
],
"total": 1,
"message": "查询成功"
}
🔧 JavaScript (Fetch)
fetch('/api/proxy.php?url=https%3A%2F%2Fwww.chuangxinwu.cn%2Fpublic%2Fapi%2Fdns_api.php%3Fdomain%3Dwww.chuangxinwu.cn', {
method: 'GET',
headers: { 'Content-Type': 'application/json' }
})
.then(res => res.json())
.then(data => console.log(data))
.catch(err => console.error(err));
🐘 PHP (cURL)
<?php
$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, 'https://www.chuangxinwu.cn/public/api/dns_api.php?domain=www.chuangxinwu.cn');
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_CUSTOMREQUEST, 'GET');
$response = curl_exec($ch);
curl_close($ch);
echo $response;
?>
📡 Python (requests)
import requests
url = 'https://www.chuangxinwu.cn/public/api/dns_api.php?domain=www.chuangxinwu.cn'
response = requests.request('GET', url)
print(response.json())