Calling API

For getting the API key, you need to get started with our developer account. When you sign up then you can copy the API key from our billing dashboard.

Copied
GET https://api.whoisfreaks.com/v1.0/domain/availability?apiKey=API_KEY&domain=google.com
GET https://api.whoisfreaks.com/v1.0/domain/availability?apiKey=API_KEY&domain=google.com&sug=true
GET https://api.whoisfreaks.com/v1.0/domain/availability?apiKey=API_KEY&domain=google.com&sug=true&count=10


Input parameters: required

apiKey Get your API key on our billing dashboard.

domain The domain to check availability.

Input parameters: optional

sug For getting suggestions. It can be passed with or without count.

count If sug is true then count can be passed for desired number of suggestions. Default value of count is 5.

format Two formats are available JSON, XML. If you don't pass 'format' parameter, default format is JSON.


Response

Following is explanation of API response

  • DomainAvailability
    • true: domain is not registered
    • false: domain is already registered


{
    "domain": "whoisfreaks.com",
    "domainAvailability": false
}


With domain suggestions

[ { "domain": "whoisfreaks.net", "domainAvailability": true }, { "domain": "whoisfreaks.dev", "domainAvailability": true }, { "domain": "whoisfreaks.top", "domainAvailability": true }, { "domain": "whoisfreaks.org", "domainAvailability": true }, { "domain": "whoisfreaks.info", "domainAvailability": true }, { "domain": "whoisfreaks.com", "domainAvailability": false } ]



HTTP Error Codes

Below mentioned possible type of error and desc

HTTP Code
Error Message
403 We are not providing the whois of this domain extension(comsdf) 400 Please pass domain param correct value[For Technical Support: support@whoisfreaks.com] 408 Unable to fetch whois data.Please try again [For Technical Support: support@whoisfreaks.com] 401 Provided API key is invalid. [For Technical Support: support@whoisfreaks.com] 401 Provided API key is inactive. [For Technical Support: support@whoisfreaks.com] 401 Please buy subscription plan or add api credits then use this api key. [For Technical Support: support@whoisfreaks.com] 413 You have exceeded the limit of api credits requests [allowed_request_no].Please upgrade your plan [For Technical Support: support@whoisfreaks.com] 412 You have exceeded the limit of api plan requests and your subscription canceled.Please contact our technical support team: support@whoisfreaks.com] 413 You have exceeded the limit of Surcharge Requests [allowed_surcharge_request_no]. Please upgrade your plan [For Technical Support: support@whoisfreaks.com] 401 Your subscription is deactivated.Please buy new plan or add api credits for using whoisfreaks api's [For Technical Support: support@whoisfreaks.com] 401 Your subscription is deactivated due to many time payment failure.Please buy new plan or add api credits for using whoisfreaks api's 401 Your account is deactivated.[For Technical Support: support@whoisfreaks.com]

            
{
    "timestamp":1655190836973,
    "status": 403,
    "error": "Not Supported Domain extension",
    "message": "We are not providing the whois of this domain extension(comsdf)",
    "path": "/v1.0/domain/availability?domain=JFREAKS.comsdf&apiKey=API_KEY"
}
            
            
            
 {
    "timestamp": 1655190764370,
    "status": 400,
    "error": "Invalid Param Exception",
    "message": "Please provide domain",
    "path": "/v1.0/domain/availability?domain=DOMAIN_NAME&apiKey=API_KEY"
}
            
                        
            {
    "timestamp": 1639056483652,
    "status": 408,
    "error": "Fetching Whois Data Failed",
    "message": "Unable to fetch whois data.Please try again [For Technical Support: support@whoisfreaks.com]",
    "path": "/v1.0/domain/availability?domain=DOMAIN_NAME&apiKey=API_KEY"
    }
            
            

