Google auth disallowed_useragent 403

I'm using Google authorization for my web application.

Getting error "google auth disallowed_useragent 403" while trying to log in from the app. The app is basically web-view.

Any help?

Yes, you will need to use the CustomWebView extension or WebviewTools by Luke Gackle, and set the userAgentString as follows:

image

I have created exact user agent as

But still facing the same issue.

There is a space between ; and wv .

Thanks for the correction. But the problem still persists even after adding space.

Show complete blocks.

Basically, I just want to open the URL (given in the block). This URL has the option to log in with Google.

Order of things is important.

You need to set the userAgent before your go to the url

You also do not show your other blocks that setup the custom webview....

This is the complete block setup.

Instead of showing the home page (URL mentioned in the block), the app is showing an empty white screen.

Where are you executing these blocks? On button click? On Screen Initialize?

Working OK for me

Actually, I want to show that URL page on the home page when the application starts.

Cool. You are calling blocks on button click.

What about if I want to execute blocks at the start of launching app, rather than providing button?

You can use Screen.Initialise.

Does it work for you now ?

@vknow360 @TIMAI2 Thank you so much. I really appreciate your quick response. Problem solved.

1 Like

I have one more question...

If I open the application in web browser, it asked to choose the Google account. This is perfectly fine.

But, whenever I try to log in with Google from the app, it does not list the Google account from my android device, instead, it asks to enter my email ID and password.

In case of an app, how can I list Google accounts instead of manually entering email and password?

Try:

  1. Signing out of Google in the webview
    and/or
  2. Removing cookies from the webview

Tried. But not working.

Hmmm, I cannot easily test as I only have one google account on my device.

But even with one Google account it is not working.

It should display one Google account. But it asking user to enter email and password.