我正在尝试使用此https://www.npmjs.com/package/nativescript-plugin-google-places
或此: https://market.nativescript.org/plugins/nativescript-google-place-picker
但是我收到了:
错误:错误:地点选择器错误:错误Domain = com.google.places.ErrorDomain代码= -9“未启用iOS的Places API。有关如何启用的信息,请参见开发者指南(https://developers.google.com/places/ios-api/start)。适用于iOS的Google Places API。” UserInfo = {NSLocalizedFailureReason =未启用iOS的Places API。有关如何启用iOS的Google Places API的信息,请参阅开发者指南(https://developers.google.com/places/ios-api/start)。NSUnderlyingError = 0x600003e539f0 {Error Domain = com.google.places.server.ErrorDomain代码= -1“(null)” UserInfo = {NSUnderlyingError = 0x600003e53f30 {Error Domain = com.google.GTLRErrorObjectDomain代码= 403“项目253161235137之前未使用iOS的Places SDK或已将其禁用。请访问https://console.developers.google.com/apis/api/placesios.googleapis.com/overview?project=253161235137启用它,然后重试。如果启用了此功能API最近,请等待几分钟,以执行操作t <…>
即使我启用了Google Place API,也一直如此。
对此进行审查,我注意到我启用了Google Place API,而不是启用了IOS的Google Place API。
似乎“ for ios”版本不再存在。
所以这个URL
实际上无效,因为“ placesios.googleapis.com”不再可用。它只是返回一个白页。
Google Place API现在以“ places-backend.googleapis.com”表示
https://console.cloud.google.com/google/maps-apis/apis/places-backend.googleapis.com/
关于如何解决这个问题的任何线索?
谢谢大家。