12 ms·
Show HN: A New, Clean Geolocation API
- kharms 9y agoYou should include the free plan on the pricing page.
- eitland 9y ago> What is the free plan rate limit? Landing page said 1500 I think.
- jonathan-kosgei 9y agoThat's probably what's causing the confusion, thanks. Adding that right now..
- jonathan-kosgei 9y agoI've added a note before the pricing plans emphasizing the free plan.
- _Codemonkeyism 9y ago"Free IP Geolocation API" vs. "Choose Your Pricing Plan" What Geo IP service would people suggest instead?
- ddorian43 9y agoMaxmind
- jonathan-kosgei 9y agoI think the freemium model is pretty common in Saas. And I think a free tier of 45 000 requests a month, 1500 per day is pretty generous. Anything running as a hobby app/side project would run pretty well within that tier. Most users making more than 1500 requests a day have no issue paying.
- _Codemonkeyism 9y agoI think 1500 per day is practically useless unless for a very small side project. My old blog got many more daily unique visitors, but YMMV. [edit] Aside from that, I personally would not do business with someone describing his own offer as "pretty generous", but that's just me.
- nailer 9y ago> Up to 1500 free requests daily with no credit card or signup required Neat. I'll make an updated express-geoip using this today or tomorrow.
- jonathan-kosgei 9y agoAwesome! Ping me at jonathan at ipdata dot co if you'd like to discuss anything!
- no_protocol 9y agoI wonder if you can change the pricing plans and language around them a little. What happens if I'm going along happily on the 2500/day plan and suddenly I get hit with a traffic spike and need 20,000/day for 3 days until things calm down? If you're going to use pricing buckets like this it probably needs to also come with an automated way to bump the plan if needed. Someone else in the thread suggested Maxmind as an alternative. Their prices seem to be several times higher than yours. Can you double your prices? It seems really cheap. Too cheap? Also, the location identified for me was off by 60 miles. On your Documentation page you've used 8.8.8.8 as an example IP address. And 1.1.1.1, and 2.2.2.2... I'd rather see you use the IPv4 address blocks reserved for documentation by RFC 5737 [0]. That's what they're for! Unfortunately, they probably don't have any actual data associated with them so the examples would need to be fabricated...hmm. And it looks like actually using one of those results in some output that does not conform to the format on your documentation page, so you'd best also add documentation about error handling. [0]: https://tools.ietf.org/html/rfc5737 https://tools.ietf.org/html/rfc5737
- jonathan-kosgei 9y agoI've actually been seriously considering adding a pay as you go plan, where you pay for only per the number of requests you make,is this something that would interest you? The current prices are an extended Cyber Monday offer, I figured I'd let it run into the holidays. Unfortunately it's never going to be spot on all the time. Awesome points on the example ips and adding error handling documentation. Thanks for pointing me to rfc5737! I'm adding the Error Code documentation right now. Added a table with Error Codes and their accompanying messages.
- mrkurt 9y agoIt's more fun to sell metered services to people than "plans". You can get the best of both worlds by having a per unit price, and then giving people discounts for committing to certain usage levels. Plans are kind of a pain because you have to have a sales process to get people to change. Mailchimp automatically upgrades/downgrades people between plans, which is a decent workaround, but still a little weird to customers.
- lluft 9y agoHow do you compare to Maxmind in regards of data quality?
- joekrill 9y agoThis is really important. Particularly because Maxmind can be used locally and their free dataset is actually pretty accurate for most use cases.
- lluft 9y agoAgree. Nothing beats running it locally in regards to latency constraints.
- jonathan-kosgei 9y agoPlease see my reply to mywittyname above, basically, there are certain situations where being able to take advantage of our globally distributed infrastructure is the best call and I 100% agree that there are situations where using a local db is simply the best (only) call.
- dewski 9y agoI live in a well known city of almost 300k people and it can't locate my city and the lat/lon is the center of the US.
- jonathan-kosgei 9y agoUnfortunately, it's never going to be a 100%. If it's not able to pin you exactly it'll place your location as the center of the population. If you're okay with sending your IP and location to an internet stranger my email is jonathan at ipdata dot co. I can keep tabs on this and see if accuracy improves.
- reaperducer 9y agoI can't speak for anyone else, but it's got me pegged 571 miles from my actual location. Not even close enough for an ICBM.
- sbr464 9y agoLantency spelling on link, just heads up
- jonathan-kosgei 9y agoThanks! Fixing that right now.
- jonathan-kosgei 9y agoFixed.
- rhyst 9y ago"Lantency based routing" - typo on landing page?
- jonathan-kosgei 9y agoThanks! Fixing that right now.
- jonathan-kosgei 9y agoFixed.
- mycentstoo 9y agoDesign looks great!
- jonathan-kosgei 9y agoThanks!
- boyd9461 9y agoDo you support GeoJSON formatted output?
- jonathan-kosgei 9y agoHi, I'm not sure our data would fit this format but at the moment it's not supported.
- Drdrdrq 9y agoI wonder what the source of the data is? Also, local queries are a must for most web apps... Otherwise latency is just too high.
- jonathan-kosgei 9y agoPlease see my reply to mywittyname, basically, there are certain situations where being able to take advantage of our globally distributed infrastructure is the best call and I 100% agree that there are situations where using a local db is simply the best (only) call.
- kasbah 9y agoI host my own instance of https://freegeoip.net https://freegeoip.net. Any advantages this would have over that?
- jonathan-kosgei 9y agoHi Kasbah, :) Several. - The Global infrastructure backing ipdata.co is pretty impressive, 4 data centers in the US, 1 in Canada, 2 in Europe and 1 each in Mumbai, Sydney and Seoul. - We offer more datapoints, I tried to build this around the most common use cases for Geolocation, one of which is showing your users the right currency. This is something we provide, that is, the currency ISO code and symbol. - I think our API is pretty darn fast :) Your pros; You offer more data formats, csv and xml whereas we only offer JSON. You offer a pretty high free tier but I think there's definitely tonnes of people who derive a lot of value from ipdata :)
- kasbah 9y agoThanks for you answer. To clarify: Freegeopip is not my project but it's pretty easy (for someone who knows how to run a Linux server) to host your own instance.
- jonathan-kosgei 9y agoMy bad! Sorry about that. That's definitely an option, however there're definitely users who'd rather not do it themselves and would benefit from our global infrastructure and not having to bother with updates.
- dylz 9y ago1) freegeoip is locally hosted - unlimited queries 2) OK. 3) freegeoip is faster and locally hosted - no network latency The entire thing runs as a one command docker instance - database updates are automatically managed
- jonathan-kosgei 9y ago
- harrisonhjones 9y agoIt would be cool if your examples (or really your entire website) was a git repo so people could easily report issues. Examples: 1. Your GO examples don't quite follow Go standard style "resp_body" instead of just "body", "resp", or "respBody" 2. Instead of "Error Codes" it should probably be "Status Codes" since the first "Error Code" is actually "200 OK"
- jonathan-kosgei 9y agoOn 2, thanks for catching that, changing that right now. On 1 atm we have a Python repo https://github.com/ipdata/python https://github.com/ipdata/python which I know isn't exactly what you're looking for. Thanks for reporting this. The right avenue to handle something like this would be sending an email to Support. Be assured we'll be quick to respond and work through whatever you need. Made the change.
- larelli 9y agoI tried "curl ipdata.co" and got a 301 page. It'd be great to get the same json back that's shown on the webpage.
- jonathan-kosgei 9y agoThe API endpoint is https://api.ipdata.co https://api.ipdata.co try "curl https://api.ipdata.co" https://api.ipdata.co"
- jscholes 9y ago> We regularly update our data, with checks for changes in IP address allocations made everyday. `everyday` is an adjective, in this case you should use `every day` as two separate words.
- jonathan-kosgei 9y agoFixed! Appreciate the feedback :)
- cmg 9y agoLooks very cool and I'm going to give the free tier a try on a project. But this concerns me: > Can I update my card details? > Yes. Send an email to support@ipdata.co. Your request will be processed within 24hrs. What is your process there? You're not asking people to send credit card information via email, right?
- jonathan-kosgei 9y agoDefinitely not! :) We'd send you a unique link to a page where you can update your details. We'd never expose your credit card information in that manner.
- lucideer 9y agoGood to hear, but I'd still be a bit concerned that the wording above might lead some inexperienced/not-security-conscious person to send you their details via email outright.
- jonathan-kosgei 9y agoGood point, I think there's another way we could do it. Let me fix that.
- cmg 9y agoYou actually have good language right on your /faq.html page that should address this. >Yes, send an email to support@ipdata.co requesting the change. You will receive a link from where you'll be able to securely update your details.
- jonathan-kosgei 9y agoFixed the front page.
- jonathan-kosgei 9y agoThanks for the great feedback!
- Shoothe 9y agoVery nice service. Using unicode emoji for flags would be better than pngs IMO.
- jonathan-kosgei 9y agoThat's a very intriguing idea. I'm definitely going to look into the mechanics of this. I don't know if it'd make it possible to have them in different sizes, but thanks for this! I'm definitely going to look into adding a field with this.
- Shoothe 9y agoWell they are characters so they are in different sizes by design (like vector graphics). For the reference here you have one with description how they are generated: https://emojipedia.org/flag-for-united-states/ https://emojipedia.org/flag-for-united-states/
- jonathan-kosgei 9y agoThanks, will check it out.
- qwerty456127 9y agoBoth of these are redundant as long as there is the country code already included in the API response object.
- jonathan-kosgei 9y agoIt's a thing https://stackoverflow.com/questions/19768023/how-can-i-get-users-country-flag-on-my-site https://stackoverflow.com/questions/19768023/how-can-i-get-u...
- ggm 9y agoplease explain your data source model. How do you integrate the RIR data, the NIR data, BGP and RTT location/estimation data to arrive at the geoid of where any given IP is. How do you handle multi=national ASN or cellular ASN using IPs across borders? (disclosure: I work in a regional internet registry)
- jonathan-kosgei 9y agoWe aggregate our data from multiple existing sources. I'm going to add a Data section to our site explaining this in more detail.
- chrisseldo 9y agoWhat about adding zipcode?
- jonathan-kosgei 9y agoThere's a "postal" field in the API output containing the postal code.
- qwerty456127 9y ago> Get the following datapoints from any IP address; Again :-( I just wonder if people will ever stop making assumptions about others given their IP address or hair colours and divide the Internet on these slippery grounds. The only legitimate and valid way to determine the client's location automatically is the browser or the OS geolocation API, and for the language it is the HTTP_ACCEPT_LANGUAGE header. The fact I have contacted your server from an IP address assigned to a Chinese ISP neither means I'm in China nor that I speak Chinese.
- cdancette 9y agoTrue but for most users it's enough. And it's sometimes the only information they have if the geolocation api doesn't give them anything.
- qwerty456127 9y agoIf the geolocation api doesn't give anything - that probably means the user has chosen to configure it this way because they don't want to share their location. You should probably ask them in case you actually need to know where they are.
- stedaniels 9y agoTrue. But what language should you ask them in? Correctly assuming some details improves the UX for the many.
- ksenzee 9y agoYou should ask them in whatever language their Accept-Language HTTP header specifies. If there isn't one, then ok, maybe look at their IP. But it makes no sense to treat the IP as a more valuable source of information than the HTTP header that's there for exactly this purpose.
- qwerty456127 9y ago
- gsaqui 9y agoAre you able to flag an IP address as an IP coming from a VPN?
- preinheimer 9y agoThe folks at http://getipintel.net/ http://getipintel.net/ can give you some decent information about wether an IP looks spammy or not. > Given an IP address, the system will return a probabilistic value (between a value of 0 and 1) of how likely the IP is a VPN / proxy / hosting / bad IP. A value of 1 means that IP is explicitly banned (a web host, VPN, or TOR node) by our dynamic lists. We've been using it for a while and are pretty happy.
- gsaqui 9y agoWill check this out - thank you.
- jonathan-kosgei 9y agoThis is something we'd really like to add to our API and something we're working on.
- gsaqui 9y agoAre you able to flag if the IP is from a TOR network?
- jonathan-kosgei 9y agoYou can see all the datapoints we provide by visiting our homepage https://ipdata.co https://ipdata.co or by making a call in your terminal via curl https://api.ipdata.co https://api.ipdata.co
- gsaqui 9y agoIf you are able to add detection for VPN then this is something my company would happily pay for.
- Shoothe 9y agoTangential but I find it funny that such a simple service has libraries for so many different languages. Is one simple HTTP call and JSON deserialization that hard? Personally I'd be more concerned about bringing yet another 3rd party module (leftpad, security, maintenance) than doing GET + JSON.parse but maybe convenience is what's most important.
- Kalium 9y agoOne of the first things people tend to look at for an API is whether or not there's a library that makes integration as easy as possible. One HTTP call and JSON deserialization is often more thought and effort than people want to put in.
- jonathan-kosgei 9y agoRight, this is why we have multiple copy-pasteable examples in different languages. To make it as straight forward and quick as possible to get started.
- Shoothe 9y ago> One HTTP call and JSON deserialization is often more thought and effort than people want to put in. I rest my case.
- fluffyllemon 9y agoThey only have one official library (python); all the language examples are just showing how to do an HTTP call to the service
- agotterer 9y agoFYI, tried to contact you but the contact form is broken and is raising a 405 error.
- jonathan-kosgei 9y agoPlease send an email to jonathan at ipdata dot co or support at ipdata dot co
- coderholic 9y agoCongrats on the launch and the HN coverage @jonathan-kosgei! Looks very similar to my service, https://ipinfo.io https://ipinfo.io: $ curl ipinfo.io/8.8.8.8 { "ip": "8.8.8.8", "hostname": "google-public-dns-a.google.com", "city": "Mountain View", "region": "California", "country": "US", "loc": "37.3860,-122.0840", "org": "AS15169 Google LLC", "postal": "94035", "phone": "650" } It also started as a simple geolocation API when I first launched it over 3 years ago. Since then we've built many custom data sets and expanded to more products, including IP to company details, carrier detection, reverse IP hosting data and more. See https://ipinfo.io/products https://ipinfo.io/products. We've been lucky enough to signup customers like Dell, Tesla, eBay, TripAdvisor, Plesk and others. Happy to chat and share notes at some point!
- jonathan-kosgei 9y agoThanks coderholic! :). I took a lot of inspiration from your service but built around solving a number of pain points. Would love to chat and talk sometime :)
- hidiegomariani 9y agowhere do you guys get all this ip-to-location data from?
- alam2000 9y agoThere are several providers in the market such as Maxmind GeoIP2 or IP2Location LITE.
- jsteemann 9y agoJust to let you know: Google+ link on webpage is not doing anything, as it simply links to "#".
- jonathan-kosgei 9y agoWe actually haven't setup our Google+ presence yet.
- jonathan-kosgei 9y agoRemoved the link :)
- styfle 9y agoHow accurate can you get with an IP address? I seems like it could act as a fallback if the geolocation web api is blocked. I have a side project[0] that uses the geolocation api to post to Slack and seems to be pretty accurate, even on mobile. Maybe I'll try this as a fallback. [0]: https://github.com/styfle/geoslack https://github.com/styfle/geoslack
- jonathan-kosgei 9y agoGeoslack looks really cool!! Using it as a fallback when location isn't allowed via the browser or if within an app from GPS would be a valid and common usecase! I'd say you can pretty much trust it up to the country level and greater region, more specific than that the results will not always be highly accurate.
- coderholic 9y agoHere's a guide on doing exactly that - falling back to IP geolocation when browser geolocation is blocked (or unavailable): https://ipinfo.io/developers/replacing-getcurrentposition https://ipinfo.io/developers/replacing-getcurrentposition
- qwerty456127 9y agoBy the way, it would be nice to also include ISO 3166-2 state code (e.g. US-AL for Alabama, AU-TAS for Tasmania, TZ-26 for Manyara etc).
- jonathan-kosgei 9y agoThat sounds like a great idea, I'll consider adding this, is there a specific use case for this format?
- thomasconner 9y agoI have added a JavaScript Library. https://github.com/thomasconner/ipdata-js-library https://github.com/thomasconner/ipdata-js-library
- jonathan-kosgei 9y agoToo cool! Ping me at jonathan at ipdata dot co and I'll set you up with free api keys for this! :) We can also talk about adding including some examples on the docs page.
- orf 9y agoGreat looking site, and good luck. My IP data was pretty much bang on, something I haven't seen before. However, I was just looking at your Python SDK: https://github.com/ipdata/python/blob/master/ipdata/ipdata.py#L20 https://github.com/ipdata/python/blob/master/ipdata/ipdata.p... What are you thinking. Never do this in a library. Also it looks a bit amaterish, as it's your only currently supported library I'd fix it up a bit - don't add .pyc/dist files to git, make it pep8, remove sys.exit() in a library (!!!) etc.
- jonathan-kosgei 9y agoYou're absolutely right! Not sure how/why that got in there in the first place. I'm fixing a new release right now. I'm also going to have the repo/package cleaned up. Pushed a new release: https://pypi.python.org/pypi/ipdata/2.6 https://pypi.python.org/pypi/ipdata/2.6
- kelnos 9y agoCalling 'print' from within a library is pretty bad form too... responses and errors should always be returned as data that can be inspected programmatically. In this case it's even worse, as the code will just return None on error, and you don't know why.
- orf 9y ago^ This. Never call print from a library, what if I'm using a script to pipe stdout somewhere. Just throw a custom GeolocationException or something, with some useful data about what went wrong. In this specific case though, just don't bother catching the exception. It's not useful and it indicates something is terribly wrong.
- jonathan-kosgei 9y agoFixed https://github.com/ipdata/python/blob/master/ipdata/ipdata.py https://github.com/ipdata/python/blob/master/ipdata/ipdata.p... will add enhancements when I can.
- rmason 9y agoIn my case it was off by 24 miles. That's the furthest off I've ever seen a Geolocation API be. The best are within a couple of hundred feet.
- simonebrunozzi 9y agoAnybody has heard about FOAM? It seems a similar use case.
- jonathan-kosgei 9y agoJust a few reasons why to use Ipdata; 1. Currency Data - The user's country's Currency ISO code and symbol are returned in the API output. 2. Phone Code Data - The user's country's Calling code is returned as well. 3. Global Footprint - Endpoints in 10 locations globally. 4 on both US coasts, 1 in Canada, 2 in Europe, 1 each in Mumbai, Seoul and Sydney. This ensures you get pretty low latencies wherever your app is hosted and wherever your end users are located. 4. Solid Infrastructure - The infrastructure backing Ipdata is pretty impressive, and built to scale to a substantial amount of traffic - in the hundreds of millions. 5. A free tier of 1500 requests daily (45 000/month) with no signup or credit card needed. 6. Examples in multiple languages on the Docs page at https://ipdata.co/docs.html https://ipdata.co/docs.html, to make integrating with your site absolutely painless. 7. Regularly updated data - we check for changes daily and regularly update our data. Coming soon; VPN/Proxy and Tor exit node data.
- jonathan-kosgei 9y agoOur API now supports Tor Exit Node detection: https://api.ipdata.co/103.10.197.50 https://api.ipdata.co/103.10.197.50, you can also try it against a current list of Tor Nodes here https://check.torproject.org/cgi-bin/TorBulkExitList.py?ip=1.1.1.1 https://check.torproject.org/cgi-bin/TorBulkExitList.py?ip=1...