@playwright/mcp 0.0.30 → 0.0.31

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.
package/README.md CHANGED
@@ -19,7 +19,9 @@ node utils/generate-links.js
19
19
 
20
20
  ### Getting started
21
21
 
22
- First, install the Playwright MCP server with your client. A typical configuration looks like this:
22
+ First, install the Playwright MCP server with your client.
23
+
24
+ **Standard config** works in most of the tools:
23
25
 
24
26
  ```js
25
27
  {
@@ -37,20 +39,25 @@ First, install the Playwright MCP server with your client. A typical configurati
37
39
  [<img src="https://img.shields.io/badge/VS_Code-VS_Code?style=flat-square&label=Install%20Server&color=0098FF" alt="Install in VS Code">](https://insiders.vscode.dev/redirect?url=vscode%3Amcp%2Finstall%3F%257B%2522name%2522%253A%2522playwright%2522%252C%2522command%2522%253A%2522npx%2522%252C%2522args%2522%253A%255B%2522%2540playwright%252Fmcp%2540latest%2522%255D%257D) [<img alt="Install in VS Code Insiders" src="https://img.shields.io/badge/VS_Code_Insiders-VS_Code_Insiders?style=flat-square&label=Install%20Server&color=24bfa5">](https://insiders.vscode.dev/redirect?url=vscode-insiders%3Amcp%2Finstall%3F%257B%2522name%2522%253A%2522playwright%2522%252C%2522command%2522%253A%2522npx%2522%252C%2522args%2522%253A%255B%2522%2540playwright%252Fmcp%2540latest%2522%255D%257D)
38
40
 
39
41
 
40
- <details><summary><b>Install in VS Code</b></summary>
42
+ <details>
43
+ <summary>Claude Code</summary>
41
44
 
42
- You can also install the Playwright MCP server using the VS Code CLI:
45
+ Use the Claude Code CLI to add the Playwright MCP server:
43
46
 
44
47
  ```bash
