Usage guide

Endpoints

Path Returns
/ Full aggregated info — auto-detects HTML / JSON / text
/ip Current connection IP — bare value
/ipv4 /ip4 /4 IPv4 only — bare value, scriptable
/ipv6 /ip6 /6 IPv6 only — bare value, scriptable
/geoip Country + city + coordinates
/asn ASN, operator, prefix, looking-glass URL
/isp "name (AS<n>)" — bare value, scriptable
/dns DNS resolver classifier (?resolver=… optional)
/rdns /rdns/{ip} Reverse DNS (PTR). With no path arg, resolves the caller's own IP (including RFC1918 if your resolver answers). With an explicit IP, resolves that one. Cached, 0.3 s timeout, public CORS so the dual-stack probe can fan out cross-origin.
/protocol Negotiated HTTP version, TLS version, ALPN. Hit https://secure.cptv.cz/protocol with curl --http1.1 / --http2 / --http3 to compare what your client can negotiate.
/traceroute Full traceroute, blocking
/traceroute.json Same, JSON only
/traceroute.txt Same, plain text only
/traceroute/stream Server-Sent Events of hops as they arrive
/help This page
/health Service health (always JSON)
/docs /redoc Auto-generated OpenAPI explorers
/openapi.json Raw OpenAPI schema

Every path is also reachable under /api/v1/… for stable client integration.

Subdomains

The 🔒 secure / 🔓 apex link in the navigation bar always points at the alternate flavour so you can switch with one click.

Format negotiation

Every endpoint speaks three formats. Pick one:

Examples

curl cptv.cz                       # aggregated text
curl cptv.cz/?format=json          # aggregated JSON
curl ipv4.cptv.cz                  # bare IPv4
curl ipv6.cptv.cz                  # bare IPv6
MY_IP=$(curl -s ipv4.cptv.cz)      # capture in shell
curl cptv.cz/geoip                 # one section, plain text
curl cptv.cz/asn?format=json       # one section, JSON
curl cptv.cz/rdns                  # PTR for your own IP
curl cptv.cz/rdns/1.1.1.1          # PTR for any IP
curl cptv.cz/traceroute.txt        # blocking traceroute
curl -I cptv.cz/ip                 # see response headers

curl --http1.1 https://secure.cptv.cz/protocol  # force HTTP/1.1
curl --http2   https://secure.cptv.cz/protocol  # force HTTP/2
curl --http3   https://secure.cptv.cz/protocol  # force HTTP/3 (QUIC)
# /protocol prints: <HTTP/x>\t<TLSvX.Y>\t<alpn>\t<encrypted|plain>