Skip to content
ToolsOnDuty - free online tools
Browse documentation

Reference / Network

Network API

16 endpoints for network workflows. Every call requires bearer authentication and uses the standard ToolsOnDuty response envelope.

Try it

Runs a real request from your browser to your own ToolsOnDuty account. Your key is only kept in this page and is never stored.

POST/v1/network/port1 credit / call

Port number lookup

Identify the range and common service associated with a TCP/UDP port.

ParameterTypeRequiredDescription
portnumberYesInteger port from 0 to 65535.

Request

curl -X POST https://toolsonduty.com/api/v1/network/port \
  -H "Authorization: ******" \
  -H "Content-Type: application/json" \
  -d '{"port":443}'

Response

{
  "ok": true,
  "data": {
    "port": 443,
    "range": "well-known",
    "known": true,
    "service": "HTTPS",
    "protocol": "TCP"
  }
}
POST/v1/network/caa-parse1 credit / call

CAA record parser

Parse CAA flags, critical bit, tag and certificate-authority value.

ParameterTypeRequiredDescription
recordstringYesCAA record value.

Request

curl -X POST https://toolsonduty.com/api/v1/network/caa-parse \
  -H "Authorization: ******" \
  -H "Content-Type: application/json" \
  -d '{"record":"0 issue \"letsencrypt.org\""}'

Response

{
  "ok": true,
  "data": {
    "flags": 0,
    "critical": false,
    "tag": "issue",
    "value": "letsencrypt.org"
  }
}
POST/v1/network/srv-parse1 credit / call

SRV record parser

Parse and range-check SRV priority, weight, port and target.

ParameterTypeRequiredDescription
recordstringYesSRV record value: priority weight port target.

Request

curl -X POST https://toolsonduty.com/api/v1/network/srv-parse \
  -H "Authorization: ******" \
  -H "Content-Type: application/json" \
  -d '{"record":"10 5 443 service.example.com."}'

Response

{
  "ok": true,
  "data": {
    "priority": 10,
    "weight": 5,
    "port": 443,
    "target": "service.example.com"
  }
}
POST/v1/network/asn-lookup5 credits / call

ASN lookup

Look up the autonomous system number and network operator for a validated public IP address.

ParameterTypeRequiredDescription
ipstringYesPublic IPv4 or IPv6 address.

Request

curl -X POST https://toolsonduty.com/api/v1/network/asn-lookup \
  -H "Authorization: ******" \
  -H "Content-Type: application/json" \
  -d '{"ip":"1.1.1.1"}'

Response

{
  "ok": true,
  "data": {
    "ip": "1.1.1.1",
    "asn": 13335,
    "organization": "Cloudflare, Inc."
  }
}
POST/v1/network/dns5 credits / call

DNS lookup

Resolve a validated public hostname through Google Public DNS over HTTPS and return record values with current TTLs.

ParameterTypeRequiredDescription
namestringYesPublic hostname or domain, for example example.com.
typestringNoDNS record type: A, AAAA, CAA, CNAME, MX, NS, SOA, TXT. Default: A.

Request

curl -X POST https://toolsonduty.com/api/v1/network/dns \
  -H "Authorization: ******" \
  -H "Content-Type: application/json" \
  -d '{"name":"example.com","type":"A"}'

Response

{
  "ok": true,
  "data": {
    "query": {
      "name": "example.com",
      "type": "A"
    },
    "status": {
      "code": 0,
      "name": "NOERROR"
    },
    "records": [
      {
        "name": "example.com.",
        "type": "A",
        "ttl": 300,
        "data": "93.184.216.34"
      }
    ],
    "resolver": {
      "name": "Google Public DNS",
      "protocol": "DNS over HTTPS"
    }
  }
}
POST/v1/network/rdap-domain5 credits / call

Domain RDAP lookup

Retrieve curated public domain-registration data from the authoritative RDAP registry selected through the official IANA bootstrap service.

ParameterTypeRequiredDescription
domainstringYesRegistered public domain, for example example.com.

Request

curl -X POST https://toolsonduty.com/api/v1/network/rdap-domain \
  -H "Authorization: ******" \
  -H "Content-Type: application/json" \
  -d '{"domain":"example.com"}'

Response

