Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

YouTube Data API v3, Web Application, 403 usageLimits accessNotConfigured

Tags:

youtube-api

I'm having trouble when trying to access the YouTube Data API v3. This is the json response I get whenever I send a valid request:

{
 "error": {
  "errors": [
   {
    "domain": "usageLimits",
    "reason": "accessNotConfigured",
    "message": "Access Not Configured"
   }
  ],
  "code": 403,
  "message": "Access Not Configured"
 }
}

Example of one of my valid requests:

https://www.googleapis.com/youtube/v3/search?part=snippet&maxResults=5&q=funny&key=*my_valid_api_browser_key*

Here is a screenshot of my services setting in the Google APIs Console:

http://imgur.com/GA747

In addition, I have registered the application and it has a Project ID and Client ID. I have also tried swapping the api_key parameter in the example above, one of my valid request URLs, with a valid api server key (and I believe this will only work if the request comes from the IP address associated with the key, which I can do because I can make the API request from the correct server); however, I still get the exact same result.

Is the YouTube Data API v3 public yet? It appears that it was released publicly on December 12, 2012 when this video for the YouTube Data API v3 was released: http://www.youtube.com/watch?v=tlcWiP7OLFI. I guess I could be wrong though.

Any other ideas on why I could be getting this particular response instead of a response that has the expected list of videos matching my query?

like image 902
bradleygsmith Avatar asked Jan 04 '13 19:01

bradleygsmith


1 Answers

Jeff, your email recommendation resolved my issue. I removed all lines from the Referers field. Now, in my Google API console, on the API Access screen for this project, under the section titled 'Key for browser apps (with referers)' has a 'Referers' field that reads --> Referers: Any referer allowed.

Now, I get an accurate JSON response from the API.

like image 199
bradleygsmith Avatar answered Jan 01 '23 14:01

bradleygsmith