[[["Mudah dipahami","easyToUnderstand","thumb-up"],["Memecahkan masalah saya","solvedMyProblem","thumb-up"],["Lainnya","otherUp","thumb-up"]],[["Informasi yang saya butuhkan tidak ada","missingTheInformationINeed","thumb-down"],["Terlalu rumit/langkahnya terlalu banyak","tooComplicatedTooManySteps","thumb-down"],["Sudah usang","outOfDate","thumb-down"],["Masalah terjemahan","translationIssue","thumb-down"],["Masalah kode / contoh","samplesCodeIssue","thumb-down"],["Lainnya","otherDown","thumb-down"]],["Terakhir diperbarui pada 2025-07-26 UTC."],[[["\u003cp\u003e\u003ccode\u003eAuthorizationException\u003c/code\u003e triggers an authorization card to obtain user authorization.\u003c/p\u003e\n"],["\u003cp\u003eIt allows setting an authorization URL, a resource display name, and optionally, a custom authorization prompt.\u003c/p\u003e\n"],["\u003cp\u003eDevelopers use \u003ccode\u003esetAuthorizationUrl()\u003c/code\u003e, \u003ccode\u003esetResourceDisplayName()\u003c/code\u003e, and \u003ccode\u003esetCustomUiCallback()\u003c/code\u003e to configure the authorization request.\u003c/p\u003e\n"],["\u003cp\u003e\u003ccode\u003ethrowException()\u003c/code\u003e initiates the authorization flow, prompting the user to grant access.\u003c/p\u003e\n"],["\u003cp\u003eDebugging is facilitated by \u003ccode\u003eprintJson()\u003c/code\u003e which outputs the object's JSON representation.\u003c/p\u003e\n"]]],[],null,["AuthorizationException\n\nAn error that can be returned to trigger an authorization card to be shown to the user.\n\n```javascript\nCardService.newAuthorizationException()\n .setAuthorizationUrl('http://auth.com/')\n .setResourceDisplayName('Example Resource')\n .throwException();\n``` \n\nMethods\n\n| Method | Return type | Brief description |\n|-----------------------------------------------------------------|-----------------------------|---------------------------------------------------------------------------------|\n| [printJson()](#printJson()) | `String` | Prints the JSON representation of this object. |\n| [setAuthorizationUrl(authUrl)](#setAuthorizationUrl(String)) | [AuthorizationException](#) | Sets the authorization URL that user is taken to from the authorization prompt. |\n| [setCustomUiCallback(callback)](#setCustomUiCallback(String)) | [AuthorizationException](#) | The name of a function to call to generate a custom authorization prompt. |\n| [setResourceDisplayName(name)](#setResourceDisplayName(String)) | [AuthorizationException](#) | Sets the name that is displayed to the user when asking for authorization. |\n| [throwException()](#throwException()) | `void` | Triggers this exception to be thrown. |\n\nDetailed documentation \n\n`print``Json()` \nPrints the JSON representation of this object. This is for debugging only.\n\nReturn\n\n\n`String`\n\n*** ** * ** ***\n\n`set``Authorization``Url(authUrl)` \nSets the authorization URL that user is taken to from the authorization prompt. Required.\n\nParameters\n\n| Name | Type | Description |\n|-------------|----------|-------------------------------|\n| `auth``Url` | `String` | The authorization URL to set. |\n\nReturn\n\n\n[AuthorizationException](#) --- This object, for chaining.\n\n*** ** * ** ***\n\n`set``Custom``Ui``Callback(callback)` \nThe name of a function to call to generate a custom authorization prompt. Optional.\n\nParameters\n\n| Name | Type | Description |\n|------------|----------|------------------------------------------------------------------------|\n| `callback` | `String` | The name of the function that generates a custom authorization prompt. |\n\nReturn\n\n\n[AuthorizationException](#) --- This object, for chaining.\n\n*** ** * ** ***\n\n`set``Resource``Display``Name(name)` \nSets the name that is displayed to the user when asking for authorization. Required.\n\nParameters\n\n| Name | Type | Description |\n|--------|----------|-------------------|\n| `name` | `String` | The display name. |\n\nReturn\n\n\n[AuthorizationException](#) --- This object, for chaining.\n\n*** ** * ** ***\n\n`throw``Exception()` \nTriggers this exception to be thrown."]]