module EasyGeoIP::API::Nekudo
Private Class Methods
standardize_geodata(json)
click to toggle source
# File lib/easy_geoip/api/nekudo.rb, line 14 def self.standardize_geodata(json) { ip: json["ip"], country: json["country"]["name"], country_code: json["country"]["code"], city: json["city"], latitude: json["location"]["latitude"], longitude: json["location"]["longitude"], time_zone: json["location"]["time_zone"] } end
url(ip)
click to toggle source
# File lib/easy_geoip/api/nekudo.rb, line 10 def self.url(ip) "http://geoip.nekudo.com/api/#{ip}" end