canonical: https://jentic.com/apis/ipapi.com/ipapi

# ipapi - IP Geolocation API

ipapi is a hosted IP geolocation service that resolves IPv4 and IPv6 addresses to country, region, city, latitude and longitude, time zone, currency, and connection details. The API exposes three endpoints: a requester-IP lookup, a single-IP lookup, and a bulk lookup that resolves several IPs in one comma-separated request. It is a long-standing alternative for teams that want an HTTPS-only geolocation surface with currency and time-zone fields built into the response.

## For AI agents

Resolve an IP address to country, city, time zone, currency, and connection details so an agent can enrich logs or personalise content by location.

## Scope

Does not handle proxy or VPN detection, domain WHOIS, or threat intelligence - use for IP geolocation, currency, and time-zone lookups only.

## Capabilities

- Resolve any IPv4 or IPv6 address to country, region, city, and ZIP code
- Geolocate the requesting IP without supplying it explicitly via /check
- Bulk lookup several IPs in one call by comma-separating them in the path
- Return time zone, current local time, and GMT offset for an IP
- Surface the local currency code, name, and symbol alongside the geolocation
- Pull connection details such as ASN, ISP, and connection type for an IP

## Use cases

### Currency and Locale Personalisation

E-commerce and SaaS sites can call /check on a request to detect the visitor's country, currency, and time zone in one call, then pre-fill the currency selector and apply locale-specific copy. Bundling currency into the geolocation response avoids a second lookup against a separate ISO data source.

Example prompt: Call /check with no IP from the server-side handler and pre-fill the currency selector with the returned currency_code.

### Time Zone-Aware Scheduling

Scheduling and notification platforms can resolve a user's IP to a time zone and local time, then schedule emails or push notifications for a sensible local hour. The response includes the IANA time zone id and the GMT offset so the scheduler does not have to look them up separately.

Example prompt: Look up an IP and return the IANA time zone id along with the next local 09:00 timestamp for a notification.

### Bulk Log Enrichment

Operations teams can pass several IPs at once via the bulk endpoint to enrich access logs or audit traces with country, city, ISP, and ASN, which is cheaper than firing one request per IP. The response is keyed by IP so the result merges back into the source row easily.

Example prompt: Bulk-resolve 10 IPs from a log row and return country, city, and ISP for each.

### Agent-Driven Visitor Insight

An AI agent connected via Jentic can call /check on a request handler, read the country, currency, and time zone, and pick the right localisation rules without the developer wiring three look-up libraries. The agent searches Jentic by intent rather than juggling ipapi's three endpoints by hand.

Example prompt: On a request handler, call ipapi /check via Jentic and return a JSON object with country, currency_code, and timezone.id.

## Key endpoints

| Method | Path | Description |
| --- | --- | --- |
| GET | /check | Geolocate the requesting IP |
| GET | /{ip} | Geolocate a single IP address |
| GET | /{ips} | Bulk geolocate multiple IPs |

## Key resources

- **Requester Lookup** — Geolocate the calling client's IP via /check.
- **Standard Lookup** — Geolocate one IP address via /{ip}.
- **Bulk Lookup** — Geolocate several IPs in one call by comma-separating them in the path.

## Why Jentic

- **Setup:** Wiring ipapi by hand means registering for a key, appending it as the access_key query parameter to api.ipapi.com, and choosing between the single-IP, bulk, and requester-IP paths for each lookup. Through Jentic you install once, import ipapi from the API Directory, store the key once, and your agent calls it.
- **Permission scoping:** ipapi is a set of read-only geolocation lookups where the IP travels in the URL path or as the requester, so scope the agent to the operations it needs, such as geolocating an IP or resolving a batch of IPs. It stays a lookup client and cannot reach anything beyond the operations you allow.
- **Credential handling:** Your ipapi access_key is stored once, encrypted, by your own Jentic One instance and injected as the access_key query parameter at execution time. It never enters the agent's prompt, logs, or context.
- **Discovery method:** Agents search Jentic by intent such as 'geolocate an IP' or 'get currency for a visitor', and Jentic returns the ipapi operation with its input schema, exposing the bulk path when several IPs need resolving in one call, so the agent calls the right endpoint without browsing the docs.

## Related APIs

- **ip-api** — ip-api offers a free no-key tier for non-commercial geolocation lookups.
- **IP2Location.io** — IP2Location.io returns geolocation and bundles proxy and VPN flags into the same response.
- **IP2Proxy** — IP2Proxy adds anonymous proxy, VPN, and TOR detection that ipapi does not classify.

## FAQ

### What authentication does the ipapi API use?

ipapi uses an access_key query parameter on every request. Through Jentic the key is held in the encrypted vault and appended at execution time so the raw key never enters the agent context.

### Can ipapi return the currency for the visitor's country?

Yes. The response includes a currency object with the ISO code, English name, plural name, and symbol alongside the geolocation fields, which is useful for currency selectors and pricing display.

### Can I bulk lookup IPs in one call?

Yes. Comma-separate the IPs in the path (for example /1.1.1.1,8.8.8.8) and ipapi returns an array keyed by IP. This is the recommended pattern for log-enrichment workloads.

### What are the rate limits for the ipapi API?

Free plans cap monthly volume; paid plans raise the cap and unlock HTTPS plus additional response fields. The exact monthly volume per plan is documented at https://ipapi.com and surfaces as quota errors in the response when exhausted.

### How do I geolocate an IP through Jentic?

Search Jentic for 'geolocate an IP with ipapi', load the schema for GET /{ip}, and execute with the ip parameter. Run pip install jentic, then await client.search, await client.load, await client.execute.

### Does ipapi support IPv6?

Yes. The /{ip} endpoint accepts IPv4 and IPv6 addresses and returns the same response shape for both, so an agent can pass either family without branching.

### Can I limit what my agent is allowed to do with the ipapi API?

Yes. Because you self-host Jentic One, your own rules decide which ipapi operations and credentials the agent may use. ipapi is a set of read-only geolocation lookups, so you can scope the agent to only the operations it needs, such as geolocating the requesting IP via /check, resolving a single IP via /{ip}, or bulk-resolving several IPs in one call. It stays a lookup client and cannot reach any operation you have not allowed.
