OpenWeatherMap requires an API key to be part of the service call. I didn't see that anywhere in the tutorial. I created an account at the weather site, then added the key/value pair to the service call as defined in the .js file.
Solved! Go to Solution.
Out of curiosity, I checked out the OpenWeatherMap API and its pretty straight forward, just needs an "appid" query param to work.
@Brent Stains , Welcome to Apigee Community.
Can you please point the API you are referring to ? And also , Can you please post your js code with masked credentials ? I feel above question is not very clear & need more details to understand. Please update your question.
See my reply to Kurt.
Out of curiosity, I checked out the OpenWeatherMap API and its pretty straight forward, just needs an "appid" query param to work.
Agreed. I created an account, got a key and updated the weather.js controller to include this in the getWeatherByCity(). Note I hard-coded the value for the test.
var url = "http://api.openweathermap.org/data/2.5/weather?q="+city+"&units=imperial&APPID=MyPersonalId";
I worked fine. I posted here in case someone wants to update a127 on GitHub.
Brent S
Thanks @Brent Stains for the heads up -- Looks like the apikey requirement came after the tutorial was written. I'll update the tutorial.
User | Count |
---|---|
1 | |
1 | |
1 | |
1 | |
1 |