开发者参考

DNS 传播检查器 API 文档

DNS 传播检查器 API 文档: 跨 13 个全球 DNS 服务器检查 DNS 记录传播。对于验证迁移后的 DNS 更改、排除 DNS 问题故障或监控 TTL 过期至关重要。服务器跨越北美、欧洲、亚太和其他地区以提供全面的覆盖。

DNS 传播检查器

跨 13 个全球 DNS 服务器检查 DNS 记录传播。对于验证迁移后的 DNS 更改、排除 DNS 问题故障或监控 TTL 过期至关重要。服务器跨越北美、欧洲、亚太和其他地区以提供全面的覆盖。

GET /v1/dns/propagation

查询参数

参数类型说明
domain 必需 string 要检查的域名(例如 "example.com" 或 "subdomain.example.com")
type 可选 string 记录类型:A、AAAA、CNAME、MX、TXT、NS、SOA(默认值:A)
expected 可选 string 预期值以验证传播(例如,新 IP 地址)

响应字段

字段类型说明
propagation_percentagenumber返回预期值的服务器百分比(0-100)
fully_propagatedboolean如果所有服务器返回一致的值,则为真
consistentboolean如果所有成功的响应具有相同的值,则为真
unique_valuesarray跨服务器看到的所有唯一记录值
resultsarray每台服务器的结果,包括位置、记录、TTL、响应时间

请求示例

# Check A record propagation
curl "https://domscan.net/v1/dns/propagation?domain=example.com&type=A"

# Check MX record with expected value
curl "https://domscan.net/v1/dns/propagation?domain=example.com&type=MX&expected=mail.example.com"
const url = new URL("https://domscan.net/v1/dns/propagation");
url.searchParams.set("domain", "example.com");
url.searchParams.set("type", "A");

const response = await fetch(url);
const data = await response.json();

console.log(`Propagation: ${data.propagation_percentage}%`);
console.log(`Fully propagated: ${data.fully_propagated}`);

// Check which servers are still showing old values
data.results
  .filter(r => !r.success || r.records[0] !== data.expected)
  .forEach(r => console.log(`${r.server.name}: ${r.records}`));
import requests

response = requests.get(
    "https://domscan.net/v1/dns/propagation",
    params={"domain": "example.com", "type": "A"}
)
data = response.json()

print(f"Propagation: {data['propagation_percentage']}%")
print(f"Fully propagated: {data['fully_propagated']}")

# Show servers with different values
for result in data['results']:
    print(f"{result['server']['name']}: {result['records']}")
package main

import (
    "encoding/json"
    "fmt"
    "net/http"
)

func main() {
    resp, _ := http.Get("https://domscan.net/v1/dns/propagation?domain=example.com&type=A")
    defer resp.Body.Close()

    var data map[string]interface{}
    json.NewDecoder(resp.Body).Decode(&data)

    fmt.Printf("Propagation: %.0f%%\n", data["propagation_percentage"])
    fmt.Printf("Fully propagated: %v\n", data["fully_propagated"])
}
require 'net/http'
require 'json'

uri = URI("https://domscan.net/v1/dns/propagation?domain=example.com&type=A")
response = Net::HTTP.get_response(uri)
data = JSON.parse(response.body)

puts "Propagation: #{data['propagation_percentage']}%"
puts "Fully propagated: #{data['fully_propagated']}"

响应示例

{
  "domain": "example.com",
  "record_type": "A",
  "propagation_percentage": 100,
  "fully_propagated": true,
  "consistent": true,
  "unique_values": ["93.184.216.34"],
  "results": [
    {
      "server": {
        "name": "Cloudflare",
        "ip": "1.1.1.1",
        "location": "Global Anycast"
      },
      "success": true,
      "records": ["93.184.216.34"],
      "ttl": 86400,
      "response_time_ms": 12
    },
    {
      "server": {
        "name": "Google",
        "ip": "8.8.8.8",
        "location": "Global Anycast"
      },
      "success": true,
      "records": ["93.184.216.34"],
      "ttl": 86400,
      "response_time_ms": 15
    }
  ],
  "summary": {
    "total_servers": 13,
    "successful": 13,
    "failed": 0
  }
}
GET /v1/dns/servers

获取用于传播检查的 DNS 服务器列表。返回所有 13 个全球服务器及其位置和 IP 地址。

响应示例

{
  "servers": [
    {"name": "Cloudflare", "ip": "1.1.1.1", "location": "Global Anycast"},
    {"name": "Google", "ip": "8.8.8.8", "location": "Global Anycast"},
    {"name": "Quad9", "ip": "9.9.9.9", "location": "Global Anycast"},
    {"name": "OpenDNS", "ip": "208.67.222.222", "location": "US"},
    {"name": "Comodo", "ip": "8.26.56.26", "location": "US"}
  ],
  "total": 13
}

响应字段

字段 类型
servers[] object[]
servers[] object
servers[].name string
servers[].location string
servers[].country string
servers[].ip string
servers[].provider string
total integer
GET /v1/dns/history

查询参数

参数 类型 必需
domain string 必需
type string 可选
from string 可选
to string 可选
limit integer 可选

响应字段

字段 类型
domain string
history[] object[]
history[] object
history[].date string
history[].record_type string
history[].changes[] object[]
history[].changes[] object
history[].changes[].action string
history[].changes[].value string
current_records object
first_seen string | null
last_seen string | null
total_changes integer
record_types_tracked[] string[]
beta_notice string
meta object
meta.note string
meta.data_source string

请求示例

curl -H "X-API-Key: $DOMSCAN_API_KEY" "https://domscan.net/v1/dns/history?domain=example.com&type=A&from=2026-01-01&to=2026-04-15&limit=10"

响应示例

{
  "domain": "example.com",
  "history": [
    {
      "date": "2026-04-13",
      "record_type": "A",
      "changes": [
        {
          "action": "added",
          "value": "104.20.23.154"
        },
        {
          "action": "added",
          "value": "172.66.147.243"
        },
        {
          "action": "removed",
          "value": "104.18.26.120"
        }
      ]
    }
  ],
  "current_records": {
    "A": [
      "104.20.23.154",
      "172.66.147.243"
    ]
  },
  "first_seen": "2026-01-01",
  "last_seen": "2026-04-13",
  "total_changes": 3,
  "record_types_tracked": [
    "A"
  ],
  "beta_notice": "This endpoint is in beta. History data accumulates from API usage over time and does not include external historical sources.",
  "meta": {
    "note": "History data recorded from prior API lookups.",
    "data_source": "internal"
  }
}

被出色公司的人们使用

VercelLLM PulseOLXCasa ModernaPipeCal.comBeehiivSnykTogglRemoteSprigDeel