You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
OpenWeatherMap updated their API quite a bit since I last worked on this project.
API requests by city name, zip-codes and city id have been deprecated in the Current API endpoint. You can still get a response for queries of only a city name, but if the name applies to more than one city worldwide, you get the first result -- so they may not be accurate (example: "London" returns results for London, UK, but the user could possibly mean London, Ohio, USA). Additionally, it's not super intuitive to users to enter only a city name.
They've introduced a Geocoder API endpoint which will take any string and return 1 or more objects that match, along with their specific latitude and longitude...
So perhaps the interface should be updated to hit that Geocoder endpoint first, maybe 1 second after the user stops typing. Then, if there's only 1 result, pass it to the Current Weather endpoint and return the results -- and if there's 2 or more results, present those in a dropdown below the current input field so the user can click the relevant one, and then fetch the Current Weather. Just my first thought for now!
The text was updated successfully, but these errors were encountered:
OpenWeatherMap updated their API quite a bit since I last worked on this project.
API requests by city name, zip-codes and city id have been deprecated in the Current API endpoint. You can still get a response for queries of only a city name, but if the name applies to more than one city worldwide, you get the first result -- so they may not be accurate (example: "London" returns results for London, UK, but the user could possibly mean London, Ohio, USA). Additionally, it's not super intuitive to users to enter only a city name.
They've introduced a Geocoder API endpoint which will take any string and return 1 or more objects that match, along with their specific latitude and longitude...
So perhaps the interface should be updated to hit that Geocoder endpoint first, maybe 1 second after the user stops typing. Then, if there's only 1 result, pass it to the Current Weather endpoint and return the results -- and if there's 2 or more results, present those in a dropdown below the current input field so the user can click the relevant one, and then fetch the Current Weather. Just my first thought for now!
The text was updated successfully, but these errors were encountered: