Academic Integrity: tutoring, explanations, and feedback — we don’t complete graded work or submit on a student’s behalf.

manuelquiroz69452210.codeanyapp.com f facebook N Netflix Error 400 (OAuth2 1 Err

ID: 3849496 • Letter: M

Question

manuelquiroz69452210.codeanyapp.com f facebook N Netflix Error 400 (OAuth2 1 Error)!!1 uth2/auth?redirect uri storagerelay%3 i Secure https:// accounts google.com Google 400 That's an error. Error: redirect uri mismatch The JavaScript origin in the request, http://app- emmanuel quiroz69452210.codeanyapp.com, does not match the ones authorized for the OAuth client. Visit https://console.developers.google.com/apis/credentials/oauthclient/361982001136- ghjdqd7kb74hlave58tc494ote7bvaii.apps.googleusercontent.com? project 361982001136 to update the authorized JavaScript origins. Learn more Request Details That's all we know. D cse 460 BS Booksee.org

Explanation / Answer

It seems like your redirect URI is not registered in API console. That's why it is throwing error code of 400 and it also mention that the URI you have does not matches one for OAuth Client.
As written message, visit your console and make modification it can be you didn't registered it or you made some type error mistake.

My suggestion to perform this operation:

1.Visit console of your project under API access.

2. You will see Client ID and your secret key.

3. There also you will see list of redirect URIs.

4.if URI is not in list, click on edit settings

5. Add this your URI to list.

6. If URI was there, click on edit settings.

7. Modify this URIs, please copy URI from address bar to avoid any mistake of typing.

8. Add this URI to list

try to run your application it should start working. I hope this helps you in resolving the issue.

There is one additional information if you are using google+ button then, you should use 'postmessage' keyword in place of URI

like $client->setRedirectURI('http://...') instead of this use $client->setRedirectURI('postmessage')

above line just for example you can use any language, but main thing is if you are using google+ button then use postmessage keyword.

Please try above methods.