Developer Libraries
Third-party Integrations
Python SDK for Domain Availability Lookup with WhoisFreaks API
The WhoisFreaks Python SDK allows developers to check the availability of domain names, making it easier to identify domains that are open for registration. This functionality supports domain acquisition, brand protection, and strategic management of digital assets by uncovering new domain opportunities.
Domain Availability Lookup
This package is for performing any type of Domain Availability Lookup.
To utilize the WhoisFreaks Python SDK for checking the availability of domain names, follow these steps:
First, ensure that Python and the WhoisFreaks Python SDK are installed on your system. To install the necessary modules, please visit the Installation Steps page.
In all lookups, replace "your_api_key" with your actual API key.
-
Domain Availability Check
domain_availability_lookup performs a domain availability check using the WhoisFreaks API. It checks whether a specific domain name is available for registration.
python Copydomain_availability_lookup(api_key='your_api_key', domain='google.com', sug=True)
Parameter:
- domain: The domain name to be checked for availability (e.g., "example.com").
- sug: For getting suggestions, it can be passed with or without a count. There are two possible values for sug: true or false. If you don't specify the sug parameter, the default value will be false.
- count: If sug is true, then count can be passed for the desired number of suggestions. Default value of count is 5.
- source: By default, a live WHOIS lookup is used to check domain availability for higher reliability. For faster responses, you can set the source to dns.
- format: Two formats are available JSON, XML. If you don't specify the 'format' parameter, the default format will be JSON.
- api_key: Get your API key from our billing dashboard.
Returns:
- Success: A simple domain availability flag or a pointer to a domain_available_response struct containing domain availability of requested domain name and some other suggested domains.
- Error: A JSON string containing the error structure if an API error occurs, or 'nil' if the request fails.
For a comprehensive details of response fields, please visit the Domain Availability Lookup Documentation.Example Usage:
python Copyfrom whoisfreaks import WhoisfreaksApi from whoisfreaks.core.api_error import ApiError client = WhoisfreaksApi() try: response = client.domain_availability_lookup(api_key='your_api_key', domain='google.com', sug=True) response = {k: v for k, v in response.dict().items() if v is not None} # Filtering the Null values print(response) except ApiError as e: print(e.body)
Replace "whois.com" with the domain you wish to check.
To perform other lookups using the Python SDK, click on one of the related options below.
WHOIS lookups
Offers live, reverse, historical, IP, ASN, and bulk domain WHOIS lookups.
DNS Lookups
Provides live, reverse, historical, and bulk DNS lookup services.
SSL Lookups
Performs SSL lookup and shows certificate chain from start to present.
Check out the official WhoisFreaks Python SDK documentation for domain availability lookups and management.

WhoisFreaks Python SDK
Use this powerful Python-based SDK to easily integrate, interact with, and manage data from the WhoisFreaks API seamlessly.
whoisfreaks.docs.buildwithfern.com