Google 地图 API 没有 return 基于 "Chile" 地址的邮政编码

Google maps API does not return postal code for "Chile" based addresses

当我尝试使用 Google 地图地理编码 API 获取地址的邮政编码时,它起作用了,邮政编码是 returned 作为 [=22= 的一部分] 数组:(例如: https://maps.googleapis.com/maps/api/geocode/json?&address=socoma%201%2C%20marrakesh).

但对于基于智利(国家/地区)的地址,return 似乎没有邮政编码:(示例: https://maps.googleapis.com/maps/api/geocode/json?&address=las%20condes%20santiago%20chile).

知道原因将不胜感激。

我在维基百科上看过有关 Las Condes 地区的信息

https://en.wikipedia.org/wiki/Las_Condes

并计算出 Las Condes 的邮政编码应该是 7550000:

https://worldpostalcode.com/chile/region-metropolitana-de-santiago/santiago/las-condes

现在我尝试使用组件过滤来搜索智利的邮政编码 7550000,这是邮政编码查找的推荐方式

https://maps.googleapis.com/maps/api/geocode/json?components=postal_code%3A7550000%7Ccountry%3ACL&key=MY_API_KEY

这个请求returns

{
    "results":[
    ],
    "status":"ZERO_RESULTS"
}

因此,目前 Google 数据库中似乎缺少邮政编码 7550000,您遇到了数据问题。为了解决数据问题,您应该按照文档将其报告给 Google:

https://support.google.com/maps/answer/3094088

希望 Google 尽快添加缺少的邮政编码。

Google 并不是所有问题的答案,智利和其他一些国家/地区的邮政编码非常精确。 基本上对于城市,街道的每个部分都有一个特定的邮政编码。 所以对于Las Condes来说,一般邮政编码是7550000,但是如果你需要一个地址的特定代码,你需要在Chile post web site上搜索 例如,Acapulco 街,3700 号,邮政编码为 7550541。 您还可以使用 GeoPostcodes

等邮政数据库