list_tlds
Lists available top-level domain categories and their contents to help users explore TLD options for domain registration.
Instructions
List available TLD categories and their contents.
Tool call template
This tool declares no required parameters. Add optional parameters from the input schema as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {},
"name": "list_tlds"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| category | No | Category to list. Default: all |
Implementation Reference
- src/index.ts:247-278 (handler)The handler function that executes the list_tlds tool logic, accepting a category argument and returning the appropriate TLD lists (general, tech, country, or all).
case "list_tlds": { const category = (args?.category as string) || "all"; let result: Record<string, string[]>; switch (category) { case "general": result = { general: POPULAR_TLDS }; break; case "tech": result = { tech: TECH_TLDS }; break; case "country": result = { country: COUNTRY_TLDS }; break; case "all": default: result = { general: POPULAR_TLDS, tech: TECH_TLDS, country: COUNTRY_TLDS, }; } return { content: [ { type: "text", text: JSON.stringify(result, null, 2), }, ], }; } - src/index.ts:90-103 (schema)The tool schema definition that defines the input parameters for list_tlds, including the category enum (general, tech, country, all).
{ name: "list_tlds", description: "List available TLD categories and their contents.", inputSchema: { type: "object" as const, properties: { category: { type: "string", enum: ["general", "tech", "country", "all"], description: "Category to list. Default: all", }, }, }, }, - src/domain-checker.ts:33-50 (helper)General TLD list constant used by list_tlds handler for the 'general' category.
export const POPULAR_TLDS = [ "com", "net", "org", "io", "co", "dev", "app", "ai", "xyz", "me", "info", "biz", "tech", "online", "site", "cloud", ]; - src/domain-checker.ts:53-69 (helper)Country-code TLD list constant used by list_tlds handler for the 'country' category.
export const COUNTRY_TLDS = [ "uk", "de", "fr", "nl", "es", "it", "pl", "ru", "jp", "cn", "au", "ca", "us", "in", "br", ]; - src/domain-checker.ts:72-83 (helper)Tech-focused TLD list constant used by list_tlds handler for the 'tech' category.
export const TECH_TLDS = [ "io", "dev", "app", "ai", "tech", "cloud", "software", "systems", "digital", "code", ];