Does the sunset in Liverpool?

  • 1
  • Question
  • Updated 4 years ago
I did some testing using lat/lon values to retrieve hourly10day forecasts which all returned a sunset/sunrise value.
If I change this to use a city name, I tried Liverpool, the sun_Phase values are no longer returned. Is this by design or is this a bug?
Thanks
Photo of nibbo

nibbo

  • 6 Posts
  • 0 Reply Likes

Posted 4 years ago

  • 1
Photo of nibbo

nibbo

  • 6 Posts
  • 0 Reply Likes
Anyone?
Photo of John Belmonte

John Belmonte

  • 18 Posts
  • 1 Reply Like
The documentation at http://api.wunderground.com/weather/a... states:

"3. Multiple API features can be combined into a single HTTP request. This is an easy way to economize your requests...."

Just add /astronomy as part of your query and you should get the data you need.
Photo of nibbo

nibbo

  • 6 Posts
  • 0 Reply Likes
Thanks John but...
That's my point, I have astronomy in the request and I DO get the sun_Phase data when I use lat/lon but I DO NOT get the sun_Phase when I use a city name.
Photo of nibbo

nibbo

  • 6 Posts
  • 0 Reply Likes
Ah ha... I think I have worked it out.
Just using Liverpool is not enough to identify a single location as there are several worldwide so the sun_Phase cannot be determined. Changing it to 'Liverpool,UK' works just fine.