Returns the city, state and country for an IPv4 or IPv6 address. Authentication via API key.
GET https://geoapi.charotartelelink.com/v1/lookup?ip=8.8.8.8 X-API-Key: YOUR_API_KEY
You can also send Authorization: Bearer YOUR_API_KEY. Several IPs: ?ip=8.8.8.8,1.1.1.1 (max 50).
{
"ip": "8.8.8.8",
"city": "Mountain View",
"state": "California",
"country": "United States",
"country_code": "US",
"attribution": "IP geolocation by DB-IP.com (https://db-ip.com), CC BY 4.0"
}
| HTTP | error |
|---|---|
| 400 | missing_ip, invalid_ip, private_or_reserved_ip, too_many_ips |
| 401 | missing_api_key, invalid_api_key |
| 403 | tenant_suspended, ip_not_allowed |
| 404 | not_found |
| 429 | rate_limited, quota_exceeded |