WhoisFreaks Docs

Databases - DNS

Section: Databases

DNS database snapshots

3 endpoints. Requests need your API key unless noted otherwise. See Authentication.

DNS Database Daily

GET https://files.whoisfreaks.com/v3.2/download/dbupdate/daily/dns

DNS Database Daily. Returns the file/snapshot described by this operation.

Parameters

Parameter In Required Type Default Description
date query no string (date)   yyyy-MM-dd; omit for latest

Usage

Python ```python """DNS Database Daily: GET https://files.whoisfreaks.com/v3.2/download/dbupdate/daily/dns Run it with your API key in the environment: WHOISFREAKS_API_KEY=your_api_key python DbDnsDaily.py """ import os from datetime import date import whoisfreaks config = whoisfreaks.Configuration() config.api_key["ApiKeyAuth"] = os.environ["WHOISFREAKS_API_KEY"] # set once for every request with whoisfreaks.ApiClient(config) as client: api = whoisfreaks.DatabasesDNSApi(client) # db_dns_daily parameters: # var_date (datetime.date, optional, keyword): yyyy-MM-dd; omit for latest data = api.db_dns_daily(var_date=date(2026, 10, 1)) # the file's raw bytes path = "DbDnsDaily.csv" with open(path, "wb") as f: f.write(data) print(f"Saved {len(data)} bytes to {os.path.abspath(path)}") ```
TypeScript ```typescript // DNS Database Daily: GET https://files.whoisfreaks.com/v3.2/download/dbupdate/daily/dns // Run: WHOISFREAKS_API_KEY=your_api_key npx tsx DbDnsDaily.ts import { writeFile } from "node:fs/promises"; import { resolve } from "node:path"; import { Configuration, DatabasesDNSApi, ResponseError } from "whoisfreaks"; // Set the API key once; the client adds it to every request. const config = new Configuration({ apiKey: process.env.WHOISFREAKS_API_KEY }); const api = new DatabasesDNSApi(config); // dbDnsDaily({ date? }) // date (Date, optional): yyyy-MM-dd; omit for latest async function main(): Promise { const blob = await api.dbDnsDaily({ date: new Date("2026-10-01") }); // a Blob with the file's bytes const file = "DbDnsDaily.csv"; await writeFile(file, new Uint8Array(await blob.arrayBuffer())); console.log(`Saved ${blob.size} bytes to ${resolve(file)}`); } main().catch(async (err: unknown) => { // API errors carry the HTTP response if (err instanceof ResponseError) { console.error(`HTTP ${err.response.status}: ${await err.response.text()}`); } else { console.error(err); } process.exitCode = 1; }); ``` </details>
Go ```go // Runnable example: DNS Database Daily (GET /v3.2/download/dbupdate/daily/dns) // Run it from the Getting Started module: save it as main.go, then `go run .` // Parameters for dbDnsDaily (GET /v3.2/download/dbupdate/daily/dns): // - date (string, optional): yyyy-MM-dd; omit for latest package main import ( "context" "fmt" "io" "log" "os" "path/filepath" whoisfreaks "github.com/WhoisFreaks/whoisfreaks-go" ) func main() { // Set the API key once on the context; every call made with ctx sends it. ctx := context.WithValue(context.Background(), whoisfreaks.ContextAPIKeys, map[string]whoisfreaks.APIKey{"ApiKeyAuth": {Key: os.Getenv("WHOISFREAKS_API_KEY")}}) client := whoisfreaks.NewAPIClient(whoisfreaks.NewConfiguration()) file, _, err := client.DatabasesDNSAPI.DbDnsDaily(ctx).Date("2026-10-01").Execute() if err != nil { log.Fatal(err) } // The SDK saves the response to a temporary file: copy it to its destination. defer os.Remove(file.Name()) defer file.Close() out, err := os.Create("DbDnsDaily.csv") if err != nil { log.Fatal(err) } defer out.Close() n, err := io.Copy(out, file) if err != nil { log.Fatal(err) } path, _ := filepath.Abs(out.Name()) fmt.Printf("Saved %d bytes to %s\n", n, path) } ```
--- ## DNS Database Weekly `GET https://files.whoisfreaks.com/v3.2/download/dbupdate/weekly/dns` DNS Database Weekly. Returns the file/snapshot described by this operation. **Parameters** | Parameter | In | Required | Type | Default | Description | |-----------|----|----------|------|---------|-------------| | `date` | query | no | string (date) | | yyyy-MM-dd; omit for latest | **Usage**
Python ```python """DNS Database Weekly: GET https://files.whoisfreaks.com/v3.2/download/dbupdate/weekly/dns Run it with your API key in the environment: WHOISFREAKS_API_KEY=your_api_key python DbDnsWeekly.py """ import os from datetime import date import whoisfreaks config = whoisfreaks.Configuration() config.api_key["ApiKeyAuth"] = os.environ["WHOISFREAKS_API_KEY"] # set once for every request with whoisfreaks.ApiClient(config) as client: api = whoisfreaks.DatabasesDNSApi(client) # db_dns_weekly parameters: # var_date (datetime.date, optional, keyword): yyyy-MM-dd; omit for latest data = api.db_dns_weekly(var_date=date(2026, 10, 1)) # the file's raw bytes path = "DbDnsWeekly.csv" with open(path, "wb") as f: f.write(data) print(f"Saved {len(data)} bytes to {os.path.abspath(path)}") ```
TypeScript ```typescript // DNS Database Weekly: GET https://files.whoisfreaks.com/v3.2/download/dbupdate/weekly/dns // Run: WHOISFREAKS_API_KEY=your_api_key npx tsx DbDnsWeekly.ts import { writeFile } from "node:fs/promises"; import { resolve } from "node:path"; import { Configuration, DatabasesDNSApi, ResponseError } from "whoisfreaks"; // Set the API key once; the client adds it to every request. const config = new Configuration({ apiKey: process.env.WHOISFREAKS_API_KEY }); const api = new DatabasesDNSApi(config); // dbDnsWeekly({ date? }) // date (Date, optional): yyyy-MM-dd; omit for latest async function main(): Promise { const blob = await api.dbDnsWeekly({ date: new Date("2026-10-01") }); // a Blob with the file's bytes const file = "DbDnsWeekly.csv"; await writeFile(file, new Uint8Array(await blob.arrayBuffer())); console.log(`Saved ${blob.size} bytes to ${resolve(file)}`); } main().catch(async (err: unknown) => { // API errors carry the HTTP response if (err instanceof ResponseError) { console.error(`HTTP ${err.response.status}: ${await err.response.text()}`); } else { console.error(err); } process.exitCode = 1; }); ``` </details>
Go ```go // Runnable example: DNS Database Weekly (GET /v3.2/download/dbupdate/weekly/dns) // Run it from the Getting Started module: save it as main.go, then `go run .` // Parameters for dbDnsWeekly (GET /v3.2/download/dbupdate/weekly/dns): // - date (string, optional): yyyy-MM-dd; omit for latest package main import ( "context" "fmt" "io" "log" "os" "path/filepath" whoisfreaks "github.com/WhoisFreaks/whoisfreaks-go" ) func main() { // Set the API key once on the context; every call made with ctx sends it. ctx := context.WithValue(context.Background(), whoisfreaks.ContextAPIKeys, map[string]whoisfreaks.APIKey{"ApiKeyAuth": {Key: os.Getenv("WHOISFREAKS_API_KEY")}}) client := whoisfreaks.NewAPIClient(whoisfreaks.NewConfiguration()) file, _, err := client.DatabasesDNSAPI.DbDnsWeekly(ctx).Date("2026-10-01").Execute() if err != nil { log.Fatal(err) } // The SDK saves the response to a temporary file: copy it to its destination. defer os.Remove(file.Name()) defer file.Close() out, err := os.Create("DbDnsWeekly.csv") if err != nil { log.Fatal(err) } defer out.Close() n, err := io.Copy(out, file) if err != nil { log.Fatal(err) } path, _ := filepath.Abs(out.Name()) fmt.Printf("Saved %d bytes to %s\n", n, path) } ```
--- ## DNS Database Monthly `GET https://files.whoisfreaks.com/v3.2/download/dbupdate/monthly/dns` DNS Database Monthly. Returns the file/snapshot described by this operation. **Parameters** | Parameter | In | Required | Type | Default | Description | |-----------|----|----------|------|---------|-------------| | `date` | query | no | string (date) | | yyyy-MM-dd; omit for latest | **Usage**
Python ```python """DNS Database Monthly: GET https://files.whoisfreaks.com/v3.2/download/dbupdate/monthly/dns Run it with your API key in the environment: WHOISFREAKS_API_KEY=your_api_key python DbDnsMonthly.py """ import os from datetime import date import whoisfreaks config = whoisfreaks.Configuration() config.api_key["ApiKeyAuth"] = os.environ["WHOISFREAKS_API_KEY"] # set once for every request with whoisfreaks.ApiClient(config) as client: api = whoisfreaks.DatabasesDNSApi(client) # db_dns_monthly parameters: # var_date (datetime.date, optional, keyword): yyyy-MM-dd; omit for latest data = api.db_dns_monthly(var_date=date(2026, 10, 1)) # the file's raw bytes path = "DbDnsMonthly.csv" with open(path, "wb") as f: f.write(data) print(f"Saved {len(data)} bytes to {os.path.abspath(path)}") ```
TypeScript ```typescript // DNS Database Monthly: GET https://files.whoisfreaks.com/v3.2/download/dbupdate/monthly/dns // Run: WHOISFREAKS_API_KEY=your_api_key npx tsx DbDnsMonthly.ts import { writeFile } from "node:fs/promises"; import { resolve } from "node:path"; import { Configuration, DatabasesDNSApi, ResponseError } from "whoisfreaks"; // Set the API key once; the client adds it to every request. const config = new Configuration({ apiKey: process.env.WHOISFREAKS_API_KEY }); const api = new DatabasesDNSApi(config); // dbDnsMonthly({ date? }) // date (Date, optional): yyyy-MM-dd; omit for latest async function main(): Promise { const blob = await api.dbDnsMonthly({ date: new Date("2026-10-01") }); // a Blob with the file's bytes const file = "DbDnsMonthly.csv"; await writeFile(file, new Uint8Array(await blob.arrayBuffer())); console.log(`Saved ${blob.size} bytes to ${resolve(file)}`); } main().catch(async (err: unknown) => { // API errors carry the HTTP response if (err instanceof ResponseError) { console.error(`HTTP ${err.response.status}: ${await err.response.text()}`); } else { console.error(err); } process.exitCode = 1; }); ``` </details>
Go ```go // Runnable example: DNS Database Monthly (GET /v3.2/download/dbupdate/monthly/dns) // Run it from the Getting Started module: save it as main.go, then `go run .` // Parameters for dbDnsMonthly (GET /v3.2/download/dbupdate/monthly/dns): // - date (string, optional): yyyy-MM-dd; omit for latest package main import ( "context" "fmt" "io" "log" "os" "path/filepath" whoisfreaks "github.com/WhoisFreaks/whoisfreaks-go" ) func main() { // Set the API key once on the context; every call made with ctx sends it. ctx := context.WithValue(context.Background(), whoisfreaks.ContextAPIKeys, map[string]whoisfreaks.APIKey{"ApiKeyAuth": {Key: os.Getenv("WHOISFREAKS_API_KEY")}}) client := whoisfreaks.NewAPIClient(whoisfreaks.NewConfiguration()) file, _, err := client.DatabasesDNSAPI.DbDnsMonthly(ctx).Date("2026-10-01").Execute() if err != nil { log.Fatal(err) } // The SDK saves the response to a temporary file: copy it to its destination. defer os.Remove(file.Name()) defer file.Close() out, err := os.Create("DbDnsMonthly.csv") if err != nil { log.Fatal(err) } defer out.Close() n, err := io.Copy(out, file) if err != nil { log.Fatal(err) } path, _ := filepath.Abs(out.Name()) fmt.Printf("Saved %d bytes to %s\n", n, path) } ```
---