{
  "ok": true,
  "data": {
    "domain": "example.com",
    "status": [
      "client transfer prohibited"
    ],
    "events": [
      {
        "action": "registration",
        "date": "1995-08-14T04:00:00Z"
      }
    ],
    "nameservers": [
      "elliott.ns.cloudflare.com",
      "hera.ns.cloudflare.com"
    ],
    "secureDns": {
      "delegationSigned": true
    },
    "source": {
      "protocol": "RDAP",
      "bootstrap": "IANA RDAP Bootstrap Service Registry"
    }
  }
}
POST/v1/network/rdap-ip5 credits / call

IP RDAP lookup

Retrieve curated public network-allocation data from the authoritative regional registry selected through the official IANA IPv4 or IPv6 bootstrap service.

ParameterTypeRequiredDescription
ipstringYesPublic IPv4 or IPv6 address, for example 8.8.8.8 or 2606:4700:4700::1111.

Request

curl -X POST https://toolsonduty.com/api/v1/network/rdap-ip \
  -H "Authorization: ******" \
  -H "Content-Type: application/json" \
  -d '{"ip":"8.8.8.8"}'

Response

{
  "ok": true,
  "data": {
    "query": "8.8.8.8",
    "ipVersion": "v4",
    "name": "GOGL",
    "startAddress": "8.8.8.0",
    "endAddress": "8.8.8.255",
    "cidrs": [
      "8.8.8.0/24"
    ],
    "source": {
      "protocol": "RDAP",
      "bootstrap": "IANA RDAP Bootstrap Service Registry",
      "bootstrapAllocation": "8.0.0.0/8"
    }
  }
}
POST/v1/network/email-domain5 credits / call

Email domain validation

Validate a domain's public mail-routing configuration using MX, Null MX, fallback address, SPF and DMARC DNS records without sending email or probing SMTP.

ParameterTypeRequiredDescription
domainstringYesPublic email domain, for example gmail.com.

Request

curl -X POST https://toolsonduty.com/api/v1/network/email-domain \
  -H "Authorization: ******" \
  -H "Content-Type: application/json" \
  -d '{"domain":"gmail.com"}'

Response

{
  "ok": true,
  "data": {
    "domain": "gmail.com",
    "acceptsMail": true,
    "reason": "The domain publishes one or more MX records.",
    "mx": {
      "nullMx": false,
      "records": [
        {
          "priority": 5,
          "exchange": "gmail-smtp-in.l.google.com",
          "ttl": 300
        }
      ]
    },
    "policies": {
      "spf": [
        "v=spf1 ..."
      ],
      "dmarc": [
        "v=DMARC1; ..."
      ]
    }
  }
}
POST/v1/network/http-headers7 credits / call

HTTP header inspection

Inspect non-sensitive response headers from a validated public HTTP or HTTPS URL with redirect revalidation and no response-body download.

ParameterTypeRequiredDescription
urlstringYesPublic HTTP or HTTPS URL using port 80 or 443.

Request

curl -X POST https://toolsonduty.com/api/v1/network/http-headers \
  -H "Authorization: ******" \
  -H "Content-Type: application/json" \
  -d '{"url":"https://example.com"}'

Response

{
  "ok": true,
  "data": {
    "requestedUrl": "https://example.com/",
    "finalUrl": "https://example.com/",
    "status": 200,
    "redirects": [],
    "headers": {
      "content-type": "text/html"
    },
    "https": true,
    "inspection": {
      "method": "HEAD",
      "bodyDownloaded": false
    }
  }
}
POST/v1/network/redirect-trace7 credits / call

Validated redirect trace

Trace up to five public HTTP redirects while revalidating the destination hostname, addresses, scheme and port at every hop.

ParameterTypeRequiredDescription
urlstringYesPublic HTTP or HTTPS URL using port 80 or 443.

Request

curl -X POST https://toolsonduty.com/api/v1/network/redirect-trace \
  -H "Authorization: ******" \
  -H "Content-Type: application/json" \
  -d '{"url":"http://github.com"}'

Response

{
  "ok": true,
  "data": {
    "requestedUrl": "http://github.com/",
    "finalUrl": "https://github.com/",
    "finalStatus": 200,
    "redirectCount": 1,
    "redirects": [
      {
        "status": 301,
        "location": "https://github.com/"
      }
    ]
  }
}
POST/v1/network/response-size7 credits / call

Response-size metadata

