Stay organized with collections Save and categorize content based on your preferences.
ServiceAccess and manipulate script publishing.
Methods Method Return type Brief descriptiongetUrl()
String
Returns the URL of the web app, if it has been deployed; otherwise returns null
. isEnabled()
Boolean
Returns true
if the script is accessible as a web app. Deprecated methods Method Return type Brief description disable()
void
Disables the script from being accessed as a web app. Detailed documentation getUrl()
Returns the URL of the web app, if it has been deployed; otherwise returns null
. If you are running the development mode web app, this returns the development mode url.
// Mail the URL of the published web app. MailApp.sendMail( 'myself@example.com', 'My Snazzy App', `My new app is now available at ${ScriptApp.getService().getUrl()}`, );Return
String
— the URL of the web app
isEnabled()
Returns true
if the script is accessible as a web app.
Boolean
— true
if the script is published as a web app; false
if not
disable()
Deprecated. This function is deprecated and should not be used in new scripts.
Disables the script from being accessed as a web app. This method is equivalent to opening the "Publish > Deploy as web app" dialog and clicking "disable web app".
ScriptApp.getService().disable();
Except as otherwise noted, the content of this page is licensed under the Creative Commons Attribution 4.0 License, and code samples are licensed under the Apache 2.0 License. For details, see the Google Developers Site Policies. Java is a registered trademark of Oracle and/or its affiliates.
Last updated 2024-12-02 UTC.
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Missing the information I need","missingTheInformationINeed","thumb-down"],["Too complicated / too many steps","tooComplicatedTooManySteps","thumb-down"],["Out of date","outOfDate","thumb-down"],["Samples / code issue","samplesCodeIssue","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2024-12-02 UTC."],[[["The `ScriptApp` service allows you to control and interact with the deployment of your script as a web application."],["You can retrieve the web app's URL using `getUrl()`, check its accessibility status with `isEnabled()`, and previously, disable it using the now deprecated `disable()` method."],["The `disable()` method has been deprecated and should no longer be used in new scripts, replaced by the \"Publish \u003e Deploy as web app\" dialog for disabling."],["When deploying your script as a web app, you can use provided methods to obtain its URL and determine if it's enabled for access."]]],[]]
RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4