Some common Errors:

                        
 {
    "timestamp": 1612161378521,
    "status": 401,
    "error": "Api Access Exception",
    "message": "Provided API key is invalid. [For Technical Support: support@whoisfreaks.com]",
    "path": "/v1.0/domain/availability?domain=DOMAIN_NAME&apiKey=API_KEY"
}
            
                        

                        
 {
    "timestamp": 1612161378521,
    "status": 401,
    "error": "Api Access Exception",
    "message": "Provided API key is inactive. [For Technical Support: support@whoisfreaks.com]",
    "path": "/v1.0/domain/availability?domain=DOMAIN_NAME&apiKey=API_KEY"
}
            
                        

                        
 {
    "timestamp": 1612161378521,
    "status": 401,
    "error": "Api Access Exception",
    "message": "Please buy subscription plan or add api credits then use this api key. [For Technical Support: support@whoisfreaks.com]",
    "path": "/v1.0/domain/availability?domain=DOMAIN_NAME&apiKey=API_KEY"
}
            
                        

                        
 {
    "timestamp": 1612161378521,
    "status": 413,
    "error": "Api Access Exception",
    "message": "You have exceeded the limit of api credits requests [allowed_request_no].Please upgrade your plan [For Technical Support: support@whoisfreaks.com]  ",
    "path": "/v1.0/domain/availability?domain=DOMAIN_NAME&apiKey=API_KEY"
}
            
                        

                        
 {
    "timestamp": 1612161378521,
    "status": 412,
    "error": "Api Access Exception",
    "message": "You have exceeded the limit of api plan requests and your subscription canceled.Please contact our technical support team: support@whoisfreaks.com]",
    "path": "/v1.0/domain/availability?domain=DOMAIN_NAME&apiKey=API_KEY"
}
            

            

                        
 {
    "timestamp": 1612161378521,
    "status": 413,
    "error": "Api Access Exception",
    "message": "You have exceeded the limit of Surcharge Requests [allowed_surcharge_request_no]. Please upgrade your plan [For Technical Support: support@whoisfreaks.com] ",
    "path": "/v1.0/domain/availability?domain=DOMAIN_NAME&apiKey=API_KEY"
}
            

            
                        
 {
    "timestamp": 1612161378521,
    "status": 401,
    "error": "Api Access Exception",
    "message": "Your subscription is deactivated.Please buy new plan or add api credits for using whoisfreaks api's [For Technical Support: support@whoisfreaks.com]",
    "path": "/v1.0/domain/availability?domain=DOMAIN_NAME&apiKey=API_KEY"
}
            
                        

                        
 {
    "timestamp": 1612161378521,
    "status": 401,
    "error": "Api Access Exception",
    "message": "Your subscription is deactivated due to many time payment failure.Please buy new plan or add api credits for using whoisfreaks api's",
    "path": "/v1.0/domain/availability?domain=DOMAIN_NAME&apiKey=API_KEY"
}
            
                        



                        
 {
    "timestamp": 1612161378521,
    "status": 401,
    "error": "Api Access Exception",
    "message": "Your account is deactivated.[For Technical Support: support@whoisfreaks.com]",
    "path": "/v1.0/domain/availability?domain=DOMAIN_NAME&apiKey=API_KEY"
}
            
                        

API Usage Rule

Cost Using Domain Availability Service will charge 1 credit per domain, and Domain Suggestion will charge 1 credit per five domain name suggestions.

Code Snippet


    curl --location --request GET 'https://api.whoisfreaks.com/v1.0/domain/availability?domain=jfreaks.com&apiKey=API_KEY'



var request = require('request');
var options = {
  'method': 'GET',
  'url': 'https://api.whoisfreaks.com/v1.0/domain/availability?domain=freaks.com&apiKey=API_KEY',
  'headers': {
  }
};
request(options, function (error, response) {
  if (error) throw new Error(error);
  console.log(response.body);
});





    OkHttpClient client = new OkHttpClient().newBuilder()
  .build();
Request request = new Request.Builder()
  .url("https://api.whoisfreaks.com/v1.0/domain/availability?domain=jfreaks.com&apiKey=API_KEY")
  .method("GET", null)
  .build();
Response response = client.newCall(request).execute();




    import http.client
    conn = http.client.HTTPSConnection("api.whoisfreaks.com")
payload = ''
headers = {}
conn.request("GET", "/v1.0/domain/availability?domain=jfreaks.com&apiKey=API_KEY", payload, headers)
res = conn.getresponse()
data = res.read()
print(data.decode("utf-8"))




     'https://api.whoisfreaks.com/v1.0/domain/availability?domain=jfreaks.com&apiKey=API_KEY',
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => '',
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 0,
  CURLOPT_FOLLOWLOCATION => true,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => 'GET',
));

$response = curl_exec($curl);

