safari_run_javascript
Execute JavaScript in the active or specified Safari tab to extract data, modify page content, or automate browser interactions.
Instructions
Run JavaScript in the current Safari page.
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": "safari_run_javascript"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| script | Yes | ||
| tab_index | No | ||
| window_index | No |