Reputation: 47
My requirement is to get country name by device Ip. Without any WEB/API calls. I googled well but I cannot conclude anything. We have good free service MaxMind but it provides CSV format as well its very huge in file size. Do we have any suggested way.? We should not use location based service like GPS/Network Provider..?
please helps me to fix this out..
Upvotes: 2
Views: 7045
Reputation: 51
You can use https://ipstack.com/
http://freegeoip.net/ is change to http://freegeoip.net/ is very simple and useful. Its implementation with volley in android is very easy
Upvotes: 0
Reputation: 1457
You can consider IPInfoDB API http://www.ipinfodb.com
It is fast API using data delivery network (DDN). It allows 2 connections per second by default.
http://api.ipinfodb.com/v3/ip-city/?key=your_api_key&ip=74.125.45.100
Upvotes: 0
Reputation: 1385
You can use http://freegeoip.net/
It allows up to 10,000 queries per hour by default.
It uses json parsing you can easily implement
For ex: http://freegeoip.net/json/github.com
gives this
{"ip":"192.30.252.130","country_code":"US","country_name":"United States","region_code":"CA","region_name":"California","city":"San Francisco","zip_code":"94107","time_zone":"America/Los_Angeles","latitude":37.77,"longitude":-122.394,"metro_code":807}
with Country Code and Country Name
Upvotes: 6