Geo & Location Toolkit

12 endpoints for IP intelligence, geographic calculations, timezone conversion, country and currency lookups, and phone number validation.

Base URL

https://geo.toolkitapi.io/v1/

Endpoints

IP Intelligence

Endpoint Description
GET /v1/geo/ip-lookup Resolve IP to city, region, country, coordinates, ASN
GET /v1/geo/ip-threat Detect VPN, proxy, Tor, and datacenter IPs

Geographic Math

Endpoint Description
POST /v1/geo/distance Distance along a chain of lat/lon points (Haversine or Vincenty)
POST /v1/geo/bounding-box Bounding box from a center point and radius
POST /v1/geo/center Geographic centroid of multiple coordinates

Location Data

Endpoint Description
GET /v1/geo/country-info Country details by ISO alpha-2 code (capital, currency, languages, flag)
GET /v1/geo/currency-info Currency details by ISO 4217 code (symbol, decimals, countries)

Timezones

Endpoint Description
GET /v1/geo/timezone-convert Convert an ISO 8601 timestamp between IANA timezones
GET /v1/geo/timezone-by-coords IANA timezone name for a lat/lon pair
GET /v1/geo/timezone-info UTC offset, DST status, and local time for a timezone

Phone Validation

Endpoint Description
GET /v1/geo/phone-validate Parse and validate a phone number; returns E.164, carrier, line type
POST /v1/geo/phone-validate-batch Validate up to 50 phone numbers in one request

Quick Examples

# IP geolocation
curl "https://geo.toolkitapi.io/v1/geo/ip-lookup?ip=8.8.8.8" \
  -H "X-API-Key: YOUR_KEY"
{
  "ip": "8.8.8.8",
  "country": "United States",
  "country_code": "US",
  "city": "Mountain View",
  "region": "California",
  "latitude": 37.386,
  "longitude": -122.0838,
  "asn": "AS15169",
  "org": "Google LLC"
}
# Timezone conversion
curl "https://geo.toolkitapi.io/v1/geo/timezone-convert?timestamp=2026-06-01T09:00:00&from=America/New_York&to=Europe/London" \
  -H "X-API-Key: YOUR_KEY"
from toolkitapi import Geo

with Geo(api_key="tk_...") as geo:
    # IP lookup
    loc = geo.ip_lookup("8.8.8.8")
    print(loc["city"], loc["country_code"])

    # Distance between two cities
    result = geo.distance(
        [{"lat": 51.5074, "lon": -0.1278}, {"lat": 48.8566, "lon": 2.3522}],
        unit="km",
    )
    print(result["total_distance"], "km")  # ~341 km

Tip

All IP intelligence endpoints accept both IPv4 and IPv6 addresses. Private, loopback, and reserved addresses return a 400 error — only public IPs can be geolocated.