execute_js
Execute custom JavaScript in the browser to scrape data or automate interactions using Chrome DevTools Protocol.
Instructions
Execute arbitrary JavaScript in the current page via CDP.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"script": "<script>"
},
"name": "execute_js"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| script | Yes | JavaScript to execute |