Last night a site that has been working fine for about six months started getting a 403 error when using Google OAuth. The authentication code hasn't changed, and I don't see any notes that Google OAuth suddenly changed either. I've tried re-issuing the client ID (including client secret) but that didn't fix it.
Details:
Full error: "Access Not Configured. Please use Google Developers Console to activate the API for your project." comes after this (scrubbed) request:
https://accounts.google.com/o/oauth2/auth?response_type=code&redirect_uri=https%3A%2F%2Fx.y.com%2Fauth%2Fgoogle%2Fcallback&scope=https%3A%2F%2Fwww.googleapis.com%2Fauth%2Fuserinfo.profile%20https%3A%2F%2Fwww.googleapis.com%2Fauth%2Fuserinfo.email&client_id=12345-abcdefg.apps.googleusercontent.com
The response header does contain this (scrubbed):
Location: https://x.y.com/auth/google/callback?code=4/MF-V...
which contains the code similar to what I see in the API playground.
Server setup: node.js running express with passport/passport-google-oauth.
I don't know what API needs to be enabled -- I sort of think this is a miss-sense error. None of the APIs in the "APIs & auth" section of the Developers Console appear to be relevant. I'm configuring OAuth under "APIs & auth > Credentials." This is not youtube or Google+ authentication.
I don't think this is the cause of your problem but you should be aware of it anyway. Using OAuth 2.0 for Login (early version)
Important: Google has deprecated the early implementation of OAuth 2.0 for login that is described in this document and will no longer support it, after a migration period. If your app uses OAuth 2.0 login (early version), you should either switch to Google+ Sign-In or update your existing userinfo endpoints and scopes by the deadline given in the migration timetable. For instructions, see Migrate or update OAuth 2.0 login.
Migration timetable says on Sept. 1, 2014 its gone: https://developers.google.com/+/api/auth-migration#timetable
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With