name.ai

Name.ai developer portal / API

Name.ai API docs

The Name.ai API is a public REST surface for domain search and availability, WHOIS lookup, TLD registration pricing and requirements, and marketplace listings. Every endpoint below works without an account or an API key. The machine-readable contract is an OpenAPI 3.1 document at thenamesmarket.com/openapi.json.

Endpoints

MethodPathWhat it returns
POST/api/domain/searchCheck whether a domain is available, with alternate-TLD siblings for the same label.
POST/api/tools/whoisWHOIS/RDAP registration details: registrar, registrant, dates, nameservers.
GET/api/pricing/tldCurrent USD price to register, renew, transfer or restore on a given TLD.
GET/api/tlds/{tld}/metadataRegistration requirements for a TLD: term range, organization and nameserver rules.
GET/api/market/listingsBrowse aftermarket listings. Follow page.next_cursor, or page by offset.
POST/api/batchUp to 20 of the reads above in one request. GET the same path for the catalogue.
POST/api/domains/bulk/{op}Apply one operation to up to 1,000 domains you own (signed-in).

Calling the Name.ai API

One request, no setup:

curl -s https://thenamesmarket.com/api/pricing/tld?tld=ai

curl -s -X POST https://thenamesmarket.com/api/domain/search \
  -H 'Content-Type: application/json' \
  -d '{"q":"example.ai"}'

# Several lookups, one round trip
curl -s -X POST https://thenamesmarket.com/api/batch \
  -H 'Content-Type: application/json' \
  -d '{"operations":[
        {"id":"a","op":"search_domain","params":{"q":"acme.ai"}},
        {"id":"b","op":"tld_registration_price","params":{"tld":"ai","op":"register"}},
        {"id":"c","op":"whois_lookup","params":{"domain":"example.com"}}
      ]}'

Conventions

Name.ai SDKs

Official, zero-dependency clients for the endpoints above. Both cover cursor paging and batching, and both work with no account.

npm install nameai-sdk     # JavaScript / TypeScript, Node >= 18
pip install nameai         # Python >= 3.9
import NameAI from 'nameai-sdk';

const nameai = new NameAI();
const { priceCents } = await nameai.tldPrice('ai', 'register');
for await (const listing of nameai.listAllListings({ tld: 'ai' })) {
  console.log(listing.domain);
}

Source for both: github.com/namekart/nameai_mcp (sdk/ and sdk-python/). They are hand-written rather than generated: six read endpoints do not need a generated transport layer, and a thin client is easier to read than the spec it came from.

Related Name.ai developer resources

Name.ai API Docs — REST Endpoints and OpenAPI 3.1 Spec