1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
7 "namespace":"management",
8 "description": "The <code>chrome.management</code> API provides ways to manage the list of extensions/apps that are installed and running. It is particularly useful for extensions that <a href='override.html'>override</a> the built-in New Tab page.",
12 "description": "Information about an icon belonging to an extension, app, or theme.",
15 "size": { "type": "integer", "description": "A number representing the width and height of the icon. Likely values include (but are not limited to) 128, 48, 24, and 16." },
16 "url": { "type": "string", "description": "The URL for this icon image. To display a grayscale version of the icon (to indicate that an extension is disabled, for example), append <code>?grayscale=true</code> to the URL." }
20 "id": "ExtensionInfo",
21 "description": "Information about an installed extension, app, or theme.",
25 "description": "The extension's unique identifier.",
29 "description": "The name of this extension, app, or theme.",
33 "description": "A short version of the name of this extension, app, or theme.",
37 "description": "The description of this extension, app, or theme.",
41 "description": "The <a href='manifest/version.html'>version</a> of this extension, app, or theme.",
45 "description": "Whether this extension can be disabled or uninstalled by the user.",
49 "description": "Whether it is currently enabled or disabled.",
53 "description": "A reason the item is disabled.",
55 "enum": ["unknown", "permissions_increase"],
59 "description": "True if this is an app.",
61 "deprecated": "Please use $(ref:management.ExtensionInfo.type)."
64 "description": "The type of this extension, app, or theme.",
66 "enum": ["extension", "hosted_app", "packaged_app", "legacy_packaged_app", "theme"]
69 "description": "The launch url (only present for apps).",
74 "description": "The URL of the homepage of this extension, app, or theme.",
79 "description": "The update URL of this extension, app, or theme.",
84 "description": "Whether the extension, app, or theme declares that it supports offline.",
88 "description": "The url for the item's options page, if it has one.",
92 "description": "A list of icon information. Note that this just reflects what was declared in the manifest, and the actual image at that url may be larger or smaller than what was declared, so you might consider using explicit width and height attributes on img tags referencing these images. See the <a href='manifest/icons.html'>manifest documentation on icons</a> for more details.",
100 "description": "Returns a list of API based permissions.",
107 "description": "Returns a list of host based permissions.",
114 "description": "How the extension was installed. One of<br><var>admin</var>: The extension was installed because of an administrative policy,<br><var>development</var>: The extension was loaded unpacked in developer mode,<br><var>normal</var>: The extension was installed normally via a .crx file,<br><var>sideload</var>: The extension was installed by other software on the machine,<br><var>other</var>: The extension was installed by other means.",
116 "enum": ["admin", "development", "normal", "sideload", "other"]
124 "description": "Returns a list of information about installed extensions and apps.",
135 "$ref": "ExtensionInfo"
144 "description": "Returns information about the installed extension, app, or theme that has the given ID.",
149 "description": "The ID from an item of $(ref:management.ExtensionInfo)."
158 "$ref": "ExtensionInfo"
165 "name": "getPermissionWarningsById",
166 "description": "Returns a list of <a href='permission_warnings.html'>permission warnings</a> for the given extension id.",
170 "description": "The ID of an already installed extension."
178 "name": "permissionWarnings",
180 "items": { "type": "string" }
187 "name": "getPermissionWarningsByManifest",
188 "description": "Returns a list of <a href='permission_warnings.html'>permission warnings</a> for the given extension manifest string. Note: This function can be used without requesting the 'management' permission in the manifest.",
191 "name": "manifestStr",
193 "description": "Extension manifest JSON string."
201 "name": "permissionWarnings",
203 "items": { "type": "string" }
210 "name": "setEnabled",
211 "description": "Enables or disables an app or extension.",
216 "description": "This should be the id from an item of $(ref:management.ExtensionInfo)."
221 "description": "Whether this item should be enabled or disabled."
233 "description": "Uninstalls a currently installed app or extension.",
238 "description": "This should be the id from an item of $(ref:management.ExtensionInfo)."
245 "showConfirmDialog": {
248 "description": "Whether or not a confirm-uninstall dialog should prompt the user. Defaults to false."
261 "name": "uninstallSelf",
262 "description": "Uninstalls the calling extension. Note: This function can be used without requesting the 'management' permission in the manifest.",
269 "showConfirmDialog": {
272 "description": "Whether or not a confirm-uninstall dialog should prompt the user. Defaults to false."
286 "description": "Launches an application.",
291 "description": "The extension id of the application."
302 "name": "createAppShortcut",
303 "description": "Display options to create shortcuts for an app. On Mac, only packaged app shortcuts can be created. Note: This function is only available to Chrome users on the dev channel.",
308 "description": "This should be the id from an app item of $(ref:management.ExtensionInfo)."
321 "name": "onInstalled",
322 "description": "Fired when an app or extension has been installed.",
324 "parameters": [{"name": "info", "$ref":"ExtensionInfo"}]
327 "name": "onUninstalled",
328 "description": "Fired when an app or extension has been uninstalled.",
334 "description": "The id of the extension, app, or theme that was uninstalled."
340 "description": "Fired when an app or extension has been enabled.",
342 "parameters": [{"name": "info", "$ref":"ExtensionInfo"}]
345 "name": "onDisabled",
346 "description": "Fired when an app or extension has been disabled.",
348 "parameters": [{"name": "info", "$ref":"ExtensionInfo"}]