0

How to use Google API Explorer?

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

I would like test Google+ Domains API and even via API Explorer I receive 403 error:

{
 "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."
 }
}
Thomas
  • 97
  • 2
  • 8
  • 1
    Are you using an API key or just authenticating the request via the Authorize requests toggle? – class Aug 26 '15 at 16:55
  • Authorize requests using OAuth 2.0 - turn on with default settings (all permissions checked also don't work) – Thomas Aug 27 '15 at 14:36
  • Possible duplicate of [Google URLShortener API returns ipRefererBlocked](https://stackoverflow.com/questions/29123516/google-urlshortener-api-returns-iprefererblocked) – Linda Lawton - DaImTo May 31 '17 at 08:05

1 Answers1

2

This is an app settings issue in the Google Developers Console. On the credentials screen it lists the IPs that are allowed to use the API Key. It's a security precaution to help protect the key if it leaks. As the picture

You need to edit allowed IPs to either be empty (less secure) or update it to include the actual IP of your server. As the picture

sn ps
  • 46
  • 1
  • 5
  • Hello, i am facing the same issue, can you please explain how can i edit the allowed IPs, i cannot find this in the credentials screen thanks – Ali Akkawi May 08 '17 at 22:13