playwright-core 1.58.0-alpha-2025-12-15 → 1.58.0-alpha-2025-12-17

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.
@@ -1,7 +1,7 @@
1
1
  // This is generated from /utils/protocol-types-generator/index.js
2
2
  type binary = string;
3
- export module Protocol {
4
- export module Accessibility {
3
+ export namespace Protocol {
4
+ export namespace Accessibility {
5
5
  /**
6
6
  * Unique accessibility node identifier.
7
7
  */
@@ -341,7 +341,7 @@ including nodes that are ignored for accessibility.
341
341
  }
342
342
  }
343
343
 
344
- export module Animation {
344
+ export namespace Animation {
345
345
  /**
346
346
  * Animation instance.
347
347
  */
@@ -667,7 +667,7 @@ percentage [0 - 100] for scroll driven animations
667
667
  /**
668
668
  * Audits domain allows investigation of page violations and possible improvements.
669
669
  */
670
- export module Audits {
670
+ export namespace Audits {
671
671
  /**
672
672
  * Information about a cookie that is affected by an inspector issue.
673
673
  */
@@ -1242,7 +1242,7 @@ using Audits.issueAdded event.
1242
1242
  /**
1243
1243
  * Defines commands and events for Autofill.
1244
1244
  */
1245
- export module Autofill {
1245
+ export namespace Autofill {
1246
1246
  export interface CreditCard {
1247
1247
  /**
1248
1248
  * 16-digit credit card number.
@@ -1409,7 +1409,7 @@ If the field and related form cannot be autofilled, returns an error.
1409
1409
  /**
1410
1410
  * Defines events for background web platform features.
1411
1411
  */
1412
- export module BackgroundService {
1412
+ export namespace BackgroundService {
1413
1413
  /**
1414
1414
  * The Background Service that will be associated with the commands/events.
1415
1415
  Every Background Service operates independently, but they share the same
@@ -1512,7 +1512,7 @@ events afterwards if enabled and recording.
1512
1512
  * This domain allows configuring virtual Bluetooth devices to test
1513
1513
  the web-bluetooth API.
1514
1514
  */
1515
- export module BluetoothEmulation {
1515
+ export namespace BluetoothEmulation {
1516
1516
  /**
1517
1517
  * Indicates the various states of Central.
1518
1518
  */
@@ -1797,7 +1797,7 @@ by |characteristicId|.
1797
1797
  /**
1798
1798
  * The Browser domain defines methods and events for browser managing.
1799
1799
  */
1800
- export module Browser {
1800
+ export namespace Browser {
1801
1801
  export type BrowserContextID = string;
1802
1802
  export type WindowID = number;
1803
1803
  /**
@@ -2284,7 +2284,7 @@ CSS objects can be loaded using the `get*ForNode()` calls (which accept a DOM no
2284
2284
  can also keep track of stylesheets via the `styleSheetAdded`/`styleSheetRemoved` events and
2285
2285
  subsequently load the required stylesheet contents using the `getStyleSheet[Text]()` methods.
2286
2286
  */
2287
- export module CSS {
2287
+ export namespace CSS {
2288
2288
  /**
2289
2289
  * Stylesheet type: "injected" for stylesheets injected via extension, "user-agent" for user-agent
2290
2290
  stylesheets, "inspector" for stylesheets created by the inspector (i.e. those holding the "via
@@ -3870,7 +3870,7 @@ instrumentation).
3870
3870
  }
3871
3871
  }
3872
3872
 
3873
- export module CacheStorage {
3873
+ export namespace CacheStorage {
3874
3874
  /**
3875
3875
  * Unique identifier of the Cache object.
3876
3876
  */
@@ -4067,7 +4067,7 @@ is the count of all entries from this storage.
4067
4067
  * A domain for interacting with Cast, Presentation API, and Remote Playback API
4068
4068
  functionalities.
4069
4069
  */
4070
- export module Cast {
4070
+ export namespace Cast {
4071
4071
  export interface Sink {
4072
4072
  name: string;
4073
4073
  id: string;
@@ -4156,7 +4156,7 @@ and never sends the same node twice. It is client's responsibility to collect in
4156
4156
  the nodes that were sent to the client. Note that `iframe` owner elements will return
4157
4157
  corresponding document elements as their child nodes.
4158
4158
  */
4159
- export module DOM {
4159
+ export namespace DOM {
4160
4160
  /**
4161
4161
  * Unique DOM node identifier.
4162
4162
  */
@@ -5619,7 +5619,7 @@ popover if it was previously force-opened.
5619
5619
  * DOM debugging allows setting breakpoints on particular DOM operations and events. JavaScript
5620
5620
  execution will stop on these operations as if there was a regular breakpoint set.
5621
5621
  */
5622
- export module DOMDebugger {
5622
+ export namespace DOMDebugger {
5623
5623
  /**
5624
5624
  * DOM breakpoint type.
5625
5625
  */
@@ -5821,7 +5821,7 @@ EventTarget.
5821
5821
  /**
5822
5822
  * This domain facilitates obtaining document snapshots with DOM, layout, and style information.
5823
5823
  */
5824
- export module DOMSnapshot {
5824
+ export namespace DOMSnapshot {
5825
5825
  /**
5826
5826
  * A Node in the DOM tree.
5827
5827
  */
@@ -6359,7 +6359,7 @@ The final text color opacity is computed based on the opacity of all overlapping
6359
6359
  /**
6360
6360
  * Query and modify DOM storage.
6361
6361
  */
6362
- export module DOMStorage {
6362
+ export namespace DOMStorage {
6363
6363
  export type SerializedStorageKey = string;
6364
6364
  /**
6365
6365
  * DOM Storage identifier.
@@ -6442,7 +6442,7 @@ The final text color opacity is computed based on the opacity of all overlapping
6442
6442
  }
6443
6443
  }
6444
6444
 
6445
- export module DeviceAccess {
6445
+ export namespace DeviceAccess {
6446
6446
  /**
6447
6447
  * Device request id.
6448
6448
  */
@@ -6504,7 +6504,7 @@ selectPrompt or cancelPrompt command.
6504
6504
  }
6505
6505
  }
6506
6506
 
6507
- export module DeviceOrientation {
6507
+ export namespace DeviceOrientation {
6508
6508
 
6509
6509
 
6510
6510
  /**
@@ -6538,7 +6538,7 @@ selectPrompt or cancelPrompt command.
6538
6538
  /**
6539
6539
  * This domain emulates different environments for the page.
6540
6540
  */
6541
- export module Emulation {
6541
+ export namespace Emulation {
6542
6542
  export interface SafeAreaInsets {
6543
6543
  /**
6544
6544
  * Overrides safe-area-inset-top.
@@ -7435,7 +7435,7 @@ of size 100lvh.
7435
7435
  occurring in native code invoked from JavaScript. Once breakpoint is hit, it is
7436
7436
  reported through Debugger domain, similarly to regular breakpoints being hit.
7437
7437
  */
7438
- export module EventBreakpoints {
7438
+ export namespace EventBreakpoints {
7439
7439
 
7440
7440
 
7441
7441
  /**
@@ -7472,7 +7472,7 @@ reported through Debugger domain, similarly to regular breakpoints being hit.
7472
7472
  /**
7473
7473
  * Defines commands and events for browser extensions.
7474
7474
  */
7475
- export module Extensions {
7475
+ export namespace Extensions {
7476
7476
  /**
7477
7477
  * Storage areas.
7478
7478
  */
@@ -7591,7 +7591,7 @@ will be merged with existing values in the storage area.
7591
7591
  /**
7592
7592
  * This domain allows interacting with the FedCM dialog.
7593
7593
  */
7594
- export module FedCm {
7594
+ export namespace FedCm {
7595
7595
  /**
7596
7596
  * Whether this is a sign-up or sign-in action for this account, i.e.
7597
7597
  whether this account has ever been used to sign in to this RP before.
@@ -7699,7 +7699,7 @@ a dialog even if one was recently dismissed by the user.
7699
7699
  /**
7700
7700
  * A domain for letting clients substitute browser's network layer with client code.
7701
7701
  */
7702
- export module Fetch {
7702
+ export namespace Fetch {
7703
7703
  /**
7704
7704
  * Unique request identifier.
7705
7705
  Note that this does not identify individual HTTP requests that are part of
@@ -8070,7 +8070,7 @@ domain before body is received results in an undefined behavior.
8070
8070
  }
8071
8071
  }
8072
8072
 
8073
- export module FileSystem {
8073
+ export namespace FileSystem {
8074
8074
  export interface File {
8075
8075
  name: string;
8076
8076
  /**
@@ -8121,7 +8121,7 @@ domain before body is received results in an undefined behavior.
8121
8121
  /**
8122
8122
  * This domain provides experimental commands only supported in headless mode.
8123
8123
  */
8124
- export module HeadlessExperimental {
8124
+ export namespace HeadlessExperimental {
8125
8125
  /**
8126
8126
  * Encoding options for a screenshot.
8127
8127
  */
@@ -8201,7 +8201,7 @@ display. Reported for diagnostic uses, may be removed in the future.
8201
8201
  /**
8202
8202
  * Input/Output operations for streams produced by DevTools.
8203
8203
  */
8204
- export module IO {
8204
+ export namespace IO {
8205
8205
  /**
8206
8206
  * This is either obtained from another method or specified as `blob:<uuid>` where
8207
8207
  `<uuid>` is an UUID of a Blob.
@@ -8269,7 +8269,7 @@ following the last read). Some types of streams may only support sequential read
8269
8269
  }
8270
8270
  }
8271
8271
 
8272
- export module IndexedDB {
8272
+ export namespace IndexedDB {
8273
8273
  /**
8274
8274
  * Database with an array of object stores.
8275
8275
  */
@@ -8648,7 +8648,7 @@ Security origin.
8648
8648
  }
8649
8649
  }
8650
8650
 
8651
- export module Input {
8651
+ export namespace Input {
8652
8652
  export interface TouchPoint {
8653
8653
  /**
8654
8654
  * X coordinate of the event relative to the main frame's viewport in CSS pixels.
@@ -9171,7 +9171,7 @@ for the preferred input type).
9171
9171
  }
9172
9172
  }
9173
9173
 
9174
- export module Inspector {
9174
+ export namespace Inspector {
9175
9175
 
9176
9176
  /**
9177
9177
  * Fired when remote debugging connection is about to be terminated. Contains detach reason.
@@ -9211,7 +9211,7 @@ for the preferred input type).
9211
9211
  }
9212
9212
  }
9213
9213
 
9214
- export module LayerTree {
9214
+ export namespace LayerTree {
9215
9215
  /**
9216
9216
  * Unique Layer identifier.
9217
9217
  */
@@ -9508,7 +9508,7 @@ transform/scrolling purposes only.
9508
9508
  /**
9509
9509
  * Provides access to log entries.
9510
9510
  */
9511
- export module Log {
9511
+ export namespace Log {
9512
9512
  /**
9513
9513
  * Log entry.
9514
9514
  */
@@ -9624,7 +9624,7 @@ transform/scrolling purposes only.
9624
9624
  /**
9625
9625
  * This domain allows detailed inspection of media elements.
9626
9626
  */
9627
- export module Media {
9627
+ export namespace Media {
9628
9628
  /**
9629
9629
  * Players will get an ID that is unique within the agent context.
9630
9630
  */
@@ -9755,7 +9755,7 @@ event for each active player.
9755
9755
  }
9756
9756
  }
9757
9757
 
9758
- export module Memory {
9758
+ export namespace Memory {
9759
9759
  /**
9760
9760
  * Memory pressure level.
9761
9761
  */
@@ -9935,7 +9935,7 @@ collected since browser process startup.
9935
9935
  * Network domain allows tracking network activities of the page. It exposes information about http,
9936
9936
  file, data and other requests and responses, their headers, bodies, timing, etc.
9937
9937
  */
9938
- export module Network {
9938
+ export namespace Network {
9939
9939
  /**
9940
9940
  * Resource type as it was perceived by the rendering engine.
9941
9941
  */
@@ -12597,7 +12597,7 @@ Page reload is required before the new cookie behavior will be observed
12597
12597
  /**
12598
12598
  * This domain provides various functionality related to drawing atop the inspected page.
12599
12599
  */
12600
- export module Overlay {
12600
+ export namespace Overlay {
12601
12601
  /**
12602
12602
  * Configuration data for drawing the source order of an elements children.
12603
12603
  */
@@ -13423,7 +13423,7 @@ Backend then generates 'inspectNodeRequested' event upon element selection.
13423
13423
  /**
13424
13424
  * This domain allows interacting with the browser to control PWAs.
13425
13425
  */
13426
- export module PWA {
13426
+ export namespace PWA {
13427
13427
  /**
13428
13428
  * The following types are the replica of
13429
13429
  https://crsrc.org/c/chrome/browser/web_applications/proto/web_app_os_integration_state.proto;drc=9910d3be894c8f142c977ba1023f30a656bc13fc;l=67
@@ -13594,7 +13594,7 @@ supported yet.
13594
13594
  /**
13595
13595
  * Actions and events related to the inspected page belong to the page domain.
13596
13596
  */
13597
- export module Page {
13597
+ export namespace Page {
13598
13598
  /**
13599
13599
  * Unique frame identifier.
13600
13600
  */
@@ -15714,7 +15714,7 @@ components/optimization_guide/proto/features/common_quality_data.proto
15714
15714
  }
15715
15715
  }
15716
15716
 
15717
- export module Performance {
15717
+ export namespace Performance {
15718
15718
  /**
15719
15719
  * Run-time execution metric.
15720
15720
  */
@@ -15791,7 +15791,7 @@ this method while metrics collection is enabled returns an error.
15791
15791
  * Reporting of performance timeline events, as specified in
15792
15792
  https://w3c.github.io/performance-timeline/#dom-performanceobserver.
15793
15793
  */
15794
- export module PerformanceTimeline {
15794
+ export namespace PerformanceTimeline {
15795
15795
  /**
15796
15796
  * See https://github.com/WICG/LargestContentfulPaint and largest_contentful_paint.idl
15797
15797
  */
@@ -15880,7 +15880,7 @@ Note that not all types exposed to the web platform are currently supported.
15880
15880
  }
15881
15881
  }
15882
15882
 
15883
- export module Preload {
15883
+ export namespace Preload {
15884
15884
  /**
15885
15885
  * Unique id
15886
15886
  */
@@ -16072,7 +16072,7 @@ that is incompatible with prerender and has caused the cancellation of the attem
16072
16072
  }
16073
16073
  }
16074
16074
 
16075
- export module Security {
16075
+ export namespace Security {
16076
16076
  /**
16077
16077
  * An internal certificate ID value.
16078
16078
  */
@@ -16377,7 +16377,7 @@ be handled by the DevTools client and should be answered with `handleCertificate
16377
16377
  }
16378
16378
  }
16379
16379
 
16380
- export module ServiceWorker {
16380
+ export namespace ServiceWorker {
16381
16381
  export type RegistrationID = string;
16382
16382
  /**
16383
16383
  * ServiceWorker registration.
@@ -16499,7 +16499,7 @@ For cached script it is the last time the cache entry was validated.
16499
16499
  }
16500
16500
  }
16501
16501
 
16502
- export module Storage {
16502
+ export namespace Storage {
16503
16503
  export type SerializedStorageKey = string;
16504
16504
  /**
16505
16505
  * Enum of possible storage types.
@@ -17604,7 +17604,7 @@ party URL, only the first-party URL is returned in the array.
17604
17604
  /**
17605
17605
  * The SystemInfo domain defines methods and events for querying low-level system information.
17606
17606
  */
17607
- export module SystemInfo {
17607
+ export namespace SystemInfo {
17608
17608
  /**
17609
17609
  * Describes a single graphics processor (GPU).
17610
17610
  */
@@ -17802,7 +17802,7 @@ supported.
17802
17802
  /**
17803
17803
  * Supports additional targets discovery and allows to attach to them.
17804
17804
  */
17805
- export module Target {
17805
+ export namespace Target {
17806
17806
  export type TargetID = string;
17807
17807
  /**
17808
17808
  * Unique identifier of attached debugging session.
@@ -18317,7 +18317,7 @@ and performance.
18317
18317
  /**
18318
18318
  * The Tethering domain defines methods and events for browser port binding.
18319
18319
  */
18320
- export module Tethering {
18320
+ export namespace Tethering {
18321
18321
 
18322
18322
  /**
18323
18323
  * Informs that port was successfully bound and got a specified connection id.
@@ -18357,7 +18357,7 @@ and performance.
18357
18357
  }
18358
18358
  }
18359
18359
 
18360
- export module Tracing {
18360
+ export namespace Tracing {
18361
18361
  /**
18362
18362
  * Configuration for memory dump. Used only when "memory-infra" category is enabled.
18363
18363
  */
@@ -18575,7 +18575,7 @@ are ignored.
18575
18575
  * This domain allows inspection of Web Audio API.
18576
18576
  https://webaudio.github.io/web-audio-api/
18577
18577
  */
18578
- export module WebAudio {
18578
+ export namespace WebAudio {
18579
18579
  /**
18580
18580
  * An unique ID for a graph object (AudioContext, AudioNode, AudioParam) in Web Audio API
18581
18581
  */
@@ -18812,7 +18812,7 @@ capacity and glitch may occur.
18812
18812
  * This domain allows configuring virtual authenticators to test the WebAuthn
18813
18813
  API.
18814
18814
  */
18815
- export module WebAuthn {
18815
+ export namespace WebAuthn {
18816
18816
  export type AuthenticatorId = string;
18817
18817
  export type AuthenticatorProtocol = "u2f"|"ctap2";
18818
18818
  export type Ctap2Version = "ctap2_0"|"ctap2_1";
@@ -19109,7 +19109,7 @@ https://w3c.github.io/webauthn/#sctn-automation-set-credential-properties
19109
19109
  /**
19110
19110
  * This domain is deprecated - use Runtime or Log instead.
19111
19111
  */
19112
- export module Console {
19112
+ export namespace Console {
19113
19113
  /**
19114
19114
  * Console message.
19115
19115
  */
@@ -19178,7 +19178,7 @@ https://w3c.github.io/webauthn/#sctn-automation-set-credential-properties
19178
19178
  * Debugger domain exposes JavaScript debugging capabilities. It allows setting and removing
19179
19179
  breakpoints, stepping through execution, exploring stack traces, etc.
19180
19180
  */
19181
- export module Debugger {
19181
+ export namespace Debugger {
19182
19182
  /**
19183
19183
  * Breakpoint identifier.
19184
19184
  */
@@ -20205,7 +20205,7 @@ before next pause.
20205
20205
  }
20206
20206
  }
20207
20207
 
20208
- export module HeapProfiler {
20208
+ export namespace HeapProfiler {
20209
20209
  /**
20210
20210
  * Heap snapshot object id.
20211
20211
  */
@@ -20434,7 +20434,7 @@ Deprecated in favor of `exposeInternals`.
20434
20434
  }
20435
20435
  }
20436
20436
 
20437
- export module Profiler {
20437
+ export namespace Profiler {
20438
20438
  /**
20439
20439
  * Profile node. Holds callsite information, execution statistics and child nodes.
20440
20440
  */
@@ -20704,7 +20704,7 @@ and unique identifier that can be used for further object reference. Original ob
20704
20704
  maintained in memory unless they are either explicitly released or are released along with the
20705
20705
  other objects in their object group.
20706
20706
  */
20707
- export module Runtime {
20707
+ export namespace Runtime {
20708
20708
  /**
20709
20709
  * Unique script identifier.
20710
20710
  */
@@ -21763,7 +21763,7 @@ Error was thrown.
21763
21763
  /**
21764
21764
  * This domain is deprecated.
21765
21765
  */
21766
- export module Schema {
21766
+ export namespace Schema {
21767
21767
  /**
21768
21768
  * Description of the protocol domain.
21769
21769
  */
package/types/types.d.ts CHANGED
@@ -1036,6 +1036,21 @@ export interface Page {
1036
1036
  * @param options
1037
1037
  */
1038
1038
  extract<Schema extends ZodTypeAny>(query: string, schema: Schema): Promise<ZodInfer<Schema>>;
1039
+ /**
1040
+ * Emitted when the agent makes a turn.
1041
+ */
1042
+ on(event: 'agentturn', listener: (data: {
1043
+ role: string;
1044
+
1045
+ message: string;
1046
+
1047
+ usage?: {
1048
+ inputTokens: number;
1049
+
1050
+ outputTokens: number;
1051
+ };
1052
+ }) => any): this;
1053
+
1039
1054
  /**
1040
1055
  * Emitted when the page closes.
1041
1056
  */
@@ -1243,6 +1258,21 @@ export interface Page {
1243
1258
  */
1244
1259
  on(event: 'worker', listener: (worker: Worker) => any): this;
1245
1260
 
1261
+ /**
1262
+ * Adds an event listener that will be automatically removed after it is triggered once. See `addListener` for more information about this event.
1263
+ */
1264
+ once(event: 'agentturn', listener: (data: {
1265
+ role: string;
1266
+
1267
+ message: string;
1268
+
1269
+ usage?: {
1270
+ inputTokens: number;
1271
+
1272
+ outputTokens: number;
1273
+ };
1274
+ }) => any): this;
1275
+
1246
1276
  /**
1247
1277
  * Adds an event listener that will be automatically removed after it is triggered once. See `addListener` for more information about this event.
1248
1278
  */
@@ -1338,6 +1368,21 @@ export interface Page {
1338
1368
  */
1339
1369
  once(event: 'worker', listener: (worker: Worker) => any): this;
1340
1370
 
1371
+ /**
1372
+ * Emitted when the agent makes a turn.
1373
+ */
1374
+ addListener(event: 'agentturn', listener: (data: {
1375
+ role: string;
1376
+
1377
+ message: string;
1378
+
1379
+ usage?: {
1380
+ inputTokens: number;
1381
+
1382
+ outputTokens: number;
1383
+ };
1384
+ }) => any): this;
1385
+
1341
1386
  /**
1342
1387
  * Emitted when the page closes.
1343
1388
  */
@@ -1545,6 +1590,21 @@ export interface Page {
1545
1590
  */
1546
1591
  addListener(event: 'worker', listener: (worker: Worker) => any): this;
1547
1592
 
1593
+ /**
1594
+ * Removes an event listener added by `on` or `addListener`.
1595
+ */
1596
+ removeListener(event: 'agentturn', listener: (data: {
1597
+ role: string;
1598
+
1599
+ message: string;
1600
+
1601
+ usage?: {
1602
+ inputTokens: number;
1603
+
1604
+ outputTokens: number;
1605
+ };
1606
+ }) => any): this;
1607
+
1548
1608
  /**
1549
1609
  * Removes an event listener added by `on` or `addListener`.
1550
1610
  */
@@ -1640,6 +1700,21 @@ export interface Page {
1640
1700
  */
1641
1701
  removeListener(event: 'worker', listener: (worker: Worker) => any): this;
1642
1702
 
1703
+ /**
1704
+ * Removes an event listener added by `on` or `addListener`.
1705
+ */
1706
+ off(event: 'agentturn', listener: (data: {
1707
+ role: string;
1708
+
1709
+ message: string;
1710
+
1711
+ usage?: {
1712
+ inputTokens: number;
1713
+
1714
+ outputTokens: number;
1715
+ };
1716
+ }) => any): this;
1717
+
1643
1718
  /**
1644
1719
  * Removes an event listener added by `on` or `addListener`.
1645
1720
  */
@@ -1735,6 +1810,21 @@ export interface Page {
1735
1810
  */
1736
1811
  off(event: 'worker', listener: (worker: Worker) => any): this;
1737
1812
 
1813
+ /**
1814
+ * Emitted when the agent makes a turn.
1815
+ */
1816
+ prependListener(event: 'agentturn', listener: (data: {
1817
+ role: string;
1818
+
1819
+ message: string;
1820
+
1821
+ usage?: {
1822
+ inputTokens: number;
1823
+
1824
+ outputTokens: number;
1825
+ };
1826
+ }) => any): this;
1827
+
1738
1828
  /**
1739
1829
  * Emitted when the page closes.
1740
1830
  */
@@ -4790,6 +4880,41 @@ export interface Page {
4790
4880
  height: number;
4791
4881
  };
4792
4882
 
4883
+ /**
4884
+ * Emitted when the agent makes a turn.
4885
+ */
4886
+ waitForEvent(event: 'agentturn', optionsOrPredicate?: { predicate?: (data: {
4887
+ role: string;
4888
+
4889
+ message: string;
4890
+
4891
+ usage?: {
4892
+ inputTokens: number;
4893
+
4894
+ outputTokens: number;
4895
+ };
4896
+ }) => boolean | Promise<boolean>, timeout?: number } | ((data: {
4897
+ role: string;
4898
+
4899
+ message: string;
4900
+
4901
+ usage?: {
4902
+ inputTokens: number;
4903
+
4904
+ outputTokens: number;
4905
+ };
4906
+ }) => boolean | Promise<boolean>)): Promise<{
4907
+ role: string;
4908
+
4909
+ message: string;
4910
+
4911
+ usage?: {
4912
+ inputTokens: number;
4913
+
4914
+ outputTokens: number;
4915
+ };
4916
+ }>;
4917
+
4793
4918
  /**
4794
4919
  * Emitted when the page closes.
4795
4920
  */
@@ -22118,7 +22243,7 @@ export interface BrowserContextOptions {
22118
22243
  /**
22119
22244
  * Cache control, defaults to 'auto'.
22120
22245
  */
22121
- cacheMode?: 'force'|'ignore'|'auto';
22246
+ cacheMode?: "force"|"ignore"|"update"|"auto";
22122
22247
 
22123
22248
  /**
22124
22249
  * Secrets to hide from the LLM.