1、太平洋网络IP查询接口
a、根据ip查询: http://whois.pconline.com.cn/ipJson.jsp?json=true&ip=14.16.139.216
{
"ip":"14.16.139.216",
"pro":"广东省",
"proCode":"440000",
"city":"广州市",
"cityCode":"440100",
"region":"",
"regionCode":"0",
"addr":"广东省广州市 电信",
"regionNames":"",
"err":""
}
b、客户端查询: http://whois.pconline.com.cn/ipJson.jsp?json=true
{
"ip":"113.108.110.26",
"pro":"广东省",
"proCode":"440000",
"city":"深圳市",
"cityCode":"440300",
"region":"",
"regionCode":"0",
"addr":"广东省深圳市 电信",
"regionNames":"",
"err":""
}
2、国外IP查询接口(返回英文)
a、根据ip查询: http://ip-api.com/json/14.16.139.216
{
"as":"AS4134 No.31,Jin-rong Street",
"city":"Guangzhou",
"country":"China",
"countryCode":"CN",
"isp":"China Telecom Guangdong",
"lat":23.1167,
"lon":113.25,
"org":"China Telecom Guangdong",
"query":"14.16.139.216",
"region":"GD",
"regionName":"Guangdong",
"status":"success",
"timezone":"Asia/Shanghai",
"zip":""
}
b、客户端查询: http://ip-api.com/json/
{
"as":"AS4134 No.31,Jin-rong Street",
"city":"Shenzhen",
"country":"China",
"countryCode":"CN",
"isp":"China Telecom Guangdong",
"lat":22.5333,
"lon":114.1333,
"org":"China Telecom Guangdong",
"query":"113.108.110.26",
"region":"GD",
"regionName":"Guangdong",
"status":"success",
"timezone":"Asia/Shanghai",
"zip":""
}
参考api: http://ip-api.com/docs/api:json
3、apnic
a、根据ip查询: http://www.geoplugin.net/json.gp/14.16.139.216
{
"geoplugin_request":"113.108.110.26",
"geoplugin_status":200,
"geoplugin_delay":"2ms",
"geoplugin_credit":"Some of the returned data includes GeoLite data created by MaxMind, available from http://www.maxmind.com.",
"geoplugin_city":"Shenzhen",
"geoplugin_region":"Guangdong",
"geoplugin_regionCode":"GD",
"geoplugin_regionName":"Guangdong",
"geoplugin_areaCode":"",
"geoplugin_dmaCode":"",
"geoplugin_countryCode":"CN",
"geoplugin_countryName":"China",
"geoplugin_inEU":0,
"geoplugin_euVATrate":false,
"geoplugin_continentCode":"AS",
"geoplugin_continentName":"Asia",
"geoplugin_latitude":"22.5333",
"geoplugin_longitude":"114.1333",
"geoplugin_locationAccuracyRadius":"100",
"geoplugin_timezone":"Asia/Shanghai",
"geoplugin_currencyCode":"CNY",
"geoplugin_currencySymbol":"元",
"geoplugin_currencySymbol_UTF8":"元",
"geoplugin_currencyConverter":6.8651
}
b、客户端查询: http://www.geoplugin.net/json.gp
{
"geoplugin_request":"113.108.110.26",
"geoplugin_status":200,
"geoplugin_delay":"2ms",
"geoplugin_credit":"Some of the returned data includes GeoLite data created by MaxMind, available from http://www.maxmind.com.",
"geoplugin_city":"Shenzhen",
"geoplugin_region":"Guangdong",
"geoplugin_regionCode":"GD",
"geoplugin_regionName":"Guangdong",
"geoplugin_areaCode":"",
"geoplugin_dmaCode":"",
"geoplugin_countryCode":"CN",
"geoplugin_countryName":"China",
"geoplugin_inEU":0,
"geoplugin_euVATrate":false,
"geoplugin_continentCode":"AS",
"geoplugin_continentName":"Asia",
"geoplugin_latitude":"22.5333",
"geoplugin_longitude":"114.1333",
"geoplugin_locationAccuracyRadius":"100",
"geoplugin_timezone":"Asia/Shanghai",
"geoplugin_currencyCode":"CNY",
"geoplugin_currencySymbol":"元",
"geoplugin_currencySymbol_UTF8":"元",
"geoplugin_currencyConverter":6.8651
}
参考地址api: http://ip138.com/ips138.asp
4、搜狐IP查询接口
客户端查询: http://pv.sohu.com/cityjson?ie=utf-8
var returnCitySN = {"cip": "113.108.110.26", "cid": "440300", "cname": "广东省深圳市"};
5、126IP查询接口
客户端查询: http://ip.ws.126.net/ipquery
var lo="广东省", lc="深圳市"; var localAddress={city:"深圳市", province:"广东省"}
6、百度地图IP定位API
a、根据ip查询: https://api.map.baidu.com/location/ip?ak=32f38c9491f2da9eb61106aaab1e9739&ip=14.16.139.216
b、客户端查询: https://api.map.baidu.com/location/ip?ak=32f38c9491f2da9eb61106aaab1e9739
说明: 需要传入ak参数(不清楚是否免费)
免费参考
a、阿凡达数据: https://www.avatardata.cn/docs/api/a5e61fce-b65e-49ef-896f-1a682218a054
b、百度opendata: http://opendata.baidu.com/api.php?query=42.196.245.48&co=&resource_id=6006&t=1412300361645&ie=utf8&oe=gbk&cb=op_aladdin_callback&format=json&tn=baidu
c、IP GEO 地理位置API: https://www.boip.net/api/
d、JsonBird: https://bird.ioliu.cn/#interface
e、Webscan查询接口API: http://www.webscan.cc/api/
免费天气API : https://www.sojson.com/blog/234.html