1、淘宝API接口:
文档:http://ip.taobao.com/instructions
示例:
GET http://ip.taobao.com/outGetIpInfo?ip=221.218.209.125&accessKey=alibaba-inc { data: { area: "", country: "中国", isp_id: "100026", queryIp: "221.218.209.125", city: "北京", ip: "221.218.209.125", isp: "联通", county: "", region_id: "110000", area_id: "", county_id: null, region: "北京", country_id: "CN", city_id: "110100" }, msg: "query success", code: 0 }
2、IP-API接口:
文档:https://ip-api.com/docs/api:json
示例:
GET http://ip-api.com/json/221.218.209.125?lang=zh-CN { status: "success", country: "中国", countryCode: "CN", region: "BJ", regionName: "北京市", city: "北京", zip: "", lat: 39.9285, lon: 116.385, timezone: "Asia/Shanghai", isp: "China Unicom Beijing Province Network", org: "", as: "AS4808 China Unicom Beijing Province Network", query: "221.218.209.125" }
3、太平洋IP接口:
文档:http://whois.pconline.com.cn/
示例:
GET http://whois.pconline.com.cn/ipJson.jsp?ip=221.218.209.125&json=true { ip: "221.218.209.125", pro: "北京市", proCode: "110000", city: "北京市", cityCode: "110000", region: "海淀区", regionCode: "110108", addr: "北京市海淀区 联通ADSL", regionNames: "", err: "" }
参考