LEVIATHAN X Query the index

// DEVELOPER REFERENCE

API Documentation

Base URL: https://api.leviathan.ac · versioned alias: /v1/...
Machine-readable spec: /api/openapi.json (OpenAPI 3.0)

Quickstart

# 1. open stats, no key needed
curl https://api.leviathan.ac/stats/risk-distribution

# 2. get a free key at https://leviathan.ac (100 queries/day)

# 3. search, keyed
curl -H "x-api-key: YOUR_KEY" \
  "https://api.leviathan.ac/search/port/3389?region=us&limit=10"

Authentication

Every keyed endpoint expects an x-api-key header. Keys are tiered:

TierQuotaDeep lookupsGet it
free100 queries/dayn/aself-serve signup
day pass1,000 queries / 24h100 live/day$9 one-time, instant 24h sprint pass
pro10,000 queries/day100 live/day$29/mo, key delivered instantly on checkout
demo (shared)1,000 queries/day shared by everyonen/a (no deep probes)baked into the leviathan.ac demo

Total records = identity records + open server files + open services + CVE records. The hero on the homepage breaks this out so you can see what the 190M is made of, it is not 190M hosts.

Quota is a daily counter (UTC). A 429 response means the day's quota is spent, upgrade or wait for reset. The quota object in every keyed response shows used/limit.

Endpoints

EndpointAuthDescription
GET /openService info: per-segment record counts, tiers, endpoint list
GET /stats/risk-distributionopenRisk-tier distribution, optional ?region=
GET /stats/top-asnsopenTop 20 ASN organizations
GET /stats/top-portsopenTop 20 ports
GET /host/{ip}keyUnified Host Dossier: aggregates all open ports, hostnames, PTR, CVEs, and services for an IP into a single structured profile
GET /rdns/{ip}keyReverse DNS: dual system socket + Cloudflare DoH PTR resolution
GET /threats/c2keyLive C2 Threat Tracker: active Cobalt Strike teamservers, Metasploit handlers, Sliver, Mythic, Havoc (supports ?framework=)
GET /search/c2/{framework}keySearch active C2 infrastructure (e.g. /search/c2/cobalt, /search/c2/metasploit, /search/c2/all)
GET /search/ip/{ip}keyAll exposed services for one IP (includes host dossier object)
GET /search/asn/{asn}keyAll records for one ASN
GET /search/port/{port}keyAll records for one port, risk-score descending
GET /search/product/{product}keyHosts running a product (substring match, e.g. nginx)
GET /search/cidr/{cidr}keyAll exposed services inside a CIDR block, e.g. /search/cidr/45.32.0.0%2F16 (IPv4/IPv6; encode / as %2F)
GET /search/cve/{cve_id}keyAll hosts carrying this CVE
GET /search/org/{org}keyHosts by ASN organization or ISP
GET /search/country/{cc}keyHosts by 2-letter country code
GET /search/title/{text}keyHosts by HTTP title
GET /search/q/{text}keyFree-text across product, title, server, tags, org, domain, hostname
GET /cve/{cve_id}keyCVE details: summary, CVSS, EPSS, KEV, served from the Leviathan vulnerability index (nightly NVD sync, daily EPSS, CISA KEV) with live upstream fallback flag
GET /stats/cve-exposureopenCVEs ranked by hosts affected inside the index, not by fame. Supports ?limit= and ?kev=1
GET /cve/topopenAlias of /stats/cve-exposure
GET /deep/host/{ip}paidLive deep lookup: all ports, honeyscore, services (100/day)
GET /threats/artexkeyExposed pentest-agent radar: ARTEX instances on the public internet, fingerprinted by HTTP title and favicon hash so renamed forks surface. Supports ?country=, ?confidence=, ?limit=
POST /signupopenFree key provisioning (email + honeypot)
GET /verify-purchase?session_id=openPaid key retrieval after checkout

Shared query parameters on search endpoints: ?region=us|cn|gb|vn|win · ?limit=1-1000 · ?tier=critical,high

Response shape

