WHOIS查询

接口信息
API ID: 3
总调用: 59
添加时间: 2026-05-12
更新时间: 2026-07-08
访问权限: 公开访问(无需密钥)
请求信息
请求地址:
https://api.xkzil.com/API/tools/web-whois.php
示例地址:
https://api.xkzil.com/API/tools/web-whois.php?domain=www.xkzhi.cn
请求参数
参数名 类型 必填 说明 示例值
domain string 必填 查询域名 -
type string json/text -
状态码说明
状态码 说明
200 请求成功,服务器已成功处理了请求。
403 服务器拒绝请求。这可能是由于缺少必要的认证凭据(如API密钥)或权限不足。
404 请求的资源未找到。请检查您的请求地址是否正确。
429 请求过于频繁。您已超出速率限制,请稍后再试。
500 服务器内部错误。服务器在执行请求时遇到了问题。
返回示例
响应格式
{
  "code": 200,
  "msg": "查询成功",
  "data": {
    "domain": "xkzhi.cn",
    "original_domain": "www.xkzhi.cn",
    "registrar": "腾讯云计算(北京)有限责任公司",
    "creation_date": "2024-04-09 22:12:32",
    "expiration_date": "",
    "updated_date": "",
    "name_servers": [
      "veromca.dnspod.net",
      "gavin.dnspod.net"
    ],
    "status": [
      "ok"
    ],
    "registrant": "临颍县星空知软件开发工作室(个体工商户)",
    "registrant_organization": "",
    "registrant_country": "",
    "registrant_email": "1397403557@qq.com",
    "is_registered": true,
    "days_until_expiry": 0,
    "has_privacy_protection": false,
    "privacy_protection_text": "未开启隐私保护",
    "raw_text": "Domain Name: xkzhi.cn\nROID: 20240409s10001s56870483-cn\nDomain Status: ok\nRegistrant: 临颍县星空知软件开发工作室(个体工商户)\nRegistrant Contact Email: 1397403557@qq.com\nSponsoring Registrar: 腾讯云计算(北京)有限责任公司\nName Server: veromca.dnspod.net\nName Server: gavin.dnspod.net\nRegistration Time: 2024-04-09 22:12:32\nExpiration Time: 2027-04-09 22:12:32\nDNSSEC: unsigned\n"
  },
  "api_source": "星空知API:api.xkzil.com"
}
在线测试
返回结果
此处将显示接口返回结果...
调用示例
<?php
$url = 'https://api.xkzil.com/API/tools/web-whois.php';
$params = ['domain' => 'YOUR_VALUE', 'type' => 'YOUR_VALUE', ];
$url .= '?' . http_build_query($params);
$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, $url);
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
$response = curl_exec($ch);
curl_close($ch);
echo $response;
?>
import requests
url = "https://api.xkzil.com/API/tools/web-whois.php"
params = {
    'domain': 'YOUR_VALUE',
    'type': 'YOUR_VALUE',
}
response = requests.get(url, params=params)
print(response.text)
const url = new URL('https://api.xkzil.com/API/tools/web-whois.php');
const params = {
    'domain': 'YOUR_VALUE',
    'type': 'YOUR_VALUE',
};
Object.keys(params).forEach(key => url.searchParams.append(key, params[key]));
fetch(url)
    .then(response => response.text())
    .then(data => console.log(data))
    .catch(error => console.error('Error:', error));
const axios = require('axios');
const url = 'https://api.xkzil.com/API/tools/web-whois.php';
const params = {
  'domain': 'YOUR_VALUE',
  'type': 'YOUR_VALUE',};
axios.get(url, { params })
  .then(res => console.log(res.data))
  .catch(err => console.error(err));
package main

import (
    "fmt"
    "io"
    "net/http"
    "net/url"
)

func main() {
    baseURL := "https://api.xkzil.com/API/tools/web-whois.php"
    params := url.Values{}
    params.Add("domain", "YOUR_VALUE")
    params.Add("type", "YOUR_VALUE")
    reqURL := baseURL + "?" + params.Encode()
    resp, err := http.Get(reqURL)
    if err != nil {
        panic(err)
    }
    defer resp.Body.Close()
    body, _ := io.ReadAll(resp.Body)
    fmt.Println(string(body))
}
import java.net.URI;
import java.net.http.HttpClient;
import java.net.http.HttpRequest;
import java.net.http.HttpResponse;

public class Main {
    public static void main(String[] args) throws Exception {
        String url = "https://api.xkzil.com/API/tools/web-whois.php" + "?" +
            "domain=YOUR_VALUE" + "&" +\n            "type=YOUR_VALUE";
        HttpClient client = HttpClient.newHttpClient();
        HttpRequest request = HttpRequest.newBuilder()
            .uri(URI.create(url))
            .GET()
            .build();
        HttpResponse<String> response = client.send(request,
            HttpResponse.BodyHandlers.ofString());
        System.out.println(response.body());
    }
}
using System.Net;

var client = new HttpClient();
var url = "https://api.xkzil.com/API/tools/web-whois.php" + "?" +
    string.Join("&",
        new (string, string)[] {
            ("domain", "YOUR_VALUE"),
            ("type", "YOUR_VALUE"),
        }.Select(p => $"{WebUtility.UrlEncode(p.Item1)}={WebUtility.UrlEncode(p.Item2)}")
    );
var response = await client.GetStringAsync(url);
Console.WriteLine(response);
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <curl/curl.h>

int main(void) {
    CURL *curl = curl_easy_init();
    char *url = "https://api.xkzil.com/API/tools/web-whois.php" + '?' +
        "domain=YOUR_VALUE&type=YOUR_VALUE";
    if(curl) {
        curl_easy_setopt(curl, CURLOPT_URL, url);
        curl_easy_setopt(curl, CURLOPT_FOLLOWLOCATION, 1L);
        int res = curl_easy_perform(curl);
        curl_easy_cleanup(curl);
    }
    return 0;
}
#include <iostream>
#include <httplib.h>

int main() {
    httplib::Client cli("https://api.xkzil.com");
    httplib::Params params{
        {"domain", "YOUR_VALUE"},
        {"type", "YOUR_VALUE"},
    };
    auto res = cli.Get("/API/tools/web-whois.php", params);
    if(res) std::cout << res->body << std::endl;
    return 0;
}
.版本 2

.子程序 _按钮_调用_被单击

.局部变量 网络操作对象, 网络操作类
.局部变量 返回文本, 文本型
.局部变量 完整网址, 文本型

完整网址 = "https://api.xkzil.com/API/tools/web-whois.php" + "?"
完整网址 = 完整网址 + " + "&" + "domain" + "=" + "YOUR_VALUE"
完整网址 = 完整网址 + "type" + "=" + "YOUR_VALUE"
返回文本 = 网络操作对象.网页_获取(完整网址)

调试输出(返回文本)
API 接口列表