Extensions Domain
Defines commands and events for browser extensions.
Methods
- Extensions.clearStorageItems
- Extensions.getExtensions
- Extensions.getStorageItems
- Extensions.loadUnpacked
- Extensions.removeStorageItems
- Extensions.setStorageItems
- Extensions.triggerAction
- Extensions.uninstall
Types
Methods
Extensions.clearStorageItems #
Clears extension storage in the given storageArea.
Parameters
id stringID of extension.
storageArea StorageArea to remove data from.
Extensions.getExtensions #
Gets a list of all unpacked extensions. Available if the client is connected using the --remote-debugging-pipe flag and the --enable-unsafe-extension-debugging flag is set.
Return object
extensions array[ ExtensionInfo ]Extensions.getStorageItems #
Gets data from extension storage in the given storageArea. If keys is
specified, these are used to filter the result.
Parameters
id stringID of extension.
storageArea StorageArea to retrieve data from.
keysOptional
array[ string ]Keys to retrieve.
Return object
data objectExtensions.loadUnpacked #
Installs an unpacked extension from the filesystem similar to --load-extension CLI flags. Returns extension ID once the extension has been installed. Available if the client is connected using the --remote-debugging-pipe flag and the --enable-unsafe-extension-debugging flag is set.
Parameters
path stringAbsolute file path.
enableInIncognitoOptional
booleanEnable the extension in incognito
Return object
id stringExtension id.
Extensions.removeStorageItems #
Removes keys from extension storage in the given storageArea.
Parameters
id stringID of extension.
storageArea StorageArea to remove data from.
keys array[ string ]Keys to remove.
Extensions.setStorageItems #
Sets values in extension storage in the given storageArea. The provided values
will be merged with existing values in the storage area.
Parameters
id stringID of extension.
storageArea StorageArea to set data in.
values objectValues to set.
Extensions.triggerAction #
Runs an extension default action. Available if the client is connected using the --remote-debugging-pipe flag and the --enable-unsafe-extension-debugging flag is set.
Parameters
id stringExtension id.
targetId stringA tab target ID to trigger the default extension action on.
Extensions.uninstall #
Uninstalls an unpacked extension (others not supported) from the profile. Available if the client is connected using the --remote-debugging-pipe flag and the --enable-unsafe-extension-debugging.
Parameters
id stringExtension id.
Types
Extensions.ExtensionInfo #
Detailed information about an extension.
Type: object
Properties
id stringExtension id.
name stringExtension name.
version stringExtension version.
path stringThe path from which the extension was loaded.
enabled booleanExtension enabled status.