Skip to content
IP Checker

API

Network diagnostics API for scripts and AI agents

No key, no signup. Plain text when you need one value, compact JSON for tool calls, and a full diagnostic when an agent needs context. Machine-readable docs at /openapi.json and /llms.txt.
Public IP
curl https://ipcheckhq.com/ip
Agent format
curl "https://ipcheckhq.com/api/v1/me?format=agent"
Python
import requests

r = requests.get("https://ipcheckhq.com/api/v1/me", params={"format": "agent"}, timeout=5)
r.raise_for_status()
conn = r.json()
if conn["network_type"] != "residential":
    raise RuntimeError(f"unexpected exit network: {conn}")
JavaScript
const res = await fetch("https://ipcheckhq.com/api/v1/me?fields=ip,country,asn,isp");
const { ip, country, asn, isp } = await res.json();

Agent use cases

  • Check an agent’s outbound public IPGET /ip
  • Verify the country of an automation workerGET /country
  • Check the current ASNGET /asn
  • Check the current ISPGET /isp
  • Confirm a requested country and ASN through a proxycurl -x … /api/v1/me?fields=country,asn
  • Check that a proxy is residentialcurl -x … /api/v1/me?fields=network_type,hosting
  • Look up a customer-reported IPGET /api/v1/ip/{ip}
  • Give a support agent full network contextGET /api/v1/diagnostic
  • Validate a proxy against expectations (planned)POST /api/v1/proxy/validate
  • Test sticky-session stability (planned)POST /api/v1/proxy/session-test

As an agent tool

Wrap the endpoint as a tool. The REST service layer is designed to be exposed through MCP tools later (check_current_ip, lookup_ip, get_connection_diagnostics, and the proxy tools).

Tool definition
{
  "name": "check_current_ip",
  "description": "Return this agent's public IP, country, ASN, ISP and network type.",
  "input_schema": { "type": "object", "properties": {} }
}
// implementation: GET https://ipcheckhq.com/api/v1/me?format=agent

Contract

  • Versioned under /api/v1. Keys are stable; new keys may be added.
  • Unknown values are null, never guessed.
  • Proxy, VPN, Tor and hosting are estimates. Read certainty from confidence (/me) or classification (/diagnostic).
  • Rate limits per IP per minute: 120 for connection endpoints, 30 for lookups, 5 for proxy endpoints.
  • fields allowlist: ip, ip_version, country, country_name, region, city, postal_code, latitude, longitude, timezone, asn, asn_name, isp, organization, network_type, proxy, vpn, tor, hosting, reverse_dns, user_agent, http_version, client_type, timestamp
View API documentation