# IP Geolocation API
> Geolocate any IPv4 or IPv6 address — country, region, city, postal code, latitude/longitude, timezone, calling code, currency and network details (ASN, ISP, organization). Look up any address or detect the caller's own public IP.

## Authentication
All requests require your oanor API key in the `x-oanor-key` header. Get one at https://www.oanor.com/developer/keys.

```bash
curl -H "x-oanor-key: oanor_live_…" "https://api.oanor.com/ipgeo-api/..."
```

## Pricing
- **Free** (Free) — 5,000 calls/Mo, 2 req/s
- **Basic** ($12/Mo) — 50,000 calls/Mo, 15 req/s
- **Pro** ($39/Mo) — 250,000 calls/Mo, 30 req/s
- **Mega** ($99/Mo) — 1,000,000 calls/Mo, 60 req/s

## Endpoints

### Geolocation

#### `GET /v1/check` — Geolocate the caller's own public IP

**Example:**
```bash
curl -H "x-oanor-key: $KEY" \
  "https://api.oanor.com/ipgeo-api/v1/check"
```

**Response:**
```json
{
    "data": {
        "ip": "178.105.17.60",
        "city": "Gunzenhausen",
        "type": "IPv4",
        "is_eu": true,
        "postal": "91710",
        "region": "Bavaria",
        "source": "ipwho.is",
        "country": "Germany",
        "currency": null,
        "flag_img": "https://cdn.ipwhois.io/flags/de.svg",
        "latitude": 49.1200802,
        "timezone": "Europe/Berlin",
        "continent": "Europe",
        "longitude": 10.7318864,
        "connection": {
            "asn": 24940,
            "isp": "Hetzner Online GmbH",
            "org": "CLOUD NBG1",
            "domain": "hetzner.de"
        },
        "flag_emoji": "🇩🇪",
        "utc_offset": "+02:00",
        "region_code": "BY",
        "calling_code": "+49",
        "country_code": "DE",
        "continent_code": "EU"
    },
    "meta": {
        "timestamp": "2026-05-29T21:28:58.851Z",
        "request_id": "636fcbd5-4df0-4249-9564-d1c452dd86b9"
    },
    "status": "ok",
    "message": "Caller IP geolocation retrieved successfully",
    "success": true
}
```

#### `GET /v1/lookup` — Geolocate any IPv4/IPv6 address

**Parameters:**
- `ip` (query, required, string) — IPv4 or IPv6 address Example: `8.8.8.8`

**Example:**
```bash
curl -H "x-oanor-key: $KEY" \
  "https://api.oanor.com/ipgeo-api/v1/lookup?ip=8.8.8.8"
```

**Response:**
```json
{
    "data": {
        "ip": "8.8.8.8",
        "city": "Mountain View",
        "type": "IPv4",
        "is_eu": false,
        "postal": "94039",
        "region": "California",
        "source": "ipwho.is",
        "country": "United States",
        "currency": null,
        "flag_img": "https://cdn.ipwhois.io/flags/us.svg",
        "latitude": 37.3860517,
        "timezone": "America/Los_Angeles",
        "continent": "North America",
        "longitude": -122.0838511,
        "connection": {
            "asn": 15169,
            "isp": "Google LLC",
            "org": "Google LLC",
            "domain": "google.com"
        },
        "flag_emoji": "🇺🇸",
        "utc_offset": "-07:00",
        "region_code": "CA",
        "calling_code": "+1",
        "country_code": "US",
        "continent_code": "NA"
    },
    "meta": {
        "timestamp": "2026-05-29T21:28:59.364Z",
        "request_id": "dcbcb32d-079d-4b1d-8bb1-bd9ae7e81c30"
    },
    "status": "ok",
    "message": "IP geolocation retrieved successfully",
    "success": true
}
```


---
Marketplace page: https://www.oanor.com/api/ipgeo-api
OpenAPI spec: https://www.oanor.com/api/ipgeo-api/openapi.json
