Zipcode field not returned for Canadian Postal Codes

  • 1
  • Problem
  • Updated 4 years ago
When I do a location request for Canadian postal codes, I am receiving a valid response except the zip field is being left blank. My assumption was that this field would contain the zip/postal code regardless of which country we are requesting.

Here is an example for N2K 0A7

"location" : {
"type" : "INTLCITY",
"country" : "CA",
"country_iso3166" : "CA",
"country_name" : "Canada",
"state" : "QC",
"city" : "Amos",
"tz_short" : "EST",
"tz_long" : "America/Montreal",
"lat" : "48.57109833",
"lon" : "-78.11830139",
"zip" : "00000",
"magic" : "28",
"wmo" : "71725",
"l" : "/q/zmw:00000.28.71725",
"requesturl" : "global/stations/71725.html",
"wuiurl" : "http://www.wunderground.com/global/st...",
"nearby_weather_stations" : {
"airport" : {
"station" : [{
"city" : "Val D'Or, Que.",
"state" : "",
"country" : "Canada",
"icao" : "CGVO",
"lat" : "48.05638885",
"lon" : "-77.78666687"
}, {
"city" : "Val-d'Or",
"state" : "",
"country" : "CA",
"icao" : "CYVO",
"lat" : "48.05333328",
"lon" : "-77.78277588"
}, {
"city" : "Rouyn Airport",
"state" : "",
"country" : "CA",
"icao" : "CYUY",
"lat" : "48.20611191",
"lon" : "-78.83555603"
}, {
"city" : "Rouyn",
"state" : "",
"country" : "CA",
"icao" : "CWUY",
"lat" : "48.24583435",
"lon" : "-79.03416443"
}
]
},
"pws" : {
"station" : [{
"neighborhood" : "Amos",
"city" : "Amos",
"state" : "QUEBEC",
"country" : "CANADA",
"id" : "IQUEBECA4",
"lat" : 48.5975838,
"lon" : -78.14614,
"distance_km" : 3,
"distance_mi" : 2
}
]
}
}
},
Photo of Brian Richards

Brian Richards

  • 2 Posts
  • 0 Reply Likes

Posted 4 years ago

  • 1
Photo of WunderWilliam

WunderWilliam

  • 267 Posts
  • 18 Reply Likes
The United States has full support for zip codes, but we don't we don't have postal codes for all countries.
Photo of Brian Richards

Brian Richards

  • 2 Posts
  • 0 Reply Likes
Sorry for the late response. In this scenario I am querying your API's with the postal code I was expecting to get back. There is an easy workaround for this on my end but I was relying on your response just in case you gave a response for the nearest postal code.

I would expect this field to contain the result if I am requesting via postal code.