API & Integrations

Getting Started with the WhoisExtractor API

Everything you need to make your first API call - authentication, product IDs, how the file download works, and common troubleshooting tips.

Getting Started with the WhoisExtractor API
April 11, 2026 API & Integrations WhoisExtractor Team

How the API Works

The WhoisExtractor API does not return WHOIS data as JSON. Instead, each successful request triggers an instant file download - a ZIP archive containing the structured CSV database you requested. Your HTTP client (curl, wget, Python requests) receives the file directly.

Only errors return a JSON body. If your request downloads a file, it worked.

Prerequisites

Before making API calls you need:

  1. A WhoisExtractor account (sign up here if you don't have one)
  2. An active paid plan that includes the product you want to access
  3. Your API key - shown in the API documentation page after you log in

Authentication

Pass your API key as the api query parameter. There are no headers, no OAuth tokens, and no Bearer authentication.

https://get.whoisextractor.com/?api=YOUR_API_KEY&pid=1

Keep your API key private. Never expose it in client-side code or public repositories.

The Single Endpoint

All requests go to one endpoint:

GET https://get.whoisextractor.com/

Parameters:

Parameter Required Description
api Yes Your unique API key
pid Yes Product ID - selects which database file to download
date No YYYY-MM-DD format. Defaults to today. Up to 4 days back.

All dates use India Standard Time (IST, GMT+5:30).

Product IDs

Use the pid parameter to select which database you want:

pid Product
1 India WHOIS Database
7 US WHOIS Database
8 Australia WHOIS Database
3 Daily Full WHOIS Database (global, 50,000–100,000+ domains/day)
6 WHOIS Trial Plan (7 days)
10 Daily Registered Domains API (240K+ new domains/day, 1,570+ TLDs)
11 Website Detailed Daily Data (emails & phones from websites)

Some products are download-only and do not have API access (pid 4, 5, 9). Check the API page for the current status of each product.

Your First Request

Download today's India WHOIS database:

curl "https://get.whoisextractor.com/?api=YOUR_API_KEY&pid=1" \
  --output whois-india-today.zip

Download the global WHOIS database for a specific date:

curl "https://get.whoisextractor.com/?api=YOUR_API_KEY&pid=3&date=2026-04-10" \
  --output whois-global-2026-04-10.zip

A successful request delivers the ZIP file immediately. No JSON, no redirect page.

Code Examples

PHP:

<?php
$apiKey = 'YOUR_API_KEY';
$date   = date('Y-m-d', strtotime('-1 day'));
$url    = "https://get.whoisextractor.com/?api={$apiKey}&pid=3&date={$date}";

$ch = curl_init($url);
$fp = fopen("whois-{$date}.zip", 'wb');
curl_setopt_array($ch, [
    CURLOPT_FILE           => $fp,
    CURLOPT_FOLLOWLOCATION => true,
    CURLOPT_FAILONERROR    => true,
]);
curl_exec($ch);
$httpCode = curl_getinfo($ch, CURLINFO_HTTP_CODE);
curl_close($ch);
fclose($fp);

echo $httpCode === 200 ? "Downloaded whois-{$date}.zip" : "Error: HTTP {$httpCode}";

Python:

import requests

api_key = "YOUR_API_KEY"
date = "2026-04-10"
url = f"https://get.whoisextractor.com/?api={api_key}&pid=3&date={date}"

response = requests.get(url, stream=True)

if response.status_code == 200:
    with open(f"whois-{date}.zip", "wb") as f:
        for chunk in response.iter_content(chunk_size=8192):
            f.write(chunk)
    print(f"Downloaded whois-{date}.zip")
else:
    print(response.json())  # error details as JSON

Error Responses

When a request fails, the API returns a JSON object with an error key. A successful request never returns JSON - it delivers the file directly.

HTTP Code JSON error Meaning
401 "Invalid API key" Wrong or missing api parameter
403 "Access denied" Your plan does not include this pid
404 "No data for this date" Date too old (max 4 days back) or data not yet generated
429 "Rate limit exceeded" Reduce request frequency
500 "Server error" Try again in a few minutes

Data Updates and Schedule

Data is refreshed once per day at 6:00 AM IST. Calling the API more than once per day for the same pid and date returns the same file - no additional data will have been added between calls.

Next Steps

View the full API documentation for the live endpoint tester and an up-to-date product ID list. If you run into issues, open a support ticket.

api getting started authentication integration

Was this article helpful?

Thanks for the feedback! Glad this helped. Thanks for letting us know. Open a support ticket if you need more help.