How do I request weather based on an Airport code?

  • 3
  • Question
  • Updated 6 years ago
  • Answered
Photo of Matthew Gregory

Matthew Gregory

  • 13 Posts
  • 1 Reply Like

Posted 7 years ago

  • 3
Photo of Matthew Gregory

Matthew Gregory

  • 13 Posts
  • 1 Reply Like
You can end your query with any of the following
......./q/{airport code}
......./q/iata:{airport code}
......./q/icao:{airport code}

Also look at our Apigee console for examples:
http://www.wunderground.com/weather/a...

Here is the documentation for how to create a API request.
http://www.wunderground.com/weather/a...
Photo of Dan Fox

Dan Fox

  • 1 Post
  • 0 Reply Likes
Hi, how come I can't find small airports using their ICAO codes? Using geolookup or history_xxxxxxxx, for example, I can't find any data for CWMM, CYHC, CWWA CWWK... Those are all small airports near Vancouver (Canada), except CWWA, which isn't actually an airport at all (but you can see its METAR data if you search for 'West Vancouver'). I've tried with just the code and with icao: in front of the code. The result is always "No cities match your search query."

I guess the workaround would be to ask for the exact lat/long of the airport that I want...
Photo of santoshb

santoshb

  • 23 Posts
  • 0 Reply Likes
@Dan Fox

1. I guess first you identify place or lat/long.
2. Use geolookup to find nearby by airports.
3. Use conditions/history/forecast for all those airports in http://api.wunderground.com/api/bd1a0...