Read server-reported response-size and representation metadata from a validated public URL without downloading the response body.

ParameterTypeRequiredDescription
urlstringYesPublic HTTP or HTTPS URL using port 80 or 443.

Request

curl -X POST https://toolsonduty.com/api/v1/network/response-size \
  -H "Authorization: ******" \
  -H "Content-Type: application/json" \
  -d '{"url":"https://example.com"}'

Response

{
  "ok": true,
  "data": {
    "finalUrl": "https://example.com/",
    "status": 200,
    "reportedBytes": 1256,
    "contentType": "text/html; charset=UTF-8",
    "bodyDownloaded": false
  }
}
POST/v1/network/website-health8 credits / call

Website health summary

Summarize public website availability, HTTPS, redirects and six common browser security headers using a validated header-only request.

ParameterTypeRequiredDescription
urlstringYesPublic HTTP or HTTPS URL using port 80 or 443.

Request

curl -X POST https://toolsonduty.com/api/v1/network/website-health \
  -H "Authorization: ******" \
  -H "Content-Type: application/json" \
  -d '{"url":"https://example.com"}'

Response

{
  "ok": true,
  "data": {
    "finalUrl": "https://example.com/",
    "status": 200,
    "responsive": true,
    "https": true,
    "securityHeaders": {
      "count": 3,
      "total": 6
    },
    "score": 78,
    "grade": "B"
  }
}
POST/v1/network/caa5 credits / call

CAA record lookup

Look up and parse Certificate Authority Authorization records for a public domain through Google Public DNS.

ParameterTypeRequiredDescription
domainstringYesPublic domain or hostname.

Request

curl -X POST https://toolsonduty.com/api/v1/network/caa \
  -H "Authorization: ******" \
  -H "Content-Type: application/json" \
  -d '{"domain":"example.com"}'

Response

{
  "ok": true,
  "data": {
    "domain": "example.com",
    "records": [
      {
        "flags": 0,
        "critical": false,
        "tag": "issue",
        "value": "letsencrypt.org",
        "ttl": 300
      }
    ],
    "hasPolicy": true
  }
}
POST/v1/network/nameservers5 credits / call

Nameserver lookup

Return authoritative NS records, TTLs, public IPv4/IPv6 addresses and basic redundancy signals for a domain.

ParameterTypeRequiredDescription
domainstringYesPublic domain or hostname.

Request

curl -X POST https://toolsonduty.com/api/v1/network/nameservers \
  -H "Authorization: ******" \
  -H "Content-Type: application/json" \
  -d '{"domain":"example.com"}'

Response

{
  "ok": true,
  "data": {
    "domain": "example.com",
    "nameservers": [
      {
        "hostname": "elliott.ns.cloudflare.com",
        "ttl": 86400,
        "addresses": [
          "172.64.33.162"
        ]
      }
    ],
    "redundancy": {
      "hasMultipleNameservers": true,
      "allNameserversResolved": true
    }
  }
}
POST/v1/network/dkim5 credits / call

DKIM record lookup

Look up a DKIM TXT policy for one explicitly supplied domain and selector without attempting selector enumeration.

ParameterTypeRequiredDescription
domainstringYesPublic email domain.
selectorstringYesDKIM selector published by the mail sender.

Request

curl -X POST https://toolsonduty.com/api/v1/network/dkim \
  -H "Authorization: ******" \
  -H "Content-Type: application/json" \
  -d '{"domain":"example.com","selector":"google"}'

Response

{
  "ok": true,
  "data": {
    "domain": "example.com",
    "selector": "google",
    "lookupName": "google._domainkey.example.com",
    "found": false,
    "records": []
  }
}
POST/v1/network/bimi5 credits / call

BIMI record lookup

Look up a BIMI TXT policy for a public domain and explicit selector; the selector defaults to default.

ParameterTypeRequiredDescription
domainstringYesPublic email domain.
selectorstringNoBIMI selector. Default: default.

Request

curl -X POST https://toolsonduty.com/api/v1/network/bimi \
  -H "Authorization: ******" \
  -H "Content-Type: application/json" \
  -d '{"domain":"example.com","selector":"default"}'

Response

{
  "ok": true,
  "data": {
    "domain": "example.com",
    "selector": "default",
    "lookupName": "default._bimi.example.com",
    "found": false,
    "records": []
  }
}