@types/chrome 0.0.292 → 0.0.294

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (3) hide show
  1. chrome/README.md +1 -1
  2. chrome/index.d.ts +326 -303
  3. chrome/package.json +2 -2
chrome/README.md CHANGED
@@ -8,7 +8,7 @@ This package contains type definitions for chrome (http://developer.chrome.com/e
8
8
  Files were exported from https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/chrome.
9
9
 
10
10
  ### Additional Details
11
- * Last updated: Thu, 09 Jan 2025 11:32:09 GMT
11
+ * Last updated: Tue, 14 Jan 2025 07:02:19 GMT
12
12
  * Dependencies: [@types/filesystem](https://npmjs.com/package/@types/filesystem), [@types/har-format](https://npmjs.com/package/@types/har-format)
13
13
 
14
14
  # Credits
chrome/index.d.ts CHANGED
@@ -14,7 +14,8 @@ declare namespace chrome {
14
14
  // Accessibility Features
15
15
  ////////////////////
16
16
  /**
17
- * Use the chrome.accessibilityFeatures API to manage Chrome's accessibility features. This API relies on the ChromeSetting prototype of the type API for getting and setting individual accessibility features. In order to get feature states the extension must request `accessibilityFeatures.read` permission. For modifying feature state, the extension needs `accessibilityFeatures.modify` permission. Note that `accessibilityFeatures.modify` does not imply `accessibilityFeatures.read` permission.
17
+ * Use the `chrome.accessibilityFeatures` API to manage Chrome's accessibility features. This API relies on the ChromeSetting prototype of the type API for getting and setting individual accessibility features. In order to get feature states the extension must request `accessibilityFeatures.read` permission. For modifying feature state, the extension needs `accessibilityFeatures.modify` permission. Note that `accessibilityFeatures.modify` does not imply `accessibilityFeatures.read` permission.
18
+ *
18
19
  * Permissions: "accessibilityFeatures.read", "accessibilityFeatures.modify"
19
20
  */
20
21
  export namespace accessibilityFeatures {
@@ -139,9 +140,11 @@ declare namespace chrome {
139
140
  // Action
140
141
  ////////////////////
141
142
  /**
142
- * Use the chrome.action API to control the extension's icon in the Google Chrome toolbar.
143
+ * Use the `chrome.action` API to control the extension's icon in the Google Chrome toolbar.
144
+ * The action icons are displayed in the browser toolbar next to the omnibox. After installation, these appear in the extensions menu (the puzzle piece icon). Users can pin your extension icon to the toolbar.
145
+ *
146
+ * Manifest: "action"
143
147
  * @since Chrome 88, MV3
144
- * Manifest: "action": {...}
145
148
  */
146
149
  export namespace action {
147
150
  /** @deprecated Use BadgeColorDetails instead. */
@@ -444,9 +447,9 @@ declare namespace chrome {
444
447
  // Alarms
445
448
  ////////////////////
446
449
  /**
447
- * Use the chrome.alarms API to schedule code to run periodically or at a specified time in the future.
448
- * @since Chrome 22
449
- * Permissions: "alarms"
450
+ * Use the `chrome.alarms` API to schedule code to run periodically or at a specified time in the future.
451
+ *
452
+ * Permissions: "alarms"
450
453
  */
451
454
  export namespace alarms {
452
455
  export interface AlarmCreateInfo {
@@ -570,11 +573,9 @@ declare namespace chrome {
570
573
  // Audio
571
574
  ////////////////////
572
575
  /**
573
- * The chrome.audio API is provided to allow users to get information about and control the audio devices attached to the system.
574
- * This API is currently only available in kiosk mode for ChromeOS.
576
+ * The `chrome.audio` API is provided to allow users to get information about and control the audio devices attached to the system. This API is currently only available in kiosk mode for ChromeOS.
575
577
  *
576
578
  * Permissions: "audio"
577
- *
578
579
  * @platform ChromeOS only
579
580
  * @since Chrome 59
580
581
  */
@@ -758,9 +759,9 @@ declare namespace chrome {
758
759
  // Bookmarks
759
760
  ////////////////////
760
761
  /**
761
- * Use the chrome.bookmarks API to create, organize, and otherwise manipulate bookmarks. Also see Override Pages, which you can use to create a custom Bookmark Manager page.
762
- * @since Chrome 5
763
- * Permissions: "bookmarks"
762
+ * Use the `chrome.bookmarks` API to create, organize, and otherwise manipulate bookmarks. Also see Override Pages, which you can use to create a custom Bookmark Manager page.
763
+ *
764
+ * Permissions: "bookmarks"
764
765
  */
765
766
  export namespace bookmarks {
766
767
  /** A node (either a bookmark or a folder) in the bookmark tree. Child nodes are ordered within their parent folder. */
@@ -1030,9 +1031,11 @@ declare namespace chrome {
1030
1031
  // Browser Action
1031
1032
  ////////////////////
1032
1033
  /**
1033
- * Use browser actions to put icons in the main Google Chrome toolbar, to the right of the address bar. In addition to its icon, a browser action can also have a tooltip, a badge, and a popup.
1034
- * @since Chrome 5
1035
- * Manifest: "browser_action": {...}
1034
+ * Use browser actions to put icons in the main Google Chrome toolbar, to the right of the address bar. In addition to its icon, a browser action can have a tooltip, a badge, and a popup.
1035
+ *
1036
+ * Manifest: "browser_action"
1037
+ *
1038
+ * MV2 only
1036
1039
  */
1037
1040
  export namespace browserAction {
1038
1041
  export interface BadgeBackgroundColorDetails {
@@ -1209,9 +1212,9 @@ declare namespace chrome {
1209
1212
  // Browsing Data
1210
1213
  ////////////////////
1211
1214
  /**
1212
- * Use the chrome.browsingData API to remove browsing data from a user's local profile.
1213
- * @since Chrome 19
1214
- * Permissions: "browsingData"
1215
+ * Use the `chrome.browsingData` API to remove browsing data from a user's local profile.
1216
+ *
1217
+ * Permissions: "browsingData"
1215
1218
  */
1216
1219
  export namespace browsingData {
1217
1220
  export interface OriginTypes {
@@ -1484,8 +1487,8 @@ declare namespace chrome {
1484
1487
  ////////////////////
1485
1488
  /**
1486
1489
  * Use the commands API to add keyboard shortcuts that trigger actions in your extension, for example, an action to open the browser action or send a command to the extension.
1487
- * @since Chrome 25
1488
- * Manifest: "commands": {...}
1490
+ *
1491
+ * Manifest: "commands"
1489
1492
  */
1490
1493
  export namespace commands {
1491
1494
  export interface Command {
@@ -1518,9 +1521,9 @@ declare namespace chrome {
1518
1521
  // Content Settings
1519
1522
  ////////////////////
1520
1523
  /**
1521
- * Use the chrome.contentSettings API to change settings that control whether websites can use features such as cookies, JavaScript, and plugins. More generally speaking, content settings allow you to customize Chrome's behavior on a per-site basis instead of globally.
1522
- * @since Chrome 16
1523
- * Permissions: "contentSettings"
1524
+ * Use the `chrome.contentSettings` API to change settings that control whether websites can use features such as cookies, JavaScript, and plugins. More generally speaking, content settings allow you to customize Chrome's behavior on a per-site basis instead of globally.
1525
+ *
1526
+ * Permissions: "contentSettings"
1524
1527
  */
1525
1528
  export namespace contentSettings {
1526
1529
  type ScopeEnum = "regular" | "incognito_session_only";
@@ -1843,9 +1846,9 @@ declare namespace chrome {
1843
1846
  // Context Menus
1844
1847
  ////////////////////
1845
1848
  /**
1846
- * Use the chrome.contextMenus API to add items to Google Chrome's context menu. You can choose what types of objects your context menu additions apply to, such as images, hyperlinks, and pages.
1847
- * @since Chrome 6
1848
- * Permissions: "contextMenus"
1849
+ * Use the `chrome.contextMenus` API to add items to Google Chrome's context menu. You can choose what types of objects your context menu additions apply to, such as images, hyperlinks, and pages.
1850
+ *
1851
+ * Permissions: "contextMenus"
1849
1852
  */
1850
1853
  export namespace contextMenus {
1851
1854
  export interface OnClickData {
@@ -2046,9 +2049,11 @@ declare namespace chrome {
2046
2049
  // Cookies
2047
2050
  ////////////////////
2048
2051
  /**
2049
- * Use the chrome.cookies API to query and modify cookies, and to be notified when they change.
2050
- * @since Chrome 6
2051
- * Permissions: "cookies", host permissions
2052
+ * Use the `chrome.cookies` API to query and modify cookies, and to be notified when they change.
2053
+ *
2054
+ * Permissions: "cookies"
2055
+ *
2056
+ * Manifest: "host_permissions"
2052
2057
  */
2053
2058
  export namespace cookies {
2054
2059
  /** A cookie's 'SameSite' state (https://tools.ietf.org/html/draft-west-first-party-cookies). 'no_restriction' corresponds to a cookie set with 'SameSite=None', 'lax' to 'SameSite=Lax', and 'strict' to 'SameSite=Strict'. 'unspecified' corresponds to a cookie set without the SameSite attribute. **/
@@ -2255,9 +2260,9 @@ declare namespace chrome {
2255
2260
  // Debugger
2256
2261
  ////////////////////
2257
2262
  /**
2258
- * The chrome.debugger API serves as an alternate transport for Chrome's remote debugging protocol. Use chrome.debugger to attach to one or more tabs to instrument network interaction, debug JavaScript, mutate the DOM and CSS, etc. Use the Debuggee tabId to target tabs with sendCommand and route events by tabId from onEvent callbacks.
2259
- * @since Chrome 18
2260
- * Permissions: "debugger"
2263
+ * The `chrome.debugger` API serves as an alternate transport for Chrome's remote debugging protocol. Use `chrome.debugger` to attach to one or more tabs to instrument network interaction, debug JavaScript, mutate the DOM and CSS, and more. Use the {@link Debuggee} `tabId` to target tabs with `sendCommand` and route events by `tabId` from `onEvent` callbacks.
2264
+ *
2265
+ * Permissions: "debugger"
2261
2266
  */
2262
2267
  export namespace _debugger {
2263
2268
  /** Debuggee identifier. Either tabId or extensionId must be specified */
@@ -2390,13 +2395,14 @@ declare namespace chrome {
2390
2395
  }
2391
2396
 
2392
2397
  export { _debugger as debugger };
2398
+
2393
2399
  ////////////////////
2394
2400
  // Declarative Content
2395
2401
  ////////////////////
2396
2402
  /**
2397
- * Use the chrome.declarativeContent API to take actions depending on the content of a page, without requiring permission to read the page's content.
2398
- * @since Chrome 33
2399
- * Permissions: "declarativeContent"
2403
+ * Use the `chrome.declarativeContent` API to take actions depending on the content of a page, without requiring permission to read the page's content.
2404
+ *
2405
+ * Permissions: "declarativeContent"
2400
2406
  */
2401
2407
  export namespace declarativeContent {
2402
2408
  export interface PageStateUrlDetails {
@@ -2486,6 +2492,14 @@ declare namespace chrome {
2486
2492
  ////////////////////
2487
2493
  // Declarative Web Request
2488
2494
  ////////////////////
2495
+ /**
2496
+ * Use the `chrome.declarativeWebRequest` API to intercept, block, or modify requests in-flight. It is significantly faster than the chrome.webRequest API because you can register rules that are evaluated in the browser rather than the JavaScript engine, which reduces roundtrip latencies and allows higher efficiency.
2497
+ *
2498
+ * Permissions: "declarativeWebRequest"
2499
+ *
2500
+ * MV2 only
2501
+ * @deprecated Check out the {@link declarativeNetRequest} API instead
2502
+ */
2489
2503
  export namespace declarativeWebRequest {
2490
2504
  export interface HeaderFilter {
2491
2505
  nameEquals?: string | undefined;
@@ -2596,9 +2610,9 @@ declare namespace chrome {
2596
2610
  // DesktopCapture
2597
2611
  ////////////////////
2598
2612
  /**
2599
- * Desktop Capture API that can be used to capture content of screen, individual windows or tabs.
2600
- * @since Chrome 34
2601
- * Permissions: "desktopCapture"
2613
+ * The Desktop Capture API captures the content of the screen, individual windows, or individual tabs.
2614
+ *
2615
+ * Permissions: "desktopCapture"
2602
2616
  */
2603
2617
  export namespace desktopCapture {
2604
2618
  /** Contains properties that describe the stream. */
@@ -2637,8 +2651,9 @@ declare namespace chrome {
2637
2651
  // Dev Tools - Inspected Window
2638
2652
  ////////////////////
2639
2653
  /**
2640
- * Use the chrome.devtools.inspectedWindow API to interact with the inspected window: obtain the tab ID for the inspected page, evaluate the code in the context of the inspected window, reload the page, or obtain the list of resources within the page.
2641
- * @since Chrome 18
2654
+ * Use the `chrome.devtools.inspectedWindow` API to interact with the inspected window: obtain the tab ID for the inspected page, evaluate the code in the context of the inspected window, reload the page, or obtain the list of resources within the page.
2655
+ *
2656
+ * Manifest: "devtools_page"
2642
2657
  */
2643
2658
  export namespace devtools.inspectedWindow {
2644
2659
  /** A resource within the inspected page, such as a document, a script, or an image. */
@@ -2765,8 +2780,9 @@ declare namespace chrome {
2765
2780
  // Dev Tools - Network
2766
2781
  ////////////////////
2767
2782
  /**
2768
- * Use the chrome.devtools.network API to retrieve the information about network requests displayed by the Developer Tools in the Network panel.
2769
- * @since Chrome 18
2783
+ * Use the `chrome.devtools.network` API to retrieve the information about network requests displayed by the Developer Tools in the Network panel.
2784
+ *
2785
+ * Manifest: "devtools_page"
2770
2786
  */
2771
2787
  export namespace devtools.network {
2772
2788
  /** Represents a HAR entry for a specific finished request. */
@@ -2810,8 +2826,8 @@ declare namespace chrome {
2810
2826
  // Dev Tools - Performance
2811
2827
  ////////////////////
2812
2828
  /**
2813
- * The chrome.devtools.performance API allows developers to interact with the recording features of the Performance panel in Chrome DevTools. You can use this API to get notifications when recording starts or stops.
2814
- * @since Chrome 128
2829
+ * Use the `chrome.devtools.performance` API to listen to recording status updates in the Performance panel in DevTools.
2830
+ * @since Chrome 129
2815
2831
  */
2816
2832
  export namespace devtools.performance {
2817
2833
  export interface ProfilingStartedEvent extends chrome.events.Event<() => void> {}
@@ -2828,8 +2844,9 @@ declare namespace chrome {
2828
2844
  // Dev Tools - Panels
2829
2845
  ////////////////////
2830
2846
  /**
2831
- * Use the chrome.devtools.panels API to integrate your extension into Developer Tools window UI: create your own panels, access existing panels, and add sidebars.
2832
- * @since Chrome 18
2847
+ * Use the `chrome.devtools.panels` API to integrate your extension into Developer Tools window UI: create your own panels, access existing panels, and add sidebars.
2848
+ *
2849
+ * Manifest: "devtools_page"
2833
2850
  */
2834
2851
  export namespace devtools.panels {
2835
2852
  export interface PanelShownEvent extends chrome.events.Event<(window: Window) => void> {}
@@ -3022,10 +3039,12 @@ declare namespace chrome {
3022
3039
  // Document Scan
3023
3040
  ////////////////////
3024
3041
  /**
3025
- * Use the chrome.documentScan API to discover and retrieve images from attached paper document scanners.
3042
+ * Use the `chrome.documentScan` API to discover and retrieve images from attached document scanners.
3043
+ * The Document Scan API is designed to allow apps and extensions to view the content of paper documents on an attached document scanner.
3044
+ *
3045
+ * Permissions: "documentScan"
3046
+ * @platform ChromeOS only
3026
3047
  * @since Chrome 44
3027
- * Permissions: "documentScan"
3028
- * Important: This API works only on Chrome OS.
3029
3048
  */
3030
3049
  export namespace documentScan {
3031
3050
  export interface DocumentScanOptions {
@@ -3054,7 +3073,7 @@ declare namespace chrome {
3054
3073
  // DOM
3055
3074
  ////////////////////
3056
3075
  /**
3057
- * Use the chrome.dom API to programmatically access shadow root in an HTMLElement.
3076
+ * Use the `chrome.dom` API to access special DOM APIs for Extensions
3058
3077
  * @since Chrome 88
3059
3078
  */
3060
3079
  export namespace dom {
@@ -3067,12 +3086,12 @@ declare namespace chrome {
3067
3086
  }
3068
3087
 
3069
3088
  ////////////////////
3070
- // Dev Tools - Downloads
3089
+ // Downloads
3071
3090
  ////////////////////
3072
3091
  /**
3073
- * Use the chrome.downloads API to programmatically initiate, monitor, manipulate, and search for downloads.
3074
- * @since Chrome 31
3075
- * Permissions: "downloads"
3092
+ * Use the `chrome.downloads` API to programmatically initiate, monitor, manipulate, and search for downloads.
3093
+ *
3094
+ * Permissions: "downloads"
3076
3095
  */
3077
3096
  export namespace downloads {
3078
3097
  export interface HeaderNameValuePair {
@@ -3472,11 +3491,12 @@ declare namespace chrome {
3472
3491
  // Enterprise Platform Keys
3473
3492
  ////////////////////
3474
3493
  /**
3475
- * Use the chrome.enterprise.platformKeys API to generate hardware-backed keys and to install certificates for these keys. The certificates will be managed by the platform and can be used for TLS authentication, network access or by other extension through chrome.platformKeys.
3476
- * @since Chrome 37
3477
- * Permissions: "enterprise.platformKeys"
3478
- * Important: This API works only on Chrome OS.
3479
- * Note: This API is only for extensions pre-installed by policy.
3494
+ * Use the `chrome.enterprise.platformKeys` API to generate keys and install certificates for these keys. The certificates will be managed by the platform and can be used for TLS authentication, network access or by other extension through {@link chrome.platformKeys}.
3495
+ *
3496
+ * Permissions: "enterprise.platformKeys"
3497
+ *
3498
+ * Note: Only available to policy installed extensions.
3499
+ * @platform ChromeOS only
3480
3500
  */
3481
3501
  export namespace enterprise.platformKeys {
3482
3502
  export interface Token {
@@ -3647,11 +3667,13 @@ declare namespace chrome {
3647
3667
  // Enterprise Device Attributes
3648
3668
  ////////////////////
3649
3669
  /**
3650
- * Use the <code>chrome.enterprise.deviceAttributes</code> API to read device attributes.
3651
- * Permissions: "enterprise.deviceAttributes"
3670
+ * Use the `chrome.enterprise.deviceAttributes` API to read device attributes.
3671
+ *
3672
+ * Permissions: "enterprise.deviceAttributes"
3673
+ *
3674
+ * Note: Only available to policy installed extensions.
3675
+ * @platform ChromeOS only
3652
3676
  * @since Chrome 46
3653
- * Important: This API works only on Chrome OS.
3654
- * Note: This API is only for extensions pre-installed by policy.
3655
3677
  */
3656
3678
  export namespace enterprise.deviceAttributes {
3657
3679
  /**
@@ -3700,12 +3722,11 @@ declare namespace chrome {
3700
3722
  // Enterprise Hardware Platform
3701
3723
  ////////////////////
3702
3724
  /**
3703
- * Use the chrome.enterprise.hardwarePlatform API to get the manufacturer and model of the hardware platform where the browser runs.
3725
+ * Use the `chrome.enterprise.hardwarePlatform` API to get the manufacturer and model of the hardware platform where the browser runs.
3704
3726
  *
3705
3727
  * Permissions: "enterprise.hardwarePlatform"
3706
3728
  *
3707
- * Note: This API is only for extensions pre-installed by policy.
3708
- * @platform ChromeOS only
3729
+ * Note: Only available to policy installed extensions.
3709
3730
  * @since Chrome 71
3710
3731
  */
3711
3732
  export namespace enterprise.hardwarePlatform {
@@ -3726,8 +3747,12 @@ declare namespace chrome {
3726
3747
  // Enterprise Networking Attributes
3727
3748
  ////////////////////
3728
3749
  /**
3729
- * Use the <code>chrome.enterprise.networkingAttributes</code> API to read information about your current network. Note: This API is only available to extensions force-installed by enterprise policy.
3730
- * Important: This API works only on Chrome OS.
3750
+ * Use the `chrome.enterprise.networkingAttributes` API to read information about your current network. Note: This API is only available to extensions force-installed by enterprise policy.
3751
+ *
3752
+ * Permissions: "enterprise.networkingAttributes"
3753
+ *
3754
+ * Note: Only available to policy installed extensions.
3755
+ * @platform ChromeOS only
3731
3756
  * @since Chrome 85
3732
3757
  */
3733
3758
  export namespace enterprise.networkingAttributes {
@@ -3751,8 +3776,7 @@ declare namespace chrome {
3751
3776
  // Events
3752
3777
  ////////////////////
3753
3778
  /**
3754
- * The chrome.events namespace contains common types used by APIs dispatching events to notify you when something interesting happens.
3755
- * @since Chrome 21
3779
+ * The `chrome.events` namespace contains common types used by APIs dispatching events to notify you when something interesting happens.
3756
3780
  */
3757
3781
  export namespace events {
3758
3782
  /** Filters URLs for various criteria. See event filtering. All criteria are case sensitive. */
@@ -3807,8 +3831,12 @@ declare namespace chrome {
3807
3831
  originAndPathMatches?: string | undefined;
3808
3832
  }
3809
3833
 
3810
- export interface BaseEvent<T extends Function> {
3811
- addListener(callback: T, filter?: webRequest.RequestFilter): void;
3834
+ export interface Event<T extends Function> {
3835
+ /**
3836
+ * Registers an event listener callback to an event.
3837
+ * @param callback Called when an event occurs. The parameters of this function depend on the type of event.
3838
+ */
3839
+ addListener(callback: T): void;
3812
3840
  /**
3813
3841
  * Returns currently registered rules.
3814
3842
  * @param callback Called with registered rules.
@@ -3866,18 +3894,6 @@ declare namespace chrome {
3866
3894
  hasListeners(): boolean;
3867
3895
  }
3868
3896
 
3869
- /** An object which allows the addition and removal of listeners for a Chrome event. */
3870
- interface Event<T extends Function> extends BaseEvent<T> {
3871
- /**
3872
- * Registers an event listener callback to an event.
3873
- * @param callback Called when an event occurs. The parameters of this function depend on the type of event.
3874
- */
3875
- addListener(callback: T): void;
3876
- }
3877
- export interface EventWithRequiredFilterInAddListener<T extends Function> extends BaseEvent<T> {
3878
- addListener(callback: T, filter: webRequest.RequestFilter): void;
3879
- }
3880
-
3881
3897
  /** Description of a declarative rule for handling events. */
3882
3898
  export interface Rule {
3883
3899
  /** Optional. Optional priority of this rule. Defaults to 100. */
@@ -3901,8 +3917,7 @@ declare namespace chrome {
3901
3917
  // Extension
3902
3918
  ////////////////////
3903
3919
  /**
3904
- * The chrome.extension API has utilities that can be used by any extension page. It includes support for exchanging messages between an extension and its content scripts or between extensions, as described in detail in Message Passing.
3905
- * @since Chrome 5
3920
+ * The `chrome.extension` API has utilities that can be used by any extension page. It includes support for exchanging messages between an extension and its content scripts or between extensions, as described in detail in Message Passing.
3906
3921
  */
3907
3922
  export namespace extension {
3908
3923
  export interface FetchProperties {
@@ -4022,10 +4037,10 @@ declare namespace chrome {
4022
4037
  // File Browser Handler
4023
4038
  ////////////////////
4024
4039
  /**
4025
- * Use the chrome.fileBrowserHandler API to extend the Chrome OS file browser. For example, you can use this API to enable users to upload files to your website.
4026
- * @since Chrome 12
4027
- * Permissions: "fileBrowserHandler"
4028
- * Important: This API works only on Chrome OS.
4040
+ * Use the `chrome.fileBrowserHandler` API to extend the Chrome OS file browser. For example, you can use this API to enable users to upload files to your website.
4041
+ *
4042
+ * Permissions: "fileBrowserHandler"
4043
+ * @platform ChromeOS only
4029
4044
  */
4030
4045
  export namespace fileBrowserHandler {
4031
4046
  export interface SelectionParams {
@@ -4075,10 +4090,10 @@ declare namespace chrome {
4075
4090
  // File System Provider
4076
4091
  ////////////////////
4077
4092
  /**
4078
- * Use the chrome.fileSystemProvider API to create file systems, that can be accessible from the file manager on Chrome OS.
4079
- * @since Chrome 40
4080
- * Permissions: "fileSystemProvider"
4081
- * Important: This API works only on Chrome OS.
4093
+ * Use the `chrome.fileSystemProvider` API to create file systems, that can be accessible from the file manager on Chrome OS.
4094
+ *
4095
+ * Permissions: "fileSystemProvider"
4096
+ * @platform ChromeOS only
4082
4097
  */
4083
4098
  export namespace fileSystemProvider {
4084
4099
  export interface OpenedFileInfo {
@@ -4607,9 +4622,9 @@ declare namespace chrome {
4607
4622
  // Font Settings
4608
4623
  ////////////////////
4609
4624
  /**
4610
- * Use the chrome.fontSettings API to manage Chrome's font settings.
4611
- * @since Chrome 22
4612
- * Permissions: "fontSettings"
4625
+ * Use the `chrome.fontSettings` API to manage Chrome's font settings.
4626
+ *
4627
+ * Permissions: "fontSettings"
4613
4628
  */
4614
4629
  export namespace fontSettings {
4615
4630
  /** Represents a font name. */
@@ -4832,9 +4847,9 @@ declare namespace chrome {
4832
4847
  // Google Cloud Messaging
4833
4848
  ////////////////////
4834
4849
  /**
4835
- * Use chrome.gcm to enable apps and extensions to send and receive messages through the Google Cloud Messaging Service.
4836
- * @since Chrome 35
4837
- * Permissions: "gcm"
4850
+ * Use `chrome.gcm` to enable apps and extensions to send and receive messages through Firebase Cloud Messaging (FCM).
4851
+ *
4852
+ * Permissions: "gcm"
4838
4853
  */
4839
4854
  export namespace gcm {
4840
4855
  export interface OutgoingMessage {
@@ -4914,9 +4929,9 @@ declare namespace chrome {
4914
4929
  // History
4915
4930
  ////////////////////
4916
4931
  /**
4917
- * Use the chrome.history API to interact with the browser's record of visited pages. You can add, remove, and query for URLs in the browser's history. To override the history page with your own version, see Override Pages.
4918
- * @since Chrome 5
4919
- * Permissions: "history"
4932
+ * Use the `chrome.history` API to interact with the browser's record of visited pages. You can add, remove, and query for URLs in the browser's history. To override the history page with your own version, see Override Pages.
4933
+ *
4934
+ * Permissions: "history"
4920
4935
  */
4921
4936
  export namespace history {
4922
4937
  /** An object encapsulating one visit to a URL. */
@@ -5048,8 +5063,9 @@ declare namespace chrome {
5048
5063
  // i18n
5049
5064
  ////////////////////
5050
5065
  /**
5051
- * Use the chrome.i18n infrastructure to implement internationalization across your whole app or extension.
5052
- * @since Chrome 5
5066
+ * Use the `chrome.i18n` infrastructure to implement internationalization across your whole app or extension.
5067
+ *
5068
+ * Manifest: "default_locale"
5053
5069
  */
5054
5070
  export namespace i18n {
5055
5071
  /** Holds detected ISO language code and its percentage in the input string */
@@ -5111,9 +5127,9 @@ declare namespace chrome {
5111
5127
  // Identity
5112
5128
  ////////////////////
5113
5129
  /**
5114
- * Use the chrome.identity API to get OAuth2 access tokens.
5115
- * Permissions: "identity"
5116
- * @since Chrome 29
5130
+ * Use the `chrome.identity` API to get OAuth2 access tokens.
5131
+ *
5132
+ * Permissions: "identity"
5117
5133
  */
5118
5134
  export namespace identity {
5119
5135
  /** @since Chrome 32 */
@@ -5286,9 +5302,9 @@ declare namespace chrome {
5286
5302
  // Idle
5287
5303
  ////////////////////
5288
5304
  /**
5289
- * Use the chrome.idle API to detect when the machine's idle state changes.
5290
- * Permissions: "idle"
5291
- * @since Chrome 6
5305
+ * Use the `chrome.idle` API to detect when the machine's idle state changes.
5306
+ *
5307
+ * Permissions: "idle"
5292
5308
  */
5293
5309
  export namespace idle {
5294
5310
  export type IdleState = "active" | "idle" | "locked";
@@ -5329,9 +5345,10 @@ declare namespace chrome {
5329
5345
  // Input - IME
5330
5346
  ////////////////////
5331
5347
  /**
5332
- * Use the chrome.input.ime API to implement a custom IME for Chrome OS. This allows your extension to handle keystrokes, set the composition, and manage the candidate window.
5333
- * Permissions: "input"
5334
- * @since Chrome 21
5348
+ * Use the `chrome.input.ime` API to implement a custom IME for Chrome OS. This allows your extension to handle keystrokes, set the composition, and manage the candidate window.
5349
+ *
5350
+ * Permissions: "input"
5351
+ * @platform ChromeOS only
5335
5352
  */
5336
5353
  export namespace input.ime {
5337
5354
  /** See http://www.w3.org/TR/DOM-Level-3-Events/#events-KeyboardEvent */
@@ -5809,8 +5826,12 @@ declare namespace chrome {
5809
5826
  export var onReset: InputResetEvent;
5810
5827
  }
5811
5828
 
5829
+ ////////////////////
5830
+ // Instance ID
5831
+ ////////////////////
5812
5832
  /**
5813
- * Use chrome.instanceID to access the Instance ID service.
5833
+ * Use `chrome.instanceID` to access the Instance ID service.
5834
+ *
5814
5835
  * Permissions: "gcm"
5815
5836
  * @since Chrome 44
5816
5837
  */
@@ -5893,10 +5914,11 @@ declare namespace chrome {
5893
5914
  // LoginState
5894
5915
  ////////////////////
5895
5916
  /**
5896
- * Use the chrome.loginState API to read and monitor the login state.
5917
+ * Use the `chrome.loginState` API to read and monitor the login state.
5918
+ *
5897
5919
  * Permissions: "loginState"
5920
+ * @platform ChromeOS only
5898
5921
  * @since Chrome 78
5899
- * Important: This API works only on Chrome OS.
5900
5922
  */
5901
5923
  export namespace loginState {
5902
5924
  export interface SessionStateChangedEvent extends chrome.events.Event<(sessionState: SessionState) => void> {}
@@ -5921,9 +5943,9 @@ declare namespace chrome {
5921
5943
  // Management
5922
5944
  ////////////////////
5923
5945
  /**
5924
- * The chrome.management API provides ways to manage the list of extensions/apps that are installed and running. It is particularly useful for extensions that override the built-in New Tab page.
5925
- * Permissions: "management"
5926
- * @since Chrome 8
5946
+ * The `chrome.management` API provides ways to manage installed apps and extensions.
5947
+ *
5948
+ * Permissions: "management"
5927
5949
  */
5928
5950
  export namespace management {
5929
5951
  /** Information about an installed extension, app, or theme. */
@@ -6241,7 +6263,7 @@ declare namespace chrome {
6241
6263
  }
6242
6264
 
6243
6265
  ////////////////////
6244
- // Notifications
6266
+ // Networking
6245
6267
  ////////////////////
6246
6268
  /**
6247
6269
  * Use the networking.config API to authenticate to captive portals.
@@ -6291,12 +6313,11 @@ declare namespace chrome {
6291
6313
 
6292
6314
  ////////////////////
6293
6315
  // Notifications
6294
- // https://developer.chrome.com/extensions/notifications
6295
6316
  ////////////////////
6296
6317
  /**
6297
- * Use the chrome.notifications API to create rich notifications using templates and show these notifications to users in the system tray.
6298
- * Permissions: "notifications"
6299
- * @since Chrome 28
6318
+ * Use the `chrome.notifications` API to create rich notifications using templates and show these notifications to users in the system tray.
6319
+ *
6320
+ * Permissions: "notifications"
6300
6321
  */
6301
6322
  export namespace notifications {
6302
6323
  export type TemplateType = "basic" | "image" | "list" | "progress";
@@ -6480,9 +6501,10 @@ declare namespace chrome {
6480
6501
  // Offscreen
6481
6502
  ////////////////////
6482
6503
  /**
6483
- * Use the offscreen API to create and manage offscreen documents.
6484
- * @since Chrome 109, MV3
6504
+ * Use the `offscreen` API to create and manage offscreen documents.
6505
+ *
6485
6506
  * Permissions: "offscreen"
6507
+ * @since Chrome 109, MV3
6486
6508
  */
6487
6509
  export namespace offscreen {
6488
6510
  /** The reason(s) the extension is creating the offscreen document. */
@@ -6570,8 +6592,8 @@ declare namespace chrome {
6570
6592
  ////////////////////
6571
6593
  /**
6572
6594
  * The omnibox API allows you to register a keyword with Google Chrome's address bar, which is also known as the omnibox.
6573
- * Manifest: "omnibox": {...}
6574
- * @since Chrome 9
6595
+ *
6596
+ * Manifest: "omnibox"
6575
6597
  */
6576
6598
  export namespace omnibox {
6577
6599
  /** A suggest result. */
@@ -6634,9 +6656,11 @@ declare namespace chrome {
6634
6656
  // Page Action
6635
6657
  ////////////////////
6636
6658
  /**
6637
- * Use the chrome.pageAction API to put icons inside the address bar. Page actions represent actions that can be taken on the current page, but that aren't applicable to all pages.
6638
- * Manifest: "page_action": {...}
6639
- * @since Chrome 5
6659
+ * Use the `chrome.pageAction` API to put icons in the main Google Chrome toolbar, to the right of the address bar. Page actions represent actions that can be taken on the current page, but that aren't applicable to all pages. Page actions appear grayed out when inactive.
6660
+ *
6661
+ * Manifest: "page_action"
6662
+ *
6663
+ * MV2 only
6640
6664
  */
6641
6665
  export namespace pageAction {
6642
6666
  export interface PageActionClickedEvent extends chrome.events.Event<(tab: chrome.tabs.Tab) => void> {}
@@ -6725,9 +6749,9 @@ declare namespace chrome {
6725
6749
  // Page Capture
6726
6750
  ////////////////////
6727
6751
  /**
6728
- * Use the chrome.pageCapture API to save a tab as MHTML.
6729
- * Permissions: "pageCapture"
6730
- * @since Chrome 18
6752
+ * Use the `chrome.pageCapture` API to save a tab as MHTML.
6753
+ *
6754
+ * Permissions: "pageCapture"
6731
6755
  */
6732
6756
  export namespace pageCapture {
6733
6757
  export interface SaveDetails {
@@ -6752,8 +6776,7 @@ declare namespace chrome {
6752
6776
  // Permissions
6753
6777
  ////////////////////
6754
6778
  /**
6755
- * Use the chrome.permissions API to request declared optional permissions at run time rather than install time, so users understand why the permissions are needed and grant only those that are necessary.
6756
- * @since Chrome 16
6779
+ * Use the `chrome.permissions` API to request declared optional permissions at run time rather than install time, so users understand why the permissions are needed and grant only those that are necessary.
6757
6780
  */
6758
6781
  export namespace permissions {
6759
6782
  export interface Permissions {
@@ -6806,9 +6829,10 @@ declare namespace chrome {
6806
6829
  // Platform Keys
6807
6830
  ////////////////////
6808
6831
  /**
6809
- * Use the chrome.platformKeys API to access client certificates managed by the platform. If the user or policy grants the permission, an extension can use such a certficate in its custom authentication protocol. E.g. this allows usage of platform managed certificates in third party VPNs (see chrome.vpnProvider).
6810
- * Permissions: "platformKeys"
6811
- * Important: This API works only on Chrome OS.
6832
+ * Use the `chrome.platformKeys` API to access client certificates managed by the platform. If the user or policy grants the permission, an extension can use such a certficate in its custom authentication protocol. E.g. this allows usage of platform managed certificates in third party VPNs (see chrome.vpnProvider).
6833
+ *
6834
+ * Permissions: "platformKeys"
6835
+ * @platform ChromeOS only
6812
6836
  * @since Chrome 45
6813
6837
  */
6814
6838
  export namespace platformKeys {
@@ -6904,9 +6928,9 @@ declare namespace chrome {
6904
6928
  // Power
6905
6929
  ////////////////////
6906
6930
  /**
6907
- * Use the chrome.power API to override the system's power management features.
6931
+ * Use the `chrome.power` API to override the system's power management features.
6932
+ *
6908
6933
  * Permissions: "power"
6909
- * @since Chrome 27
6910
6934
  */
6911
6935
  export namespace power {
6912
6936
  export enum Level {
@@ -6936,8 +6960,9 @@ declare namespace chrome {
6936
6960
  // Printer Provider
6937
6961
  ////////////////////
6938
6962
  /**
6939
- * The chrome.printerProvider API exposes events used by print manager to query printers controlled by extensions, to query their capabilities and to submit print jobs to these printers.
6940
- * Permissions: "printerProvider"
6963
+ * The `chrome.printerProvider` API exposes events used by print manager to query printers controlled by extensions, to query their capabilities and to submit print jobs to these printers.
6964
+ *
6965
+ * Permissions: "printerProvider"
6941
6966
  * @since Chrome 44
6942
6967
  */
6943
6968
  export namespace printerProvider {
@@ -7004,12 +7029,12 @@ declare namespace chrome {
7004
7029
  // Printing
7005
7030
  ////////////////////
7006
7031
  /**
7007
- * Use the chrome.printing API to send print jobs to printers installed on Chromebook.
7032
+ * Use the `chrome.printing` API to send print jobs to printers installed on Chromebook.
7008
7033
 
7009
- * Permissions: "printing"
7010
- * @platform ChromeOS only
7011
- * @since Chrome 81
7012
- */
7034
+ * Permissions: "printing"
7035
+ * @platform ChromeOS only
7036
+ * @since Chrome 81
7037
+ */
7013
7038
  export namespace printing {
7014
7039
  export interface GetPrinterInfoResponse {
7015
7040
  /** Printer capabilities in [CDD format](https://developers.google.com/cloud-print/docs/cdd#cdd-example). The property may be missing. */
@@ -7157,11 +7182,11 @@ declare namespace chrome {
7157
7182
  // Printing Metrics
7158
7183
  ////////////////////
7159
7184
  /**
7160
- * Use the chrome.printingMetrics API to fetch data about printing usage.
7185
+ * Use the `chrome.printingMetrics` API to fetch data about printing usage.
7161
7186
  *
7162
7187
  * Permissions: "printingMetrics"
7163
7188
  *
7164
- * Note: This API is only for extensions pre-installed by policy.
7189
+ * Note: Only available to policy installed extensions.
7165
7190
  * @platform ChromeOS only
7166
7191
  * @since Chrome 79
7167
7192
  */
@@ -7287,10 +7312,10 @@ declare namespace chrome {
7287
7312
  // Privacy
7288
7313
  ////////////////////
7289
7314
  /**
7290
- * Use the chrome.privacy API to control usage of the features in Chrome that can affect a user's privacy. This API relies on the ChromeSetting prototype of the type API for getting and setting Chrome's configuration.
7291
- * Permissions: "privacy"
7292
- * The Chrome Privacy Whitepaper gives background detail regarding the features which this API can control.
7293
- * @since Chrome 18
7315
+ * Use the `chrome.privacy` API to control usage of the features in Chrome that can affect a user's privacy. This API relies on the ChromeSetting prototype of the type API for getting and setting Chrome's configuration.
7316
+ * Note: The Chrome Privacy Whitepaper gives background detail regarding the features which this API can control.
7317
+ *
7318
+ * Permissions: "privacy"
7294
7319
  */
7295
7320
  export namespace privacy {
7296
7321
  /**
@@ -7350,9 +7375,9 @@ declare namespace chrome {
7350
7375
  // Proxy
7351
7376
  ////////////////////
7352
7377
  /**
7353
- * Use the chrome.proxy API to manage Chrome's proxy settings. This API relies on the ChromeSetting prototype of the type API for getting and setting the proxy configuration.
7354
- * Permissions: "proxy"
7355
- * @since Chrome 13
7378
+ * Use the `chrome.proxy` API to manage Chrome's proxy settings. This API relies on the ChromeSetting prototype of the type API for getting and setting the proxy configuration.
7379
+ *
7380
+ * Permissions: "proxy"
7356
7381
  */
7357
7382
  export namespace proxy {
7358
7383
  /** An object holding proxy auto-config information. Exactly one of the fields should be non-empty. */
@@ -7427,10 +7452,11 @@ declare namespace chrome {
7427
7452
  // Search
7428
7453
  ////////////////////
7429
7454
  /**
7430
- * Use the chrome.search API to search via the default provider.
7431
- * Permissions: "search"
7455
+ * Use the `chrome.search` API to search via the default provider.
7456
+ *
7457
+ * Permissions: "search"
7458
+ * @since Chrome 87
7432
7459
  */
7433
-
7434
7460
  export namespace search {
7435
7461
  export type Disposition = "CURRENT_TAB" | "NEW_TAB" | "NEW_WINDOW";
7436
7462
 
@@ -7732,8 +7758,7 @@ declare namespace chrome {
7732
7758
  // Runtime
7733
7759
  ////////////////////
7734
7760
  /**
7735
- * Use the chrome.runtime API to retrieve the background page, return details about the manifest, and listen for and respond to events in the app or extension lifecycle. You can also use this API to convert the relative path of URLs to fully-qualified URLs.
7736
- * @since Chrome 22
7761
+ * Use the `chrome.runtime` API to retrieve the service worker, return details about the manifest, and listen for and respond to events in the extension lifecycle. You can also use this API to convert the relative path of URLs to fully-qualified URLs.
7737
7762
  */
7738
7763
  export namespace runtime {
7739
7764
  /** This will be defined during an API method callback if there was an error */
@@ -8608,7 +8633,8 @@ declare namespace chrome {
8608
8633
  // Scripting
8609
8634
  ////////////////////
8610
8635
  /**
8611
- * Use the chrome.scripting API to execute script in different contexts.
8636
+ * Use the `chrome.scripting` API to execute script in different contexts.
8637
+ *
8612
8638
  * Permissions: "scripting"
8613
8639
  * @since Chrome 88, MV3
8614
8640
  */
@@ -8860,9 +8886,9 @@ declare namespace chrome {
8860
8886
  // Sessions
8861
8887
  ////////////////////
8862
8888
  /**
8863
- * Use the chrome.sessions API to query and restore tabs and windows from a browsing session.
8864
- * Permissions: "sessions"
8865
- * @since Chrome 37
8889
+ * Use the `chrome.sessions` API to query and restore tabs and windows from a browsing session.
8890
+ *
8891
+ * Permissions: "sessions"
8866
8892
  */
8867
8893
  export namespace sessions {
8868
8894
  export interface Filter {
@@ -8964,9 +8990,9 @@ declare namespace chrome {
8964
8990
  // Storage
8965
8991
  ////////////////////
8966
8992
  /**
8967
- * Use the chrome.storage API to store, retrieve, and track changes to user data.
8968
- * Permissions: "storage"
8969
- * @since Chrome 20
8993
+ * Use the `chrome.storage` API to store, retrieve, and track changes to user data.
8994
+ *
8995
+ * Permissions: "storage"
8970
8996
  */
8971
8997
  export namespace storage {
8972
8998
  /** NoInfer for old TypeScript versions */
@@ -9275,9 +9301,9 @@ declare namespace chrome {
9275
9301
  // System CPU
9276
9302
  ////////////////////
9277
9303
  /**
9278
- * Use the system.cpu API to query CPU metadata.
9304
+ * Use the `system.cpu` API to query CPU metadata.
9305
+ *
9279
9306
  * Permissions: "system.cpu"
9280
- * @since Chrome 32
9281
9307
  */
9282
9308
  export namespace system.cpu {
9283
9309
  export interface ProcessorUsage {
@@ -9326,9 +9352,9 @@ declare namespace chrome {
9326
9352
  // System Memory
9327
9353
  ////////////////////
9328
9354
  /**
9329
- * The chrome.system.memory API.
9330
- * Permissions: "system.memory"
9331
- * @since Chrome 32
9355
+ * The `chrome.system.memory` API.
9356
+ *
9357
+ * Permissions: "system.memory"
9332
9358
  */
9333
9359
  export namespace system.memory {
9334
9360
  export interface MemoryInfo {
@@ -9352,9 +9378,9 @@ declare namespace chrome {
9352
9378
  // System Storage
9353
9379
  ////////////////////
9354
9380
  /**
9355
- * Use the chrome.system.storage API to query storage device information and be notified when a removable storage device is attached and detached.
9356
- * Permissions: "system.storage"
9357
- * @since Chrome 30
9381
+ * Use the `chrome.system.storage` API to query storage device information and be notified when a removable storage device is attached and detached.
9382
+ *
9383
+ * Permissions: "system.storage"
9358
9384
  */
9359
9385
  export namespace system.storage {
9360
9386
  export interface StorageUnitInfo {
@@ -9426,9 +9452,9 @@ declare namespace chrome {
9426
9452
  // System Display //
9427
9453
  ////////////////////
9428
9454
  /**
9429
- * Use the system.display API to query display metadata.
9455
+ * Use the `system.display` API to query display metadata.
9456
+ *
9430
9457
  * Permissions: "system.display"
9431
- * @since Chrome 30
9432
9458
  */
9433
9459
  export namespace system.display {
9434
9460
  export enum LayoutPosition {
@@ -9904,11 +9930,11 @@ declare namespace chrome {
9904
9930
  // SystemLog
9905
9931
  ////////////////////
9906
9932
  /**
9907
- * Use the chrome.systemLog API to record Chrome system logs from extensions.
9933
+ * Use the `chrome.systemLog` API to record Chrome system logs from extensions.
9908
9934
  *
9909
9935
  * Permissions: "systemLog"
9910
9936
  *
9911
- * Note: This API is only for extensions pre-installed by policy.
9937
+ * Note: Only available to policy installed extensions.
9912
9938
  * @platform ChromeOS only
9913
9939
  * @since Chrome 125
9914
9940
  */
@@ -9929,9 +9955,9 @@ declare namespace chrome {
9929
9955
  // TabCapture
9930
9956
  ////////////////////
9931
9957
  /**
9932
- * Use the chrome.tabCapture API to interact with tab media streams.
9933
- * Permissions: "tabCapture"
9934
- * @since Chrome 31
9958
+ * Use the `chrome.tabCapture` API to interact with tab media streams.
9959
+ *
9960
+ * Permissions: "tabCapture"
9935
9961
  */
9936
9962
  export namespace tabCapture {
9937
9963
  export interface CaptureInfo {
@@ -9998,9 +10024,9 @@ declare namespace chrome {
9998
10024
  // Tabs
9999
10025
  ////////////////////
10000
10026
  /**
10001
- * Use the chrome.tabs API to interact with the browser's tab system. You can use this API to create, modify, and rearrange tabs in the browser.
10027
+ * Use the `chrome.tabs` API to interact with the browser's tab system. You can use this API to create, modify, and rearrange tabs in the browser.
10028
+ *
10002
10029
  * Permissions: The majority of the chrome.tabs API can be used without declaring any permission. However, the "tabs" permission is required in order to populate the url, title, and favIconUrl properties of Tab.
10003
- * @since Chrome 5
10004
10030
  */
10005
10031
  export namespace tabs {
10006
10032
  /**
@@ -10132,7 +10158,7 @@ declare namespace chrome {
10132
10158
  */
10133
10159
  groupId: number;
10134
10160
  /**
10135
- * The last time the tab was accessed as the number of milliseconds since epoch.
10161
+ * The last time the tab became active in its window as the number of milliseconds since epoch.
10136
10162
  * @since Chrome 121
10137
10163
  */
10138
10164
  lastAccessed?: number | undefined;
@@ -11232,8 +11258,9 @@ declare namespace chrome {
11232
11258
  // Tab Groups
11233
11259
  ////////////////////
11234
11260
  /**
11235
- * Use the chrome.tabGroups API to interact with the browser's tab grouping system. You can use this API to modify and rearrange tab groups in the browser. To group and ungroup tabs, or to query what tabs are in groups, use the chrome.tabs API.
11236
- * Permissions: "tabGroups"
11261
+ * Use the `chrome.tabGroups` API to interact with the browser's tab grouping system. You can use this API to modify and rearrange tab groups in the browser. To group and ungroup tabs, or to query what tabs are in groups, use the `chrome.tabs` API.
11262
+ *
11263
+ * Permissions: "tabGroups"
11237
11264
  * @since Chrome 89, MV3
11238
11265
  */
11239
11266
  export namespace tabGroups {
@@ -11369,9 +11396,9 @@ declare namespace chrome {
11369
11396
  // Top Sites
11370
11397
  ////////////////////
11371
11398
  /**
11372
- * Use the chrome.topSites API to access the top sites that are displayed on the new tab page.
11373
- * Permissions: "topSites"
11374
- * @since Chrome 19
11399
+ * Use the `chrome.topSites` API to access the top sites (i.e. most visited sites) that are displayed on the new tab page. These do not include shortcuts customized by the user.
11400
+ *
11401
+ * Permissions: "topSites"
11375
11402
  */
11376
11403
  export namespace topSites {
11377
11404
  /** An object encapsulating a most visited URL, such as the URLs on the new tab page. */
@@ -11396,9 +11423,9 @@ declare namespace chrome {
11396
11423
  // Text to Speech
11397
11424
  ////////////////////
11398
11425
  /**
11399
- * Use the chrome.tts API to play synthesized text-to-speech (TTS). See also the related ttsEngine API, which allows an extension to implement a speech engine.
11400
- * Permissions: "tts"
11401
- * @since Chrome 14
11426
+ * Use the `chrome.tts` API to play synthesized text-to-speech (TTS). See also the related ttsEngine API, which allows an extension to implement a speech engine.
11427
+ *
11428
+ * Permissions: "tts"
11402
11429
  */
11403
11430
  export namespace tts {
11404
11431
  /** An event from the TTS engine to communicate the status of an utterance. */
@@ -11529,9 +11556,9 @@ declare namespace chrome {
11529
11556
  // Text to Speech Engine
11530
11557
  ////////////////////
11531
11558
  /**
11532
- * Use the chrome.ttsEngine API to implement a text-to-speech(TTS) engine using an extension. If your extension registers using this API, it will receive events containing an utterance to be spoken and other parameters when any extension or Chrome App uses the tts API to generate speech. Your extension can then use any available web technology to synthesize and output the speech, and send events back to the calling function to report the status.
11533
- * Permissions: "ttsEngine"
11534
- * @since Chrome 14
11559
+ * Use the `chrome.ttsEngine` API to implement a text-to-speech(TTS) engine using an extension. If your extension registers using this API, it will receive events containing an utterance to be spoken and other parameters when any extension or Chrome App uses the {@link tts} API to generate speech. Your extension can then use any available web technology to synthesize and output the speech, and send events back to the calling function to report the status.
11560
+ *
11561
+ * Permissions: "ttsEngine"
11535
11562
  */
11536
11563
  export namespace ttsEngine {
11537
11564
  export interface SpeakOptions {
@@ -11581,8 +11608,7 @@ declare namespace chrome {
11581
11608
  // Types
11582
11609
  ////////////////////
11583
11610
  /**
11584
- * The chrome.types API contains type declarations for Chrome.
11585
- * @since Chrome 13
11611
+ * The `chrome.types` API contains type declarations for Chrome.
11586
11612
  */
11587
11613
  export namespace types {
11588
11614
  /**
@@ -11693,9 +11719,10 @@ declare namespace chrome {
11693
11719
  // VPN Provider
11694
11720
  ////////////////////
11695
11721
  /**
11696
- * Use the chrome.vpnProvider API to implement a VPN client.
11697
- * Permissions: "vpnProvider"
11698
- * Important: This API works only on Chrome OS.
11722
+ * Use the `chrome.vpnProvider` API to implement a VPN client.
11723
+ *
11724
+ * Permissions: "vpnProvider"
11725
+ * @platform ChromeOS only
11699
11726
  * @since Chrome 43
11700
11727
  */
11701
11728
  export namespace vpnProvider {
@@ -11784,9 +11811,10 @@ declare namespace chrome {
11784
11811
  // Wallpaper
11785
11812
  ////////////////////
11786
11813
  /**
11787
- * Use the chrome.wallpaper API to change the ChromeOS wallpaper.
11788
- * Permissions: "wallpaper"
11789
- * Important: This API works only on Chrome OS.
11814
+ * Use the `chrome.wallpaper` API to change the ChromeOS wallpaper.
11815
+ *
11816
+ * Permissions: "wallpaper"
11817
+ * @platform ChromeOS only
11790
11818
  * @since Chrome 43
11791
11819
  */
11792
11820
  export namespace wallpaper {
@@ -11818,9 +11846,9 @@ declare namespace chrome {
11818
11846
  // Web Navigation
11819
11847
  ////////////////////
11820
11848
  /**
11821
- * Use the chrome.webNavigation API to receive notifications about the status of navigation requests in-flight.
11822
- * Permissions: "webNavigation"
11823
- * @since Chrome 16
11849
+ * Use the `chrome.webNavigation` API to receive notifications about the status of navigation requests in-flight.
11850
+ *
11851
+ * Permissions: "webNavigation"
11824
11852
  */
11825
11853
  export namespace webNavigation {
11826
11854
  export interface GetFrameDetails {
@@ -12031,11 +12059,19 @@ declare namespace chrome {
12031
12059
  // Web Request
12032
12060
  ////////////////////
12033
12061
  /**
12034
- * Use the chrome.webRequest API to observe and analyze traffic and to intercept, block, or modify requests in-flight.
12035
- * Permissions: "webRequest", host permissions
12036
- * @since Chrome 17
12062
+ * Use the `chrome.webRequest` API to observe and analyze traffic and to intercept, block, or modify requests in-flight.
12063
+ *
12064
+ * Permissions: "webRequest"
12065
+ *
12066
+ * Manifest: "host_permissions"
12037
12067
  */
12038
12068
  export namespace webRequest {
12069
+ interface WebRequestEvent<T extends Function, U extends string[]>
12070
+ extends Omit<chrome.events.Event<T>, "addListener">
12071
+ {
12072
+ addListener(callback: T, filter: RequestFilter, extraInfoSpec?: U): void;
12073
+ }
12074
+
12039
12075
  /** How the requested resource will be used. */
12040
12076
  export type ResourceType =
12041
12077
  | "main_frame"
@@ -12234,82 +12270,45 @@ declare namespace chrome {
12234
12270
  error: string;
12235
12271
  }
12236
12272
 
12237
- export interface WebRequestBodyEvent extends
12238
- chrome.events.EventWithRequiredFilterInAddListener<
12239
- // eslint-disable-next-line @typescript-eslint/no-invalid-void-type
12240
- (details: WebRequestBodyDetails) => BlockingResponse | void
12241
- >
12242
- {
12243
- addListener(
12244
- // eslint-disable-next-line @typescript-eslint/no-invalid-void-type
12245
- callback: (details: WebRequestBodyDetails) => BlockingResponse | void,
12246
- filter: RequestFilter,
12247
- opt_extraInfoSpec?: string[],
12248
- ): void;
12249
- }
12273
+ export type WebRequestBodyEvent = WebRequestEvent<
12274
+ // eslint-disable-next-line @typescript-eslint/no-invalid-void-type
12275
+ (details: WebRequestBodyDetails) => BlockingResponse | void,
12276
+ string[]
12277
+ >;
12250
12278
 
12251
- export interface WebRequestHeadersSynchronousEvent extends
12252
- chrome.events.EventWithRequiredFilterInAddListener<
12253
- // eslint-disable-next-line @typescript-eslint/no-invalid-void-type
12254
- (details: WebRequestHeadersDetails) => BlockingResponse | void
12255
- >
12256
- {
12257
- addListener(
12258
- // eslint-disable-next-line @typescript-eslint/no-invalid-void-type
12259
- callback: (details: WebRequestHeadersDetails) => BlockingResponse | void,
12260
- filter: RequestFilter,
12261
- opt_extraInfoSpec?: string[],
12262
- ): void;
12263
- }
12279
+ export type WebRequestHeadersSynchronousEvent = WebRequestEvent<
12280
+ // eslint-disable-next-line @typescript-eslint/no-invalid-void-type
12281
+ (details: WebRequestHeadersDetails) => BlockingResponse | void,
12282
+ string[]
12283
+ >;
12264
12284
 
12265
- export interface WebRequestHeadersEvent
12266
- extends chrome.events.EventWithRequiredFilterInAddListener<(details: WebRequestHeadersDetails) => void>
12267
- {
12268
- addListener(
12269
- callback: (details: WebRequestHeadersDetails) => void,
12270
- filter: RequestFilter,
12271
- opt_extraInfoSpec?: string[],
12272
- ): void;
12273
- }
12285
+ export type WebRequestHeadersEvent = WebRequestEvent<
12286
+ (details: WebRequestHeadersDetails) => void,
12287
+ string[]
12288
+ >;
12274
12289
 
12275
- export interface _WebResponseHeadersEvent<T extends WebResponseHeadersDetails>
12276
- extends chrome.events.EventWithRequiredFilterInAddListener<(details: T) => void>
12277
- {
12278
- addListener(callback: (details: T) => void, filter: RequestFilter, opt_extraInfoSpec?: string[]): void;
12279
- }
12290
+ export type _WebResponseHeadersEvent<T extends WebResponseHeadersDetails> = WebRequestEvent<
12291
+ (details: T) => void,
12292
+ string[]
12293
+ >;
12280
12294
 
12281
- export interface WebResponseHeadersEvent extends
12282
- chrome.events.EventWithRequiredFilterInAddListener<
12283
- // eslint-disable-next-line @typescript-eslint/no-invalid-void-type
12284
- (details: WebResponseHeadersDetails) => BlockingResponse | void
12285
- >
12286
- {
12287
- addListener(
12288
- // eslint-disable-next-line @typescript-eslint/no-invalid-void-type
12289
- callback: (details: WebResponseHeadersDetails) => BlockingResponse | void,
12290
- filter: RequestFilter,
12291
- opt_extraInfoSpec?: string[],
12292
- ): void;
12293
- }
12295
+ export type WebResponseHeadersEvent = WebRequestEvent<
12296
+ // eslint-disable-next-line @typescript-eslint/no-invalid-void-type
12297
+ (details: WebResponseHeadersDetails) => BlockingResponse | void,
12298
+ string[]
12299
+ >;
12294
12300
 
12295
- export interface WebResponseCacheEvent extends _WebResponseHeadersEvent<WebResponseCacheDetails> {}
12301
+ export type WebResponseCacheEvent = _WebResponseHeadersEvent<WebResponseCacheDetails>;
12296
12302
 
12297
- export interface WebRedirectionResponseEvent extends _WebResponseHeadersEvent<WebRedirectionResponseDetails> {}
12303
+ export type WebRedirectionResponseEvent = _WebResponseHeadersEvent<WebRedirectionResponseDetails>;
12298
12304
 
12299
- export interface WebAuthenticationChallengeEvent extends
12300
- chrome.events.EventWithRequiredFilterInAddListener<
12301
- (details: WebAuthenticationChallengeDetails, callback?: (response: BlockingResponse) => void) => void
12302
- >
12303
- {
12304
- addListener(
12305
- callback: (
12306
- details: WebAuthenticationChallengeDetails,
12307
- callback?: (response: BlockingResponse) => void,
12308
- ) => void,
12309
- filter: RequestFilter,
12310
- opt_extraInfoSpec?: string[],
12311
- ): void;
12312
- }
12305
+ export type WebAuthenticationChallengeEvent = WebRequestEvent<
12306
+ (
12307
+ details: WebAuthenticationChallengeDetails,
12308
+ callback?: (response: BlockingResponse) => void,
12309
+ ) => void,
12310
+ string[]
12311
+ >;
12313
12312
 
12314
12313
  export interface WebResponseErrorEvent extends _WebResponseHeadersEvent<WebResponseErrorDetails> {}
12315
12314
 
@@ -12319,17 +12318,25 @@ declare namespace chrome {
12319
12318
  */
12320
12319
  export var MAX_HANDLER_BEHAVIOR_CHANGED_CALLS_PER_10_MINUTES: number;
12321
12320
 
12322
- /** Needs to be called when the behavior of the webRequest handlers has changed to prevent incorrect handling due to caching. This function call is expensive. Don't call it often. */
12323
- export function handlerBehaviorChanged(callback?: Function): void;
12321
+ /**
12322
+ * Needs to be called when the behavior of the webRequest handlers has changed to prevent incorrect handling due to caching. This function call is expensive. Don't call it often.
12323
+ * Can return its result via Promise in Manifest V3 or later since Chrome 116.
12324
+ */
12325
+ export function handlerBehaviorChanged(): Promise<void>;
12326
+ export function handlerBehaviorChanged(callback: Function): void;
12324
12327
 
12325
12328
  /** Fired when a request is about to occur. */
12326
- export var onBeforeRequest: WebRequestBodyEvent;
12329
+ export const onBeforeRequest: WebRequestBodyEvent;
12330
+
12327
12331
  /** Fired before sending an HTTP request, once the request headers are available. This may occur after a TCP connection is made to the server, but before any HTTP data is sent. */
12328
- export var onBeforeSendHeaders: WebRequestHeadersSynchronousEvent;
12332
+ export const onBeforeSendHeaders: WebRequestHeadersSynchronousEvent;
12333
+
12329
12334
  /** Fired just before a request is going to be sent to the server (modifications of previous onBeforeSendHeaders callbacks are visible by the time onSendHeaders is fired). */
12330
- export var onSendHeaders: WebRequestHeadersEvent;
12335
+ export const onSendHeaders: WebRequestHeadersEvent;
12336
+
12331
12337
  /** Fired when HTTP response headers of a request have been received. */
12332
- export var onHeadersReceived: WebResponseHeadersEvent;
12338
+ export const onHeadersReceived: WebResponseHeadersEvent;
12339
+
12333
12340
  /**
12334
12341
  * Fired when an authentication failure is received.
12335
12342
  * The listener has three options: it can provide authentication credentials, it can cancel the request and display the error page, or it can take no action on the challenge.
@@ -12338,15 +12345,19 @@ declare namespace chrome {
12338
12345
  *
12339
12346
  * Requires the `webRequestAuthProvider` permission.
12340
12347
  */
12341
- export var onAuthRequired: WebAuthenticationChallengeEvent;
12348
+ export const onAuthRequired: WebAuthenticationChallengeEvent;
12349
+
12342
12350
  /** Fired when the first byte of the response body is received. For HTTP requests, this means that the status line and response headers are available. */
12343
- export var onResponseStarted: WebResponseCacheEvent;
12351
+ export const onResponseStarted: WebResponseCacheEvent;
12352
+
12344
12353
  /** Fired when a server-initiated redirect is about to occur. */
12345
- export var onBeforeRedirect: WebRedirectionResponseEvent;
12354
+ export const onBeforeRedirect: WebRedirectionResponseEvent;
12355
+
12346
12356
  /** Fired when a request is completed. */
12347
- export var onCompleted: WebResponseCacheEvent;
12357
+ export const onCompleted: WebResponseCacheEvent;
12358
+
12348
12359
  /** Fired when an error occurs. */
12349
- export var onErrorOccurred: WebResponseErrorEvent;
12360
+ export const onErrorOccurred: WebResponseErrorEvent;
12350
12361
  }
12351
12362
 
12352
12363
  ////////////////////
@@ -12460,9 +12471,9 @@ declare namespace chrome {
12460
12471
  // Windows
12461
12472
  ////////////////////
12462
12473
  /**
12463
- * Use the chrome.windows API to interact with browser windows. You can use this API to create, modify, and rearrange windows in the browser.
12474
+ * Use the `chrome.windows` API to interact with browser windows. You can use this API to create, modify, and rearrange windows in the browser.
12475
+ *
12464
12476
  * Permissions: The chrome.windows API can be used without declaring any permission. However, the "tabs" permission is required in order to populate the url, title, and favIconUrl properties of Tab objects.
12465
- * @since Chrome 5
12466
12477
  */
12467
12478
  export namespace windows {
12468
12479
  export interface Window {
@@ -12795,6 +12806,17 @@ declare namespace chrome {
12795
12806
  export var onBoundsChanged: WindowReferenceEvent;
12796
12807
  }
12797
12808
 
12809
+ ////////////////////
12810
+ // declarativeNetRequest
12811
+ ////////////////////
12812
+ /**
12813
+ * The `chrome.declarativeNetRequest` API is used to block or modify network requests by specifying declarative rules. This lets extensions modify network requests without intercepting them and viewing their content, thus providing more privacy.
12814
+ *
12815
+ * Permissions: "declarativeNetRequest", "declarativeNetRequestWithHostAccess", "declarativeNetRequestFeedback"
12816
+ *
12817
+ * Manifest: "host_permissions"
12818
+ * @since Chrome 84
12819
+ */
12798
12820
  export namespace declarativeNetRequest {
12799
12821
  /** Ruleset ID for the dynamic rules added by the extension. */
12800
12822
  export const DYNAMIC_RULESET_ID: "_dynamic";
@@ -13623,9 +13645,10 @@ declare namespace chrome {
13623
13645
  // SidePanel
13624
13646
  ////////////////////
13625
13647
  /**
13626
- * @since Chrome 114, MV3
13627
- * https://developer.chrome.com/docs/extensions/reference/api/sidePanel
13648
+ * Use the `chrome.sidePanel` API to host content in the browser's side panel alongside the main content of a webpage.
13649
+ *
13628
13650
  * Permissions: "sidePanel"
13651
+ * @since Chrome 114, MV3
13629
13652
  */
13630
13653
  export namespace sidePanel {
13631
13654
  export interface GetPanelOptions {
@@ -13766,15 +13789,15 @@ declare namespace chrome {
13766
13789
  ): Promise<void>;
13767
13790
  }
13768
13791
 
13769
- // Type definitions for chrome.userScripts API
13770
-
13792
+ ////////////////////
13793
+ // User Scripts
13794
+ ////////////////////
13771
13795
  /**
13772
- * Availability: Chrome 120 beta. Manifest v3.
13773
- * https://developer.chrome.com/docs/extensions/reference/api/userScripts
13796
+ * Use the `userScripts` API to execute user scripts in the User Scripts context.
13797
+ *
13774
13798
  * Permissions: "userScripts"
13775
- * Description: "A user script is a bit of code injected into a web page to modify its appearance or behavior. Scripts are either created by users or downloaded from a script repository or a user script extension.""
13799
+ * @since Chrome 120, MV3
13776
13800
  */
13777
-
13778
13801
  export namespace userScripts {
13779
13802
  /**
13780
13803
  * Execution environment for a user script.
chrome/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@types/chrome",
3
- "version": "0.0.292",
3
+ "version": "0.0.294",
4
4
  "description": "TypeScript definitions for chrome",
5
5
  "homepage": "https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/chrome",
6
6
  "license": "MIT",
@@ -94,6 +94,6 @@
94
94
  "@types/har-format": "*"
95
95
  },
96
96
  "peerDependencies": {},
97
- "typesPublisherContentHash": "c9e6e484c7b9d829b6fb4d49fb96f93c498543d00292b15cc9072e938ee5b698",
97
+ "typesPublisherContentHash": "ee5173779b32ec36ced6918cfdf3e272c65479c5642f0cfcc39c0a9ac51cdbad",
98
98
  "typeScriptVersion": "5.0"
99
99
  }