45
- # For VS Code
46
- code --add-mcp '{"name":"playwright","command":"npx","args":["@playwright/mcp@latest"]}'
48
+ claude mcp add playwright npx @playwright/mcp@latest
47
49
  ```
50
+ </details>
51
+
52
+ <details>
53
+ <summary>Claude Desktop</summary>
54
+
55
+ Follow the MCP install [guide](https://modelcontextprotocol.io/quickstart/user), use the standard config above.
48
56
 
49
- After installation, the Playwright MCP server will be available for use with your GitHub Copilot agent in VS Code.
50
57
  </details>
51
58
 
52
59
  <details>
53
- <summary><b>Install in Cursor</b></summary>
60
+ <summary>Cursor</summary>
54
61
 
55
62
  #### Click the button to install:
56
63
 
@@ -60,118 +67,53 @@ After installation, the Playwright MCP server will be available for use with you
60
67
 
61
68
  Go to `Cursor Settings` -> `MCP` -> `Add new MCP Server`. Name to your liking, use `command` type with the command `npx @playwright/mcp`. You can also verify config or add command like arguments via clicking `Edit`.
62
69
 
63
- ```js
64
- {
65
- "mcpServers": {
66
- "playwright": {
67
- "command": "npx",
68
- "args": [
69
- "@playwright/mcp@latest"
70
- ]
71
- }
72
- }
73
- }
74
- ```
75
70
  </details>
76
71
 
77
72
  <details>
78
- <summary><b>Install in Windsurf</b></summary>
73
+ <summary>Gemini CLI</summary>
79
74
 
80
- Follow Windsurf MCP [documentation](https://docs.windsurf.com/windsurf/cascade/mcp). Use following configuration:
75
+ Follow the MCP install [guide](https://github.com/google-gemini/gemini-cli/blob/main/docs/tools/mcp-server.md#configure-the-mcp-server-in-settingsjson), use the standard config above.
81
76
 
82
- ```js
83
- {
84
- "mcpServers": {
85
- "playwright": {
86
- "command": "npx",
87
- "args": [
88
- "@playwright/mcp@latest"
89
- ]
90
- }
91
- }
92
- }
93
- ```
94
77
  </details>
95
78
 
96
79
  <details>
97
- <summary><b>Install in Claude Desktop</b></summary>
80
+ <summary>Goose</summary>
98
81
 
99
- Follow the MCP install [guide](https://modelcontextprotocol.io/quickstart/user), use following configuration:
100
-
101
- ```js
102
- {
103
- "mcpServers": {
104
- "playwright": {
105
- "command": "npx",
106
- "args": [
107
- "@playwright/mcp@latest"
108
- ]
109
- }
110
- }
111
- }
112
- ```
113
- </details>
82
+ #### Click the button to install:
114
83
 
115
- <details>
116
- <summary><b>Install in Claude Code</b></summary>
84
+ [![Install in Goose](https://block.github.io/goose/img/extension-install-dark.svg)](https://block.github.io/goose/extension?cmd=npx&arg=%40playwright%2Fmcp%40latest&id=playwright&name=Playwright&description=Interact%20with%20web%20pages%20through%20structured%20accessibility%20snapshots%20using%20Playwright)
117
85
 
118
- Use the Claude Code CLI to add the Playwright MCP server:
86
+ #### Or install manually:
119
87
 
120
- ```bash
121
- claude mcp add playwright npx @playwright/mcp@latest
122
- ```
88
+ Go to `Advanced settings` -> `Extensions` -> `Add custom extension`. Name to your liking, use type `STDIO`, and set the `command` to `npx @playwright/mcp`. Click "Add Extension".
123
89
  </details>
124
90
 
125
91
  <details>
126
- <summary><b>Install in Goose</b></summary>
127
-
128
- #### Click the button to install:
129
-
130
- [![Install in Goose](https://block.github.io/goose/img/extension-install-dark.svg)](https://block.github.io/goose/extension?cmd=npx&arg=%40playwright%2Fmcp%40latest&id=playwright&name=Playwright&description=Interact%20with%20web%20pages%20through%20structured%20accessibility%20snapshots%20using%20Playwright)
92
+ <summary>Qodo Gen</summary>
131
93
 
132
- #### Or install manually:
94
+ Open [Qodo Gen](https://docs.qodo.ai/qodo-documentation/qodo-gen) chat panel in VSCode or IntelliJ → Connect more tools → + Add new MCP → Paste the standard config above.
133
95
 
134
- Go to `Advanced settings` -> `Extensions` -> `Add custom extension`. Name to your liking, use type `STDIO`, and set the `command` to `npx @playwright/mcp`. Click "Add Extension".
96
+ Click <code>Save</code>.
135
97
  </details>
136
98
 
137
99
  <details>
138
- <summary><b>Install in Qodo Gen</b></summary>
100
+ <summary>VS Code</summary>
139
101
 
140
- Open [Qodo Gen](https://docs.qodo.ai/qodo-documentation/qodo-gen) chat panel in VSCode or IntelliJ → Connect more tools → + Add new MCP Paste the following configuration:
102
+ You can also install the Playwright MCP server using the VS Code CLI:
141
103
 
142
- ```js
143
- {
144
- "mcpServers": {
145
- "playwright": {
146
- "command": "npx",
147
- "args": [
148
- "@playwright/mcp@latest"
149
- ]
150
- }
151
- }
152
- }
104
+ ```bash
105
+ # For VS Code
106
+ code --add-mcp '{"name":"playwright","command":"npx","args":["@playwright/mcp@latest"]}'
153
107
  ```
154
108
 
155
- Click <code>Save</code>.
109
+ After installation, the Playwright MCP server will be available for use with your GitHub Copilot agent in VS Code.
156
110
  </details>
157
111
 
158
112
  <details>
159
- <summary><b>Install in Gemini CLI</b></summary>
113
+ <summary>Windsurf</summary>
160
114
 