curl_close($curl);
echo $response;





require "uri"
require "net/http"

url = URI("https://api.whoisfreaks.com/v1.0/domain/availability?domain=jfreaks.com&apiKey=API_KEY")

https = Net::HTTP.new(url.host, url.port)
https.use_ssl = true

request = Net::HTTP::Get.new(url)

response = https.request(request)
puts response.read_body





    var requestOptions = {
  method: 'GET',
  redirect: 'follow'
};

fetch("https://api.whoisfreaks.com/v1.0/domain/availability?domain=jfreaks.com&apiKey=API_KEY", requestOptions)
  .then(response => response.text())
  .then(result => console.log(result))
  .catch(error => console.log('error', error));




var client = new RestClient("https://api.whoisfreaks.com/v1.0/domain/availability?domain=jfreaks.com&apiKey=API_KEY");
client.Timeout = -1;
var request = new RestRequest(Method.GET);
IRestResponse response = client.Execute(request);
Console.WriteLine(response.Content);




    package main

import (
  "fmt"
  "net/http"
  "io/ioutil"
)

func main() {

  url := "https://api.whoisfreaks.com/v1.0/domain/availability?domain=jfreaks.com&apiKey=API_KEY"
  method := "GET"

  client := &http.Client {
  }
  req, err := http.NewRequest(method, url, nil)

  if err != nil {
    fmt.Println(err)
    return
  }
  res, err := client.Do(req)
  if err != nil {
    fmt.Println(err)
    return
  }
  defer res.Body.Close()

  body, err := ioutil.ReadAll(res.Body)
  if err != nil {
    fmt.Println(err)
    return
  }
  fmt.Println(string(body))
}




    CURL *curl;
CURLcode res;
curl = curl_easy_init();
if(curl) {
  curl_easy_setopt(curl, CURLOPT_CUSTOMREQUEST, "GET");
  curl_easy_setopt(curl, CURLOPT_URL, "https://api.whoisfreaks.com/v1.0/domain/availability?domain=jfreaks.com&apiKey=API_KEY");
  curl_easy_setopt(curl, CURLOPT_FOLLOWLOCATION, 1L);
  curl_easy_setopt(curl, CURLOPT_DEFAULT_PROTOCOL, "https");
  struct curl_slist *headers = NULL;
  curl_easy_setopt(curl, CURLOPT_HTTPHEADER, headers);
  res = curl_easy_perform(curl);
}
curl_easy_cleanup(curl);





import Foundation
#if canImport(FoundationNetworking)
import FoundationNetworking
#endif

var semaphore = DispatchSemaphore (value: 0)

var request = URLRequest(url: URL(string: "https://api.whoisfreaks.com/v1.0/domain/availability?domain=jfreaks.com&apiKey=API_KEY")!,timeoutInterval: Double.infinity)
request.httpMethod = "GET"

let task = URLSession.shared.dataTask(with: request) { data, response, error in
  guard let data = data else {
    print(String(describing: error))
    semaphore.signal()
    return
  }
  print(String(data: data, encoding: .utf8)!)
  semaphore.signal()
}

task.resume()
semaphore.wait()




FAQs

What is Domain Availability API?

Our Domain Availability API checks if a domain is available for registration or not. It also suggests other domains and their availability for registration.



What is criteria for Domain Suggestions?

Domains are suggested based on a GTLDs that are more popular in terms of higher number of domains registered with that particular TLD.



Not supported domain extension will be charged or not?

No, we don't charge for not supported domain.



How many TLDs are supported by your system?

You can check the current supported TLDs here: list



Do you have notification service when my API credits or requests near to an end?

Yes, we will inform you via an email. We send notification email on 80%,90%,100% usage.



What happened if my API credits or requests are ended and my system is using whois API?

We don't serve surcharge on API credits but API Subscription plans have surcharge service. We will serve you if your credits or requests limit reached until your surcharge allowed request limit reach. Each subscription plan has a different no of surcharge requests.



What is surcharge service?

Whenever your system will consume your API subscription plan quota 100% then we take care and keep on serving you according to your plan surcharge requests. And when your subscription will renew then our system will calculate amount according to surcharge requests consumed and add this amount to the actual plan price.



API Credit plans have surcharge service?

No. We don't serve when API credit plans have reached their request limit.