POSThttps://api.deepinfo.com/v1/tools/domain-extractor

Extracts every unique domain name from a block of text. Only names whose suffix is on the public suffix list are returned, so bad..name and host.invalid are skipped.

Host names come back as they are written (www.example.com, shop.example.co.uk, and a punycode label stays punycode), and the domain of an email address is extracted too: user@example.org yields example.org.

Authentication

Send your API key in the apikey request header.

Request Body

ParameterTypeRequiredDescription
textstringRequired
Text to scan. Limited to 1,000,000 characters and 10,000 lines.
application/json
{
  "text": "Indicators seen in the leak: 198.51.100.7, 203.0.113.10 and 198.51.100.7 again, plus 2001:db8::1.\nHosts: www.example.com, mail.example.org, shop.example.co.uk, xn--mteri-h9ac.example.com.\nNot hosts: bad..name, host.invalid, 10.0.0.1, user@example.org"
}

Response Fields

FieldTypeDescription
domainsarray of string
The unique domain names found.

Response Schema

FieldTypeExample
domainsarray<string>"www.example.com"

Examples

Saved examples from the Deepinfo API. Selecting one loads it into the request and response panels.

Reference updated