I've deployed a script to be used as a web app that can be accessed by "Anyone, even anonymous" and yet, if a user has not logged into a gmail account on a particular browser, its asking them to login.
Here's my manifest file -
{
"timeZone": "Asia/Kolkata",
"dependencies": {
},
"webapp": {
"access": "ANYONE_ANONYMOUS",
"executeAs": "USER_DEPLOYING"
},
"exceptionLogging": "STACKDRIVER"
}
To replicate the problem, you can visit the following link by logging out of your gmail accounts (or in a browser that does not have your gmail sign in) -
*it is required that you not change the pathInfo of the URL
Current behavior -
I'm building (or rather, though I already had built) a URL shortener service using Apps Script and oddly, it is not asking users to login when accessed from a custom domain (an iframe embedded in https://tmt.pw) but it is asking them to login once they shorten the URL and try visiting the shortened URL.
The original resources are all available here -
I've tested this on Chrome, Safari and Firefox (all on a Mac) and they all exhibit the same behavior.
I'm guessing this is something very fundamental and all I want is the web app to not ask users to login, given that it has been instructed to execute even for an anonymous user.
The script has some business with a Spreadsheet as well and so I tried making the sheet publicly editable by everyone (anyone on the internet) and it still didn't work.
Was using 1 private function (with an _
at the end of the function name) & have stopped doing that in my script - still no change; problem persists.
Adding the parameter in the path after the /exec triggers the login after the redirect. Using the queryString will probably work.