Error: invalid_scope - This app hasn't been verified to access

Viewed 18605

Has anyone experienced this error before? I have been researching, testing, and banging my head to get this error to go away but nothing seems to work.

This is a similar question to the following posts:

Error: invalid_scope google read contact
Google Api:: Error: invalid_scope
403 error when calling Google People API

Unfortunately, these posts never were resolved or aren't helpful.

What is puzzling is, i'm following the examples listed here: https://developers.google.com/api-client-library/javascript/samples/samples. Along with testing the ONLY the scopes I need here: https://developers.google.com/people/api/rest/v1/people/get.

However, I cannot seem to get past the popup screen that states i'm passing an invalid scope.

FYI, I have the API Console setup to use Google People API, Google+, and Google Contacts. I'm using my client id and api key in the "gapi.auth2.init" config call.

Any insight would be super helpful! Thank you for your time and response.

3 Answers

I copied and paste code from google developers example page Search list

and that example didn't work for me. I got the same error about invalid scope...

Solution was to change below line:

private static final Collection<String> SCOPES = Arrays.asList("YouTubeScopes.https://www.googleapis.com/auth/youtube.force-ssl YouTubeScopes.https://www.googleapis.com/auth/youtubepartner");

with following line:

private static final Collection<String> SCOPES = Arrays.asList("https://www.googleapis.com/auth/youtube.force-ssl https://www.googleapis.com/auth/youtubepartner");

Basically I just get rid of "YouTubeScopes" prefix and it has started to work.

Related