52

I try to implement google oauth, following the Google OAuth2ForDevices.

My App is registered on Google Cloud Console, as native App. When I try to follow the OAuth2ForDevices using Google Chromes - Advanced Rest Client Application, I get the json response with the user_code and verfication_url. Opening the verfication_url and enterering the user_code, leads to the follwoing Error:

invalid_client: no support email Error 400

I tried this with 2 registred Apps on Google Cloud Console. Both leading to the same error.

Anys hints, how to solve this? Do I have to register a support email somewhere in google cloud services?

jerik
  • 5,322
  • 7
  • 38
  • 75
  • 6
    In **APIs & auth | Consent screen**, did you set an **EMAIL ADDRESS**? I'm not sure that's the solution. I'm having the same problem, trying to debug now. I cannot set an email address on the consent screen because I get an "oops, our bad" error, apparently a google bug. This post seems to be the same problem: https://groups.google.com/forum/#!topic/google-doubleclick-for-publishers-api/6savNh4PBBI – janos Nov 23 '13 at 22:10
  • @janos that did the trick. Thanks a lot. I added my email adress in the consent screen. and now it works fine! – jerik Nov 24 '13 at 11:06
  • Good for you! Sadly I'm still stuck, I cannot set the email address... :( – janos Nov 24 '13 at 11:17

4 Answers4

88

It seems this can happen if you did not set an EMAIL ADDRESS on the Consent screen.

  1. Go to your Google Cloud Console
  2. Open your project
  3. Click APIs & auth
  4. Click Consent screen, and set EMAIL ADDRESS
  5. As per @ajmccall's answer, delete and recreate the client ID

This seems to have helped others, right now it does not help me. When I set an email address and click Save an error pops up:

Whoops! Our bad.

Please try again. If the problem persists, please let us know using the "Send feedback" link below. Copy the tracking number below, and include it with your feedback. Thanks!

This post seems to be about the same problem:

https://groups.google.com/forum/#!topic/google-doubleclick-for-publishers-api/6savNh4PBBI

Community
  • 1
  • 1
janos
  • 109,862
  • 22
  • 193
  • 214
  • done :). BTW, do you have an idea how I get the success code, for granting access, shown again. I did not copy it the first time, and now it will not be shown again... so currently I can't get an access token, without the (success) code... https://developers.google.com/accounts/docs/OAuth2InstalledApp?hl=de – jerik Nov 24 '13 at 12:19
  • Thanks! Unfortunately I myself haven't got the chance to see such code yet :s But I imagine you can just re-run the sample app to get the url to the auth page, no? In the worst case you could regenerate your secret key to force a re-authentication. – janos Nov 24 '13 at 13:34
  • Had two ways of testing google auth, and mixed it up. Now its clear and it works like described. Hope that you are lucky soon and can set your email and go further with the development :) – jerik Nov 24 '13 at 18:53
  • 1
    I had the same error, and couldn't figure it out. I deleted my project, and made a new one twice, and the third time got no errors. Not sure what the bug was, but glad it works now. – Gisheri Nov 14 '14 at 16:30
  • For me it enough just to set email address and it start working - without regenerating keys. – Lukasz Stelmach Feb 05 '15 at 23:17
12

If you create OAuth credentials BEFORE you set the support email address in the consent screen, then it appears that you will always get this error, even after setting the support email.

I resolved this by setting the support email, and then recreating all necessary OAuth ids in the credentials page.

ajmccall
  • 1,886
  • 21
  • 37
1

Had the same issue. Worked when I logged in with an email not associated with your api auth.

phonegapnoob
  • 87
  • 1
  • 5
0

I had to recreate all my credentials (a new Client ID and a new Key).

rotelando
  • 1
  • 1