161
- Follow the MCP install [guide](https://github.com/google-gemini/gemini-cli/blob/main/docs/tools/mcp-server.md#configure-the-mcp-server-in-settingsjson), use following configuration:
115
+ Follow Windsurf MCP [documentation](https://docs.windsurf.com/windsurf/cascade/mcp). Use the standard config above.
162
116
 
163
- ```js
164
- {
165
- "mcpServers": {
166
- "playwright": {
167
- "command": "npx",
168
- "args": [
169
- "@playwright/mcp@latest"
170
- ]
171
- }
172
- }
173
- }
174
- ```
175
117
  </details>
176
118
 
177
119
  ### Configuration
@@ -192,10 +134,8 @@ Playwright MCP server supports following arguments. They can be provided in the
192
134
  --block-service-workers block service workers
193
135
  --browser <browser> browser or chrome channel to use, possible
194
136
  values: chrome, firefox, webkit, msedge.
195
- --browser-agent <endpoint> Use browser agent (experimental).
196
- --caps <caps> comma-separated list of capabilities to enable,
197
- possible values: tabs, pdf, history, wait, files,
198
- install. Default is all.
137
+ --caps <caps> comma-separated list of additional capabilities
138
+ to enable, possible values: vision, pdf.
199
139
  --cdp-endpoint <endpoint> CDP endpoint to connect to.
200
140
  --config <path> path to the configuration file.
201
141
  --device <device> device to emulate, for example: "iPhone 15"
@@ -207,9 +147,7 @@ Playwright MCP server supports following arguments. They can be provided in the
207
147
  --isolated keep the browser profile in memory, do not save
208
148
  it to disk.
209
149
  --image-responses <mode> whether to send image responses to the client.
210
- Can be "allow", "omit", or "auto". Defaults to
211
- "auto", which sends images if the client can
212
- display them.
150
+ Can be "allow" or "omit", Defaults to "allow".
213
151
  --no-sandbox disable the sandbox for all process types that
214
152
  are normally sandboxed.
215
153
  --output-dir <path> path to the directory for output files.
@@ -227,8 +165,6 @@ Playwright MCP server supports following arguments. They can be provided in the
227
165
  specified, a temporary directory will be created.
228
166
  --viewport-size <size> specify browser viewport size in pixels, for
229
167
  example "1280, 720"
230
- --vision Run server that uses screenshots (Aria snapshots
231
- are used by default)
232
168
  ```
233
169
 
234
170
  <!--- End of options generated section -->
@@ -329,21 +265,14 @@ npx @playwright/mcp@latest --config path/to/config.json
329
265
  host?: string; // Host to bind to (default: localhost)
330
266
  },
331
267
 
332
- // List of enabled capabilities
268
+ // List of additional capabilities
333
269
  capabilities?: Array<
334
- 'core' | // Core browser automation
335
270
  'tabs' | // Tab management
336
- 'pdf' | // PDF generation
337
- 'history' | // Browser history
338
- 'wait' | // Wait utilities
339
- 'files' | // File handling
340
271
  'install' | // Browser installation
341
- 'testing' // Testing
272
+ 'pdf' | // PDF generation
273
+ 'vision' | // Coordinate-based interactions
342
274
  >;
343
275
 
344
- // Enable vision mode (screenshots instead of accessibility snapshots)
345
- vision?: boolean;
346
-
347
276
  // Directory for output files
348
277
  outputDir?: string;
349
278
 
@@ -357,10 +286,10 @@ npx @playwright/mcp@latest --config path/to/config.json
357
286
  };
358
287
 
359
288
  /**
360
- * Whether to send image responses to the client. Can be "allow", "omit", or "auto".
361
- * Defaults to "auto", images are omitted for Cursor clients and sent for all other clients.
289
+ * Whether to send image responses to the client. Can be "allow" or "omit".
290
+ * Defaults to "allow".
362
291
  */
363
- imageResponses?: 'allow' | 'omit' | 'auto';
292
+ imageResponses?: 'allow' | 'omit';
364
293
  }
365
294
  ```
366
295
  </details>
@@ -433,42 +362,10 @@ http.createServer(async (req, res) => {
433
362
 
434
363
  ### Tools
435
364
 
436
- The tools are available in two modes:
437
-
438
- 1. **Snapshot Mode** (default): Uses accessibility snapshots for better performance and reliability
439
- 2. **Vision Mode**: Uses screenshots for visual-based interactions
440
-
441
- To use Vision Mode, add the `--vision` flag when starting the server:
442
-
443
- ```js
444
- {
445
- "mcpServers": {
446
- "playwright": {
447
- "command": "npx",
448
- "args": [
449
- "@playwright/mcp@latest",
450
- "--vision"
451
- ]
452
- }
453
- }
454
- }
455
- ```
456
-
457
- Vision Mode works best with the computer use models that are able to interact with elements using
458
- X Y coordinate space, based on the provided screenshot.
459
-
460
365
  <!--- Tools generated by update-readme.js -->
461
366
 
462
367
  <details>
463
- <summary><b>Interactions</b></summary>
464
-
465
- <!-- NOTE: This has been generated via update-readme.js -->
466
-
467
- - **browser_snapshot**
468
- - Title: Page snapshot
469
- - Description: Capture accessibility snapshot of the current page, this is better than screenshot
470
- - Parameters: None
471
- - Read-only: **true**
368
+ <summary><b>Core automation</b></summary>
472
369
 
473
370
  <!-- NOTE: This has been generated via update-readme.js -->
474
371
 
@@ -479,76 +376,50 @@ X Y coordinate space, based on the provided screenshot.
479
376
  - `element` (string): Human-readable element description used to obtain permission to interact with the element
480
377
  - `ref` (string): Exact target element reference from the page snapshot
481
378
  - `doubleClick` (boolean, optional): Whether to perform a double click instead of a single click
379
+ - `button` (string, optional): Button to click, defaults to left
482
380
  - Read-only: **false**
483
381
 
484
382
  <!-- NOTE: This has been generated via update-readme.js -->
485
383
 
486
- - **browser_drag**
487
- - Title: Drag mouse
488
- - Description: Perform drag and drop between two elements
489
- - Parameters:
490
- - `startElement` (string): Human-readable source element description used to obtain the permission to interact with the element
491
- - `startRef` (string): Exact source element reference from the page snapshot
492
- - `endElement` (string): Human-readable target element description used to obtain the permission to interact with the element
493
- - `endRef` (string): Exact target element reference from the page snapshot
494
- - Read-only: **false**
495
-
496
- <!-- NOTE: This has been generated via update-readme.js -->
497
-
498
- - **browser_hover**
499
- - Title: Hover mouse
500
- - Description: Hover over element on page
501
- - Parameters:
502
- - `element` (string): Human-readable element description used to obtain permission to interact with the element
503
- - `ref` (string): Exact target element reference from the page snapshot
384
+ - **browser_close**
385
+ - Title: Close browser
386
+ - Description: Close the page
387
+ - Parameters: None
504
388
  - Read-only: **true**
505
389
 
506
390
  <!-- NOTE: This has been generated via update-readme.js -->
507
391
 
508
- - **browser_type**
509
- - Title: Type text
510
- - Description: Type text into editable element
511
- - Parameters:
512
- - `element` (string): Human-readable element description used to obtain permission to interact with the element
513
- - `ref` (string): Exact target element reference from the page snapshot
514
- - `text` (string): Text to type into the element
515
- - `submit` (boolean, optional): Whether to submit entered text (press Enter after)
516
- - `slowly` (boolean, optional): Whether to type one character at a time. Useful for triggering key handlers in the page. By default entire text is filled in at once.
517
- - Read-only: **false**
392
+ - **browser_console_messages**
393
+ - Title: Get console messages
394
+ - Description: Returns all console messages
395
+ - Parameters: None
396
+ - Read-only: **true**
518
397
 
519
398
  <!-- NOTE: This has been generated via update-readme.js -->
520
399
 
521
- - **browser_select_option**
522
- - Title: Select option
523
- - Description: Select an option in a dropdown
400
+ - **browser_drag**
401
+ - Title: Drag mouse
402
+ - Description: Perform drag and drop between two elements
524
403
  - Parameters:
525
- - `element` (string): Human-readable element description used to obtain permission to interact with the element
526
- - `ref` (string): Exact target element reference from the page snapshot
527
- - `values` (array): Array of values to select in the dropdown. This can be a single value or multiple values.
404
+ - `startElement` (string): Human-readable source element description used to obtain the permission to interact with the element
405
+ - `startRef` (string): Exact source element reference from the page snapshot
406
+ - `endElement` (string): Human-readable target element description used to obtain the permission to interact with the element
407
+ - `endRef` (string): Exact target element reference from the page snapshot
528
408
  - Read-only: **false**
529
409
 
530
410
  <!-- NOTE: This has been generated via update-readme.js -->
531
411
 
532
- - **browser_press_key**
533
- - Title: Press a key
534
- - Description: Press a key on the keyboard
412
+ - **browser_evaluate**
413
+ - Title: Evaluate JavaScript
414
+ - Description: Evaluate JavaScript expression on page or element
535
415
  - Parameters:
536
- - `key` (string): Name of the key to press or a character to generate, such as `ArrowLeft` or `a`
416
+ - `function` (string): () => { /* code */ } or (element) => { /* code */ } when element is provided
417
+ - `element` (string, optional): Human-readable element description used to obtain permission to interact with the element
418
+ - `ref` (string, optional): Exact target element reference from the page snapshot
537
419
  - Read-only: **false**
538
420
 
539
421
  <!-- NOTE: This has been generated via update-readme.js -->
540
422
 
541
- - **browser_wait_for**
542
- - Title: Wait for
543
- - Description: Wait for text to appear or disappear or a specified time to pass
544
- - Parameters:
545
- - `time` (number, optional): The time to wait in seconds
546
- - `text` (string, optional): The text to wait for
547
- - `textGone` (string, optional): The text to wait for to disappear
548
- - Read-only: **true**
549
-
550
- <!-- NOTE: This has been generated via update-readme.js -->
551
-
552
423
  - **browser_file_upload**
553
424
  - Title: Upload files
554
425
  - Description: Upload one or multiple files
@@ -566,10 +437,15 @@ X Y coordinate space, based on the provided screenshot.
566
437
  - `promptText` (string, optional): The text of the prompt in case of a prompt dialog.
567
438
  - Read-only: **false**
568
439
 
569
- </details>
440
+ <!-- NOTE: This has been generated via update-readme.js -->
570
441
 
571
- <details>
572
- <summary><b>Navigation</b></summary>
442
+ - **browser_hover**
443
+ - Title: Hover mouse
444
+ - Description: Hover over element on page
445
+ - Parameters:
446
+ - `element` (string): Human-readable element description used to obtain permission to interact with the element
447
+ - `ref` (string): Exact target element reference from the page snapshot
448
+ - Read-only: **true**
573
449
 
574
450
  <!-- NOTE: This has been generated via update-readme.js -->
575
451
 
@@ -596,83 +472,101 @@ X Y coordinate space, based on the provided screenshot.
596
472
  - Parameters: None
597
473
  - Read-only: **true**
598
474
 
599
- </details>
475
+ <!-- NOTE: This has been generated via update-readme.js -->
600
476
 
601
- <details>
602
- <summary><b>Resources</b></summary>
477
+ - **browser_network_requests**
478
+ - Title: List network requests
479
+ - Description: Returns all network requests since loading the page
480
+ - Parameters: None
481
+ - Read-only: **true**
603
482
 
604
483
  <!-- NOTE: This has been generated via update-readme.js -->
605
484
 
606
- - **browser_take_screenshot**
607
- - Title: Take a screenshot
608
- - Description: Take a screenshot of the current page. You can't perform actions based on the screenshot, use browser_snapshot for actions.
485
+ - **browser_press_key**
486
+ - Title: Press a key
487
+ - Description: Press a key on the keyboard
609
488
  - Parameters:
610
- - `raw` (boolean, optional): Whether to return without compression (in PNG format). Default is false, which returns a JPEG image.
611
- - `filename` (string, optional): File name to save the screenshot to. Defaults to `page-{timestamp}.{png|jpeg}` if not specified.
612
- - `element` (string, optional): Human-readable element description used to obtain permission to screenshot the element. If not provided, the screenshot will be taken of viewport. If element is provided, ref must be provided too.
613
- - `ref` (string, optional): Exact target element reference from the page snapshot. If not provided, the screenshot will be taken of viewport. If ref is provided, element must be provided too.
614
- - Read-only: **true**
489
+ - `key` (string): Name of the key to press or a character to generate, such as `ArrowLeft` or `a`
490
+ - Read-only: **false**
615
491
 
616
492
  <!-- NOTE: This has been generated via update-readme.js -->
617
493
 
618
- - **browser_pdf_save**
619
- - Title: Save as PDF
620
- - Description: Save page as PDF
494
+ - **browser_resize**
495
+ - Title: Resize browser window
496
+ - Description: Resize the browser window
621
497
  - Parameters:
622
- - `filename` (string, optional): File name to save the pdf to. Defaults to `page-{timestamp}.pdf` if not specified.
498
+ - `width` (number): Width of the browser window
499
+ - `height` (number): Height of the browser window
623
500
  - Read-only: **true**
624
501
 
625
502
  <!-- NOTE: This has been generated via update-readme.js -->
626
503
 
627
- - **browser_network_requests**
628
- - Title: List network requests
629
- - Description: Returns all network requests since loading the page
630
- - Parameters: None
631
- - Read-only: **true**
504
+ - **browser_select_option**
505
+ - Title: Select option
506
+ - Description: Select an option in a dropdown
507
+ - Parameters:
508
+ - `element` (string): Human-readable element description used to obtain permission to interact with the element
509
+ - `ref` (string): Exact target element reference from the page snapshot
510
+ - `values` (array): Array of values to select in the dropdown. This can be a single value or multiple values.
511
+ - Read-only: **false**
632
512
 
633
513
  <!-- NOTE: This has been generated via update-readme.js -->
634
514
 
635
- - **browser_console_messages**
636
- - Title: Get console messages
637
- - Description: Returns all console messages
515
+ - **browser_snapshot**
516
+ - Title: Page snapshot
517
+ - Description: Capture accessibility snapshot of the current page, this is better than screenshot
638
518
  - Parameters: None
639
519
  - Read-only: **true**
640
520
 
641
- </details>
642
-
643
- <details>
644
- <summary><b>Utilities</b></summary>
645
-
646
521
  <!-- NOTE: This has been generated via update-readme.js -->
647
522
 
648
- - **browser_install**
649
- - Title: Install the browser specified in the config
650
- - Description: Install the browser specified in the config. Call this if you get an error about the browser not being installed.
651
- - Parameters: None
652
- - Read-only: **false**
523
+ - **browser_take_screenshot**
524
+ - Title: Take a screenshot
525
+ - Description: Take a screenshot of the current page. You can't perform actions based on the screenshot, use browser_snapshot for actions.
526
+ - Parameters:
527
+ - `raw` (boolean, optional): Whether to return without compression (in PNG format). Default is false, which returns a JPEG image.
528
+ - `filename` (string, optional): File name to save the screenshot to. Defaults to `page-{timestamp}.{png|jpeg}` if not specified.
529
+ - `element` (string, optional): Human-readable element description used to obtain permission to screenshot the element. If not provided, the screenshot will be taken of viewport. If element is provided, ref must be provided too.
530
+ - `ref` (string, optional): Exact target element reference from the page snapshot. If not provided, the screenshot will be taken of viewport. If ref is provided, element must be provided too.
531
+ - Read-only: **true**
653
532
 
654
533
  <!-- NOTE: This has been generated via update-readme.js -->
655
534
 
656
- - **browser_close**
657
- - Title: Close browser
658
- - Description: Close the page
659
- - Parameters: None
660
- - Read-only: **true**
535
+ - **browser_type**
536
+ - Title: Type text
537
+ - Description: Type text into editable element
538
+ - Parameters:
539
+ - `element` (string): Human-readable element description used to obtain permission to interact with the element
540
+ - `ref` (string): Exact target element reference from the page snapshot
541
+ - `text` (string): Text to type into the element
542
+ - `submit` (boolean, optional): Whether to submit entered text (press Enter after)
543
+ - `slowly` (boolean, optional): Whether to type one character at a time. Useful for triggering key handlers in the page. By default entire text is filled in at once.
544
+ - Read-only: **false**
661
545
 
662
546
  <!-- NOTE: This has been generated via update-readme.js -->
663
547
 
664
- - **browser_resize**
665
- - Title: Resize browser window
666
- - Description: Resize the browser window
548
+ - **browser_wait_for**
549
+ - Title: Wait for
550
+ - Description: Wait for text to appear or disappear or a specified time to pass
667
551
  - Parameters:
668
- - `width` (number): Width of the browser window
669
- - `height` (number): Height of the browser window
552
+ - `time` (number, optional): The time to wait in seconds
553
+ - `text` (string, optional): The text to wait for
554
+ - `textGone` (string, optional): The text to wait for to disappear
670
555
  - Read-only: **true**
671
556
 
672
557
  </details>
673
558
 
674
559
  <details>
675
- <summary><b>Tabs</b></summary>
560
+ <summary><b>Tab management</b></summary>
561
+
562
+ <!-- NOTE: This has been generated via update-readme.js -->
563
+
564
+ - **browser_tab_close**
565
+ - Title: Close a tab
566
+ - Description: Close a tab
567
+ - Parameters:
568
+ - `index` (number, optional): The index of the tab to close. Closes current tab if not provided.
569
+ - Read-only: **false**
676
570
 
677
571
  <!-- NOTE: This has been generated via update-readme.js -->
678
572
 
@@ -700,60 +594,29 @@ X Y coordinate space, based on the provided screenshot.
700
594
  - `index` (number): The index of the tab to select
701
595
  - Read-only: **true**
702
596
 
703
- <!-- NOTE: This has been generated via update-readme.js -->
704
-
705
- - **browser_tab_close**
706
- - Title: Close a tab
707
- - Description: Close a tab
708
- - Parameters:
709
- - `index` (number, optional): The index of the tab to close. Closes current tab if not provided.
710
- - Read-only: **false**
711
-
712
597
  </details>
713
598
 
714
599
  <details>
715
- <summary><b>Testing</b></summary>
600
+ <summary><b>Browser installation</b></summary>
716
601
 
717
602
  <!-- NOTE: This has been generated via update-readme.js -->
718
603
 
719
- - **browser_generate_playwright_test**
720
- - Title: Generate a Playwright test
721
- - Description: Generate a Playwright test for given scenario
722
- - Parameters:
723
- - `name` (string): The name of the test
724
- - `description` (string): The description of the test
725
- - `steps` (array): The steps of the test
726
- - Read-only: **true**
604
+ - **browser_install**
605
+ - Title: Install the browser specified in the config
606
+ - Description: Install the browser specified in the config. Call this if you get an error about the browser not being installed.
607
+ - Parameters: None
608
+ - Read-only: **false**
727
609
 
728
610
  </details>
729
611
 
730
612
  <details>
731
- <summary><b>Vision mode</b></summary>
732
-
733
- <!-- NOTE: This has been generated via update-readme.js -->
734
-
735
- - **browser_screen_capture**
736
- - Title: Take a screenshot
737
- - Description: Take a screenshot of the current page
738
- - Parameters: None
739
- - Read-only: **true**
740
-
741
- <!-- NOTE: This has been generated via update-readme.js -->
742
-
743
- - **browser_screen_move_mouse**
744
- - Title: Move mouse
745
- - Description: Move mouse to a given position
746
- - Parameters:
747
- - `element` (string): Human-readable element description used to obtain permission to interact with the element
748
- - `x` (number): X coordinate
749
- - `y` (number): Y coordinate
750
- - Read-only: **true**
613
+ <summary><b>Coordinate-based (opt-in via --caps=vision)</b></summary>
751
614
 
752
615
  <!-- NOTE: This has been generated via update-readme.js -->
753
616
 
754
- - **browser_screen_click**
617
+ - **browser_mouse_click_xy**
755
618
  - Title: Click
756
- - Description: Click left mouse button
619
+ - Description: Click left mouse button at a given position
757
620
  - Parameters:
758
621
  - `element` (string): Human-readable element description used to obtain permission to interact with the element
759
622
  - `x` (number): X coordinate
@@ -762,9 +625,9 @@ X Y coordinate space, based on the provided screenshot.
762
625
 
763
626
  <!-- NOTE: This has been generated via update-readme.js -->
764
627
 
765
- - **browser_screen_drag**
628
+ - **browser_mouse_drag_xy**
766
629
  - Title: Drag mouse
767
- - Description: Drag left mouse button
630
+ - Description: Drag left mouse button to a given position
768
631
  - Parameters:
769
632
  - `element` (string): Human-readable element description used to obtain permission to interact with the element
770
633
  - `startX` (number): Start X coordinate
@@ -775,52 +638,28 @@ X Y coordinate space, based on the provided screenshot.
775
638
 
776
639
  <!-- NOTE: This has been generated via update-readme.js -->
777
640
 
778
- - **browser_screen_type**
779
- - Title: Type text
780
- - Description: Type text
781
- - Parameters:
782
- - `text` (string): Text to type into the element
783
- - `submit` (boolean, optional): Whether to submit entered text (press Enter after)
784
- - Read-only: **false**
785
-
786
- <!-- NOTE: This has been generated via update-readme.js -->
787
-
788
- - **browser_press_key**
789
- - Title: Press a key
790
- - Description: Press a key on the keyboard
791
- - Parameters:
792
- - `key` (string): Name of the key to press or a character to generate, such as `ArrowLeft` or `a`
793
- - Read-only: **false**
794
-
795
- <!-- NOTE: This has been generated via update-readme.js -->
796
-
797
- - **browser_wait_for**
798
- - Title: Wait for
799
- - Description: Wait for text to appear or disappear or a specified time to pass
641
+ - **browser_mouse_move_xy**
642
+ - Title: Move mouse
643
+ - Description: Move mouse to a given position
800
644
  - Parameters:
801
- - `time` (number, optional): The time to wait in seconds
802
- - `text` (string, optional): The text to wait for
803
- - `textGone` (string, optional): The text to wait for to disappear
645
+ - `element` (string): Human-readable element description used to obtain permission to interact with the element
646
+ - `x` (number): X coordinate
647
+ - `y` (number): Y coordinate
804
648
  - Read-only: **true**
805
649
 
806
- <!-- NOTE: This has been generated via update-readme.js -->
650
+ </details>
807
651
 
808
- - **browser_file_upload**
809
- - Title: Upload files
810
- - Description: Upload one or multiple files
811
- - Parameters:
812
- - `paths` (array): The absolute paths to the files to upload. Can be a single file or multiple files.
813
- - Read-only: **false**
652
+ <details>
653
+ <summary><b>PDF generation (opt-in via --caps=pdf)</b></summary>
814
654
 
815
655
  <!-- NOTE: This has been generated via update-readme.js -->
816
656
 
817
- - **browser_handle_dialog**
818
- - Title: Handle a dialog
819
- - Description: Handle a dialog
657
+ - **browser_pdf_save**
658
+ - Title: Save as PDF
659
+ - Description: Save page as PDF
820
660
  - Parameters:
821
- - `accept` (boolean): Whether to accept the dialog.
822
- - `promptText` (string, optional): The text of the prompt in case of a prompt dialog.
823
- - Read-only: **false**
661
+ - `filename` (string, optional): File name to save the pdf to. Defaults to `page-{timestamp}.pdf` if not specified.
662
+ - Read-only: **true**
824
663
 
825
664
  </details>
826
665