API google analytics v3.0 : avec OAuth 2.0, - api

I'm trying to install but I get the following error:
400. That’s an error.
Error: redirect_uri_mismatch
Application: Google analitycs
You can email the developer of this application at: sextoysunivers#gmail.com
The redirect URI in the request: http://sextoysunivers.com/modules/gapi/oauth2callback.php did not match a registered redirect URI
I have tried for all shops tab, individually, with the number after the p in my google analytics browser, and with the UA code getting the same error.

You have to register the redirect_uri in the Google Developer Console. After you log in click on APIs & auth, then Credentials and enter your redirect_uri into the redirect_URIs text-area

Related

redirect_uri_mismatch error on google cloud api

Request details: redirect_uri=http://localhost:8080/
I tried changing the uri in the client_secret file and on the google cloud console so they would match but it still doesn't work.

401 redirect_uri_mismatch with .net core web application?

Authorization Error
Error 400: redirect_uri_mismatch
You can't sign in to this app because it doesn't comply with Google's OAuth 2.0 policy.
If you're the app developer, register the redirect URI in the Google Cloud Console.
The redirect uri sit he URI where you are telling the authorization server to return authorization to. This uri must be registered in Google developer console for your project.
So redirect uri miss match means that your application is telling the authorization server to return the authorization code to a uri that you have not configured in Google developer console. The easiest solution is to take the uri its telling you is missing and simply add it.
This video will show you how to add it. Google OAuth2: How the fix redirect_uri_mismatch error.

Error 400: Redirect_URI_Mismatch from Embed Code Object in Google Sites to Google Sheets API

I am trying to connect to Google Sheets API from Google Sites using the Embed Code object. It returns the following error when I try to log in:
Error 400: redirect_uri_mismatch
The JavaScript origin in the request, https://xxxxxxxx-atari-embeds.googleusercontent.com, does not match the ones authorized for the OAuth client.
OAuth 2.0 Client IDs on Google Cloud Platform do not accept https://googleusercontent.com as the Authorized JavaScript origins, and I'm not sure if there's a way to allow the embed object in Google Sites to access the Google Sheets API.
Please advise.

Getting error on login with angular 2 google and firebase

I am using firebase 3 and ng 2.
My issue I am getting error when click on connect with google account.
My error is:
Error: redirect_uri_mismatch
400. That’s an error.
Error: redirect_uri_mismatch
Application: Events Manager
You can email the developer of this application at: .....#gmail.com
The redirect URI in the request, https://......firebaseapp.com/__/auth/handler, does not match the ones authorized for the OAuth client. Visit https://console.developers.google.com/......apps.googleusercontent.com?project=181586 to update the authorized redirect URIs.
my project runs on http://localhost:3000/#/login
when I am going to console.developers.google.com Authorized redirect URIs-> http://localhost:3000/
Any idea whey is it happens?
the issue was need to add to firebase auth link the correct host.
firebase-> OAuth redirect domains

Custom local URL results in redirect_uri_mismatch

I am using a custom local URL for development of a project that authenticates with both Google and Adwords using OAuth2.
The entry in my /etc/hosts file looks like:
127.0.0.1 sub.example.dev:3001
In the Google Cloud Platform console I have an OAuth 2.0 client ID setup with:
type: Web Application
Authorized JavaScript origin: http://sub.example.dev:3001
Authorized redirect URIs:
http://sub.example.dev:3001/auth/adwords/callback
http://sub.example.dev:3001/auth/google/callback
I authenticate with with both Google and Adwords separately. Previously I was using localhost:3001 instead of the custom URL which was working for both Google and Adwords. After switching to the custom local URL the Google auth still works, but when I try to authenticate with Adwords I get a redirect_uri_mismatch error.
The error page tells me that "The redirect URI in the request, sub.example.dev:3001/auth/adwords/callback, does not match the ones authorized for the OAuth client." The URI reported here is exactly the same as what I have as an authorized redirect URI (minus the protocol).
Why does this work with Google OAuth, but not Adwords? How can I get a custom local redirect URL to work with Adwords OAuth?
Thanks!
I found the issue, and there was a hint in the question itself. The redirect URL that I pass during the OAuth flow needs to contain the protocol and I had missed that in my config.
The redirect URL I was passing in the OAuth flow was sub.example.dev:3001/auth/adwords/callback
I changed it to http://sub.example.dev:3001/auth/adwords/callback and now it works! :D