ip2location/ip2locationio
steampipe plugin install ip2location/ip2locationio

Table: ip2locationio_geolocation

Get location and other information about an IP address. The ip2locationio_geolocation table requires the ip field to be specified in all queries, defining the IP address to lookup.

Examples

Info for a specific IP address

select
country_code,
country_name,
region_name,
city_name
from
ip2locationio_geolocation
where
ip = '8.8.8.8';

Nested info for specific IP address

select
country_code,
country ->> 'capital' as capital_city,
country [ 'translation' ] as translation
from
ip2locationio_geolocation
where
ip = '8.8.8.8'
and lang = 'es';

Schema for ip2locationio_geolocation

NameTypeOperatorsDescription
_ctxjsonbSteampipe context in JSON form, e.g. connection_name.
address_typetextAnycast/Unicast/Multicast/Broadcast.
ads_categorytextDomain category code based on IAB Tech Lab Content Taxonomy.
ads_category_nametextDomain category based on IAB Tech Lab Content Taxonomy.
area_codetextArea code.
astextAutonomous System (AS).
asntextAutonomous System Number (ASN).
cityjsonbCity details.
city_nametextCity name.
continentjsonbContinent details.
countryjsonbCountry details.
country_codetextISO-3166 Country code.
country_nametextCountry name.
districttextDistrict name.
domaintextInternet domain name.
elevationbigintElevation above sea level in meters.
geotargetingjsonbMetro code.
idd_codetextIDD code.
ipinet=IP address to query.
is_proxybooleanTrue if IP a proxy.
isptextInternet Service Provider (ISP).
langtext=Translation language (only for Plus and Security plans).
latitudedouble precisionLatitude.
longitudedouble precisionLongitude.
mcctextMobile Country Codes (MCC) as defined in ITU E.212.
mnctextMobile Network Code (MNC).
mobile_brandtextCommercial brand associated with the mobile carrier.
net_speedtextInternet connection type.
proxyjsonbProxy details.
regionjsonbRegion details.
region_nametextRegion name.
time_zonetextTime zone.
time_zone_infojsonbTime zone details.
usage_typetextUsage type classification of ISP or company.
weather_station_codetextWeather station code.
weather_station_nametextWeather station name.
zip_codetextPostal code.