【问题标题】:Google Map API For Near By Place By Latitude and Longitude经纬度附近的Google Map API
【发布时间】:2014-03-25 11:53:27
【问题描述】:

我有一个 Api 密钥、Api 控制台和 Sh1,并使用 EclipseIDE ANDROID -> 首选项,我 在 Api 中添加所有数据如下:

https://maps.googleapis.com/maps/api/place/radarsearch/json?location=48.859294,2.347589&radius=5000&types=food|cafe&sensor=false&keyword=vegetarian&key=AIzaSyCRQ2aFtbU2sOgO6fMvuM2edHPaWRDxbRg

但我收到此错误消息:

{
   "error_message" : "This IP, site or mobile application is not authorized to use this API key.",
   "html_attributions" : [],
   "results" : [],
   "status" : "REQUEST_DENIED"
}

我做错了什么?

【问题讨论】:

  • 您的密钥似乎尚未获得授权。您可能必须得到 Google 的批准/验证 - 您是否为此付费?
  • 检查一次api key的有效性。&你在api key中提到的包名
  • 生成新的 Api 密钥并添加权限或通过向其中添加服务 Places Api 来编辑您以前的密钥

标签: android json api google-maps


【解决方案1】:
【解决方案2】:

所以我遇到了与您相同的问题,我使用了与您相同的 api,但是我发现如果您为 android 生成新的 API 密钥它不起作用,但是如果您生成新的服务器密钥并使用它完美地工作。我在以下帖子 REQUEST_DENIED with Google Places API browser key or app key?

上找到了一些帮助

【讨论】:

    猜你喜欢
    • 1970-01-01
    • 2021-10-10
    • 2015-09-24
    • 2011-01-25
    • 1970-01-01
    • 2019-04-21
    • 1970-01-01
    • 1970-01-01
    • 2019-10-09
    相关资源
    最近更新 更多