Enum AuthorizationStatus
संग्रह की मदद से व्यवस्थित रहें
अपनी प्राथमिकताओं के आधार पर, कॉन्टेंट को सेव करें और कैटगरी में बांटें.
अनुमति की स्थिति
यह एक एनोटेशन है, जो किसी स्क्रिप्ट की अनुमति की स्थिति दिखाता है.
किसी एनम को कॉल करने के लिए, उसकी पैरंट क्लास, नाम, और प्रॉपर्टी को कॉल किया जाता है. उदाहरण के लिए,
ScriptApp.AuthorizationStatus.REQUIRED
.
प्रॉपर्टी
प्रॉपर्टी | टाइप | ब्यौरा |
REQUIRED | Enum | उपयोगकर्ता को एक या उससे ज़्यादा सेवाओं का इस्तेमाल करने के लिए, इस स्क्रिप्ट को अनुमति देनी होगी. ज़्यादातर मामलों में, स्क्रिप्ट अगली बार चलने पर उपयोगकर्ता से अनुमति मांगती है. हालांकि, अगर स्क्रिप्ट को इंस्टॉल किए जा सकने वाले ट्रिगर का इस्तेमाल करने वाले ऐड-ऑन के तौर पर पब्लिश किया जाता है, तो ट्रिगर अनुमति मांगे बिना स्क्रिप्ट को चलाता है. हालांकि, अगर स्क्रिप्ट बिना अनुमति वाली सेवा को कॉल करने की कोशिश करती है, तो वह अपवाद दिखाती है. |
NOT_REQUIRED | Enum | उपयोगकर्ता ने इस स्क्रिप्ट को सभी ज़रूरी अनुमतियां दी हैं. |
जब तक कुछ अलग से न बताया जाए, तब तक इस पेज की सामग्री को Creative Commons Attribution 4.0 License के तहत और कोड के नमूनों को Apache 2.0 License के तहत लाइसेंस मिला है. ज़्यादा जानकारी के लिए, Google Developers साइट नीतियां देखें. Oracle और/या इससे जुड़ी हुई कंपनियों का, Java एक रजिस्टर किया हुआ ट्रेडमार्क है.
आखिरी बार 2025-07-26 (UTC) को अपडेट किया गया.
[null,null,["आखिरी बार 2025-07-26 (UTC) को अपडेट किया गया."],[[["\u003cp\u003eAuthorizationStatus is an enumeration used to represent the authorization level of a script.\u003c/p\u003e\n"],["\u003cp\u003eScripts may require user authorization to access certain services, indicated by \u003ccode\u003eScriptApp.AuthorizationStatus.REQUIRED\u003c/code\u003e.\u003c/p\u003e\n"],["\u003cp\u003eIf a script has all necessary authorizations, its status is represented by \u003ccode\u003eScriptApp.AuthorizationStatus.NOT_REQUIRED\u003c/code\u003e.\u003c/p\u003e\n"],["\u003cp\u003eAdd-ons using installable triggers might run without explicit authorization prompts but will throw exceptions when attempting to use unauthorized services.\u003c/p\u003e\n"]]],[],null,["# Enum AuthorizationStatus\n\nAuthorizationStatus\n\nAn enumeration denoting the authorization status of a script.\n\nTo call an enum, you call its parent class, name, and property. For example, `\nScriptApp.AuthorizationStatus.REQUIRED`. \n\n### Properties\n\n| Property | Type | Description |\n|----------------|--------|---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| `REQUIRED` | `Enum` | The user needs to authorize this script to use one or more services. In most cases, the script prompts the user for authorization the next time it runs; however, if the script is published as an [add-on](/gsuite/add-ons/overview) that uses [installable triggers](/apps-script/understanding_triggers), the trigger runs the script without prompting for authorization but throws an exception if the script attempts to call the unauthorized service. |\n| `NOT_REQUIRED` | `Enum` | The user has granted this script all the authorization it currently requires. |"]]