Run Playwright code (unsafe)
browser_run_code_unsafeRun Python Playwright scripts with full server access for complete control over browser automation tasks.
Instructions
Run a Python Playwright code snippet. Unsafe: executes arbitrary Python in the Playwright server process with normal builtins/imports and is RCE-equivalent.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| code | No | Python Playwright code to execute. It may define an async function or provide statements that run with page in scope. | |
| _meta | No | ||
| filename | No | Load code from the specified file. If both code and filename are provided, code will be ignored. |