8 ms·
Google App Engine had this quite a while ago (almost a decade, I think)and a very generous free tier. Also has approx lat-long, city, state and country. https:
by sudhirj 6y ago
Google App Engine had this quite a while ago (almost a decade, I think)and a very generous free tier. Also has approx lat-long, city, state and country.
https://blip.runway7.net https://blip.runway7.net
https://github.com/runway7/blip https://github.com/runway7/blip
I lost track of the consumer apps I've used this on and still haven't received a $1+ bill.
- sneak 6y agoIs there a good lat/lon to timezone database that lets you leverage this into a presumptive timezone offset from UTC and thus local time?
- imustbeevil 6y agoDo you need the lat/lon for this? Usually you'd just put in the nearest city. Moment.js is probably the most prevalent time and date library.
- deleted 6y ago[deleted]
- deanishe 6y agoCan’t you just ask the client which timezone it’s in? Every browser knows, and it will be a more accurate answer: the user might be on a foreign VPN or temporarily in another TZ, but not working on that timezone.
- sneak 6y agoMy application is not browser-based. I’d like to set a system clock timezone via geoip only, without location lookup via wifi. On my more secure systems I have location services disabled and it’d be nice to have an accurate local time automatically.
- sroussey 6y agoI have a need for this too, and considering making a basic service for it.
- sudhirj 6y agohttps://blip.runway7.net/v2.beta https://blip.runway7.net/v2.beta should work for you, let me know if it doesn't?
- sroussey 6y agoHi! I need to be able to send a lat/long/timestamp to get tinezone.
- sudhirj 6y agoAh, I haven’t seen a dataset I could use for that. Everything on the links I’m putting up is based on the country and state information. I’ve seen timezone maps drawn, so this information does exist somewhere, but one would have to draw polygons for each timezone and do coverage checks, which seems complicated. The time zone lines zig and zag a lot.
- jaakl 6y agoThis is surprisingly difficult task if you need it to work really globally and accurately. You need specific, detailed and uptodate map data for it, and timezones change somewhere in the world all the time. Especially daylight savigs. In 99% of cases you need to find some workaround or limit your task to specific regions, and get something to work in 95% cases
- sneak 6y agoWhere is the source code for v2.beta? It’s not on your GitHub.
- sudhirj 6y agoI actually can’t remember :-/ will fish it out and set up a proper service, maybe paid.
- sudhirj 6y agoTry https://blip.runway7.net/v2.beta https://blip.runway7.net/v2.beta – I've added unix timezone based on the country and state code. The ISO databases have timezones associated with the level 2 code, which roughly corresponds to a state inside a country.
- jonathan-kosgei 6y agoI built something similar for https://ipdata.co https://ipdata.co. The API will return a time object like this for any IP: "time_zone": { "name": "America/Chicago", "abbr": "CDT", "offset": "-0500", "is_dst": true, "current_time": "2020-07-25T06:10:16.945136-05:00" }