It's currently raining, but the API is returning 0.0mm

  • 1
  • Question
  • Updated 4 years ago
Why is the API returning 0mm? How is Wunderground's station not detecting any rain when it's clearly raining right now?
Photo of geoffl

geoffl

  • 11 Posts
  • 0 Reply Likes

Posted 4 years ago

  • 1
Photo of WunderWilliam

WunderWilliam

  • 267 Posts
  • 18 Reply Likes
What call are you using? Please delete the key part of the string before posting.

Thanks!
Photo of geoffl

geoffl

  • 11 Posts
  • 0 Reply Likes
The following is my query string (I replaced the actual key with some placeholder text here): http://api.wunderground.com/api/API_K...

I obtained the weather conditions with that string, and then did

var precipitation = weather['current_observation']['precip_today_metric'].

This returned a result of 0mm, despite there having been rain at the time. Any metric related to precipitation returned 0.
Photo of geoffl

geoffl

  • 11 Posts
  • 0 Reply Likes
The following is my query string (I replaced the actual key with some placeholder text here): http://api.wunderground.com/api/API_K...

I obtained the weather conditions with that string, and then did

var precipitation = weather['current_observation']['precip_today_metric'].

This returned a result of 0mm, despite there having been rain at the time. Any metric related to precipitation returned 0.
Photo of Brendan Hayes

Brendan Hayes, Official Rep

  • 962 Posts
  • 123 Reply Likes
That particular station, CYUL doesn't report precip. Not all stations do. You can see its full history here:
http://www.wunderground.com/history/a...
Photo of geoffl

geoffl

  • 11 Posts
  • 0 Reply Likes
I was doing some testing with three cities on the day it was raining, and none of the stations reported any precipitation despite there having been rain. How do I know which stations report precipitation and how can I guarantee that I get that data in my query?
Photo of geoffl

geoffl

  • 11 Posts
  • 0 Reply Likes
I was doing some testing with three cities on the day it was raining, and none of the stations reported any precipitation despite there having been rain. How do I know which stations report precipitation and how can I guarantee that I get that data in my query?