Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
84 changes: 79 additions & 5 deletions domaintools/api.py
Original file line number Diff line number Diff line change
Expand Up @@ -1033,7 +1033,21 @@ def iris_detect_ignored_domains(
)

def nod(self, **kwargs) -> FeedsResults:
"""Returns back list of the newly observed domains feed"""
"""Returns back list of the newly observed domains feed.
Apex-level domains (e.g. example.com but not www.example.com) that we observe for the first time, and have not observed previously with our global DNS sensor network.

domain: str: Filter for an exact domain or a substring contained within a domain by prefixing or suffixing your substring with "*". Check the documentation for examples

before: str: Filter for records before the given time value inclusive or time offset relative to now

after: str: Filter for records after the given time value inclusive or time offset relative to now

headers: bool: Use in combination with Accept: text/csv headers to control if headers are sent or not

sessionID: str: A custom string to distinguish between different sessions

top: int: Limit the number of results to the top N, where N is the value of this parameter.
"""
validate_feeds_parameters(kwargs)
endpoint = kwargs.pop("endpoint", Endpoint.FEED.value)
source = ENDPOINT_TO_SOURCE_MAP.get(endpoint)
Expand All @@ -1050,7 +1064,22 @@ def nod(self, **kwargs) -> FeedsResults:
)

def nad(self, **kwargs) -> FeedsResults:
"""Returns back list of the newly active domains feed"""
"""Returns back list of the newly active domains feed. Contains domains that have been observed after having not been seen for at least 10 days in passive DNS.
Apex-level domains (e.g. example.com but not www.example.com) that we observe based on the latest lifecycle of the domain. A domain may be seen either for the first time ever, or again after at least 10 days of inactivity (no observed resolutions in DNS).
Populated with our global passive DNS (pDNS) sensor network.

domain: str: Filter for an exact domain or a substring contained within a domain by prefixing or suffixing your substring with "*". Check the documentation for examples

before: str: Filter for records before the given time value inclusive or time offset relative to now

after: str: Filter for records after the given time value inclusive or time offset relative to now

headers: bool: Use in combination with Accept: text/csv headers to control if headers are sent or not

sessionID: str: A custom string to distinguish between different sessions

top: int: Limit the number of results to the top N, where N is the value of this parameter.
"""
validate_feeds_parameters(kwargs)
endpoint = kwargs.pop("endpoint", Endpoint.FEED.value)
source = ENDPOINT_TO_SOURCE_MAP.get(endpoint).value
Expand All @@ -1067,7 +1096,22 @@ def nad(self, **kwargs) -> FeedsResults:
)

def domainrdap(self, **kwargs) -> FeedsResults:
"""Returns changes to global domain registration information, populated by the Registration Data Access Protocol (RDAP)"""
"""Returns changes to global domain registration information, populated by the Registration Data Access Protocol (RDAP).
Compliments the 5-Minute WHOIS Feed as registries and registrars switch from Whois to RDAP.
Contains parsed and raw RDAP-format domain registration data, emitted as soon as they are collected and parsed into a normalized structure.

domain: str: Filter for an exact domain or a substring contained within a domain by prefixing or suffixing your substring with "*". Check the documentation for examples

before: str: Filter for records before the given time value inclusive or time offset relative to now

after: str: Filter for records after the given time value inclusive or time offset relative to now

headers: bool: Use in combination with Accept: text/csv headers to control if headers are sent or not

sessionID: str: A custom string to distinguish between different sessions

top: int: Limit the number of results to the top N, where N is the value of this parameter.
"""
validate_feeds_parameters(kwargs)
endpoint = kwargs.pop("endpoint", Endpoint.FEED.value)
source = ENDPOINT_TO_SOURCE_MAP.get(endpoint).value
Expand All @@ -1081,7 +1125,22 @@ def domainrdap(self, **kwargs) -> FeedsResults:
)

def domaindiscovery(self, **kwargs) -> FeedsResults:
"""Returns new domains as they are either discovered in domain registration information, observed by our global sensor network, or reported by trusted third parties"""
"""Returns new domains as they are either discovered in domain registration information, observed by our global sensor network, or reported by trusted third parties".
Contains domains that are newly-discovered by Domain Tools in both passive and active DNS sources, emitted as soon as they are first observed.
New domains as they are either discovered in domain registration information, observed by our global sensor network, or reported by trusted third parties.

domain: str: Filter for an exact domain or a substring contained within a domain by prefixing or suffixing your substring with "*". Check the documentation for examples

before: str: Filter for records before the given time value inclusive or time offset relative to now

after: str: Filter for records after the given time value inclusive or time offset relative to now

headers: bool: Use in combination with Accept: text/csv headers to control if headers are sent or not

sessionID: str: A custom string to distinguish between different sessions

top: int: Limit the number of results to the top N, where N is the value of this parameter.
"""
validate_feeds_parameters(kwargs)
endpoint = kwargs.pop("endpoint", Endpoint.FEED.value)
source = ENDPOINT_TO_SOURCE_MAP.get(endpoint).value
Expand All @@ -1098,7 +1157,22 @@ def domaindiscovery(self, **kwargs) -> FeedsResults:
)

def noh(self, **kwargs) -> FeedsResults:
"""Returns back list of the newly observed hostnames feed"""
"""Returns back list of the newly observed hostnames feed.
Contains fully qualified domain names (i.e. host names) that have never been seen before in passive DNS, emitted as soon as they are first observed.
Hostname resolutions that we observe for the first time with our global DNS sensor network.

domain: str: Filter for an exact domain or a substring contained within a domain by prefixing or suffixing your substring with "*". Check the documentation for examples

before: str: Filter for records before the given time value inclusive or time offset relative to now

after: str: Filter for records after the given time value inclusive or time offset relative to now

headers: bool: Use in combination with Accept: text/csv headers to control if headers are sent or not

sessionID: str: A custom string to distinguish between different sessions

top: int: Limit the number of results to the top N, where N is the value of this parameter.
"""
validate_feeds_parameters(kwargs)
endpoint = kwargs.pop("endpoint", Endpoint.FEED.value)
source = ENDPOINT_TO_SOURCE_MAP.get(endpoint).value
Expand Down
6 changes: 5 additions & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,11 @@ build-backend = "setuptools.build_meta"

[project]
name = "domaintools_api"
dependencies = ["httpx", "rich", "typer"]
dependencies = [
"httpx==0.28.1",
"rich",
"typer"
]
requires-python = ">= 3.9"
authors = [{ name = "DomainTools", email = "integrations@domaintools.com" }]
description = "DomainTools Official Python API"
Expand Down