apyhub
GEOLOCATION

IP ASN Lookup API

What it does

IP ASN Lookup resolves an IP address to the network and registry details exposed by RDAP. Send an ip value and get back the IP, the ASN when available, the ASN registry, the network CIDR, the network name, the ASN description, and the ASN country code.

Use it when you need to identify who operates an address block, map traffic to an upstream network, or enrich security and network telemetry with ownership data. The response is intentionally compact, so it fits neatly into routing, abuse-checking, asset inventory, and analytics workflows.

Because the lookup is based on RDAP, results reflect registry data rather than guessed location or ISP information. That makes it useful for IP reputation checks, incident response triage, and backend tools that need a reliable ASN reference before making a decision.

If the registry does not expose a value, the corresponding field can be null, so you can handle partial results without guessing.

GET
Look up ASN, network CIDR, and registry details for an IP via RDAP
http://localhost:8080/dosvak/ip-asn-lookup
QUICKSTARTGUIDE

Quickstart

Look up the ASN details for a single IP address by passing the ip query parameter.

curl -X GET "http://localhost:8080/dosvak/ip-asn-lookup?ip=8.8.8.8" \
  -H "apy-token: $APY_TOKEN"

What you'll get back

Returns a JSON object with these top-level fields: ip is the IP address looked up, and asn, asn_registry, network_cidr, network_name, asn_description, and asn_country_code are nullable strings with the matching network/ASN information when available.

{
  "ip": "8.8.8.8",
  "asn": "15169",
  "asn_registry": "arin",
  "network_cidr": "8.8.8.0/24",
  "network_name": "GOOGLE",
  "asn_description": "Google LLC",
  "asn_country_code": "US"
}
TRY ITLIVE · 10 ATOMS
Loading your default key…
The full key is used to call the gateway and stays in this tab — never sent to orbit or saved.

About this endpoint

What it does

Looks up RDAP-based ASN and network details for the IP address provided in the query string. The response returns the queried ip plus associated ASN, registry, network CIDR, network name, ASN description, and ASN country code fields when available.

Query Parameter(s)

AttributeTypeMandatoryDescription
ipStringYesIP address to look up.

Response

Returns a JSON object with these top-level string fields: ip, asn, asn_registry, network_cidr, network_name, asn_description, and asn_country_code. The optional fields are nullable in the schema, so they may be null when the RDAP lookup does not provide a value.

ParameterTypeMandatoryDescription
ipStringNoThe IP address that was looked up.
asnStringNoThe ASN associated with the IP, or null if unavailable.
asn_registryStringNoThe registry associated with the ASN, or null if unavailable.
network_cidrStringNoThe network CIDR for the IP, or null if unavailable.
network_nameStringNoThe network name, or null if unavailable.
asn_descriptionStringNoThe ASN description, or null if unavailable.
asn_country_codeStringNoThe ASN country code, or null if unavailable.

Query parameters

Name
Type
Description
ipREQUIRED
string
▣ COMMON ERRORS

Errors any endpoint can return

400bad_request

Required parameter missing or malformed body.

401unauthorized

API key missing, revoked, or not authorized for this service.

429rate_limited

Your plan's per-second rate exceeded. Retry with exponential backoff.

503upstream_busy

Backend temporarily unavailable. Try again in a few seconds.