{
  "query":    { "port": "3389" },
  "region":   "all",
  "total":    141,
  "returned": 2,
  "truncated": true,
  "quota":    { "used": 3, "limit": 1000 },
  "results": [
    {
      "ip": "43.166.167.133", "port": "3389",
      "service_class": "rdp", "product": "Remote Desktop Protocol",
      "version": "10.0.26100", "risk_flags": "rdp_exposed",
      "asn": "132203", "asn_org": "ACEVILLE PTE.LTD.",
      "asn_type": "cloud", "ip_type": "datacenter",
      "city": "Ashburn", "region": "us", "country": "US",
      "hostname": "", "registered_domain": "",
      "ssl_present": "1", "cpe23": "o:microsoft:windows:10.0.26100",
      "cves": "CVE-2023-44487;...", "max_cvss": "8.7", "cve_count": "18",
      "os": "", "tags": "", "components": "",
      "http_title": "", "http_server": "", "http_status": "",
      "banner_flags": "", "risk_score": 83, "risk_tier": "high",
      "first_seen": "2026-10-23", "last_seen": "2026-10-24"
    }
  ]
}

Results are ordered risk-score descending, the interesting stuff leads. truncated: true means more matches exist behind your limit.

Errors

CodeBodyMeaning
401{"error": "missing x-api-key header"}No key sent
403{"error": "invalid or inactive API key"}Bad/rotated key
404{"error": "unknown search kind 'x'", "allowed": [...]}Bad search kind, the response lists the valid ones
429{"error": "daily quota exceeded", "limit": 10}Quota spent, resets 00:00 UTC
400{"error": "unknown region 'xx'"}Bad parameter
500{"error": "internal error", "requestId": "..."}Our fault, quote the requestId

Canonical endpoints

Every dataset has exactly one canonical URL. Aliases resolve, but they 301 to the route below and are marked deprecated in openapi.json — save the canonical form, not its alias.

DataCanonicalAliases (301 → canonical)
Index totals/stats/summary/stats
CVE blast radius/stats/cve-exposure/cve/top
Reverse-IP neighbours/reverse-ip/{ip}/reverseip/{ip}
Live ticker/stats/live-feed—
C2 / APT tracker/threats/c2/search/c2/{framework}
Exposed pentest agents/threats/artex—
CVE record/cve/{cve_id}—

/v1/… is a versioned alias of the whole surface and resolves to the same handlers; it is accepted, not deprecated.

Client examples

Python

import requests

BASE = "https://api.leviathan.ac"
H = {"x-api-key": "YOUR_KEY"}

# CVEs ranked by hosts affected inside the index (no key needed)
cves = requests.get(f"{BASE}/stats/cve-exposure", params={"limit": 10, "kev": 1}).json()
for c in cves["cves"]:
    print(c["cve_id"], c["hosts_affected"], "hosts", c["cvss_v3"], c["epss"])

# Exposed pentest agents (ARTEX)
agents = requests.get(f"{BASE}/threats/artex", headers=H, params={"limit": 50}).json()

r = requests.get(f"{BASE}/search/cve/CVE-2023-44487",
                 headers=H, params={"region": "us", "limit": 100})
for rec in r.json()["results"]:
    print(rec["ip"], rec["port"], rec["risk_tier"], rec["cves"])

JavaScript

const BASE = "https://api.leviathan.ac";
const r = await fetch(`${BASE}/search/asn/16509?limit=50`,
                      { headers: { "x-api-key": "YOUR_KEY" } });
const { total, results } = await r.json();

curl

curl -H "x-api-key: YOUR_KEY" \
  "https://api.leviathan.ac/search/product/nginx?limit=20"

Webhook recipes

Continuous monitoring: cron a script that pulls /search/cve/{NEW_KEV_CVE} whenever CISA adds a KEV entry, any host in the index carrying it is your alert list. Pair with ?region= to scope to your markets.

Surface-diff pattern: snapshot /search/asn/{YOUR_ASN} daily, diff against yesterday, new exposures surface with tier + CVE context in one call.

Versioning

The current API is served at both the root and /v1/..., identical behavior. Breaking changes will ship under /v2/... with at least 90 days of /v1 overlap.

← Back to Search · openapi.json