IP Geolocation API
GET /api/geo $0.001 per call
USDC on Base · x402
IP geolocation: country, region, city, coordinates, and timezone for any IPv4 or IPv6 address. Fast in-memory lookup for analytics, fraud, and personalization agents.
Parameters
| Name | In | Description | |
|---|---|---|---|
ip | query | IPv4 or IPv6 address to locate. Omit to geolocate the caller. |
Example request
curl "https://api.webbersites.com/api/geo?ip=8.8.8.8"
# first call returns 402 + payment requirements; an x402 client pays and retries automaticallyExample response
{
"ip": "8.8.8.8",
"country": "US",
"region": "CA",
"city": "Mountain View",
"timezone": "America/Los_Angeles",
"ll": [
37.4056,
-122.0775
]
}MCP tool: get_geo — via npx -y webbersites-x402-mcp (local, key stays on your machine) or the remote endpoint https://api.webbersites.com/mcp.
How payment works
There is no signup and no API key. Call the endpoint; it replies 402 Payment Required with machine-readable payment requirements. Your client signs a USDC transfer authorization (EIP-3009, gasless) and retries with the X-PAYMENT header — @x402/fetch does this automatically. See the overview for a working snippet.