Add *.googleusercontent.com to Authorized JavaScript origins

Viewed 1357

We have an add-on for Google Sheets and would like to switch other Google accounts for some functions.

Half a year ago, I successfully added a URL (https://***.googleusercontent.com) to Authorized JavaScript origins and a URL (https://oauth-redirect.googleusercontent.com/r/\*\*\*) to Authorized redirect URIs.

But now we can't and, therefore, it keeps showing

Authorization Error (Error:400: redirect_uri_mismatch).

When I try to add this URL(https://***.googleusercontent.com), it shows

"Save failed! The request failed because one of the field of the resource is invalid."

I don't know whether the rules changed and what should I do. See the screenshot for details. Thanks!

Error Message: The JavaScript origin in the request, https://***.googleusercontent.com, does not match the ones authorized for the OAuth client.

The JavaScript origin in the request, https://***.googleusercontent.com, does not match the ones authorized for the OAuth client.

Trying to add a new URI

2 Answers

This appears to be a bug.

The issue you reported on Issue Tracker has been forwarded internally:

Thank you for bringing this to our attention. It has been forwarded internally.

Posting this here to give it more visibility. Please click the top-left star if you're affected by this.

I have the same problem, since October I am not allowed to use *.googleusercontent.com as Authorized origin.

I reported it on Issue Tracker, but their answer simply was "Thank you for your report, unfortunately Issuetracker is not the proper forum to address your report".

I solved this problem (At least temporarily) by inserting the Google sign-in button on an external site (Github pages) and once logged, redirect the user to my *.googleusercontent.com page with the sign-in token inserted in the URL as a parameter.

Related