API Explorer ipRefererBlocked

时间:2015-08-26 14:17:49

标签: google-api google-plus http-status-code-403 google-plus-domains

如何使用Google API Explorer?

https://developers.google.com/apis-explorer/#p/plusDomains/v1/plusDomains.people.get

我想测试Google+域名API,甚至通过API Explorer我收到403错误:

{
 "error": {
  "errors": [
   {
    "domain": "usageLimits",
    "reason": "ipRefererBlocked",
    "message": "There is a per-IP or per-Referer restriction configured on your API key and the request does not match these restrictions. Please use the Google Developers Console to update your API key configuration if request from this IP or referer should be allowed.",
    "extendedHelp": "https://console.developers.google.com"
   }
  ],
  "code": 403,
  "message": "There is a per-IP or per-Referer restriction configured on your API key and the request does not match these restrictions. Please use the Google Developers Console to update your API key configuration if request from this IP or referer should be allowed."
 }
}

1 个答案:

答案 0 :(得分:2)

这是 Google Developers Console 中的应用设置问题。在凭据屏幕上,它列出了允许使用API​​密钥的IP。这是一个安全预防措施,以帮助保护密钥泄漏。 As the picture

您需要将允许的IP编辑为空(安全性较低)或更新它以包含服务器的实际IP。 As the picture