browser_handle_dialog
Handle browser dialogs by accepting or dismissing prompts during automated web interactions. Manage dialog responses to continue script execution without manual intervention.
Instructions
Handle dialog
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": {
"accept": "<accept>"
},
"name": "browser_handle_dialog"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| accept | Yes | ||
| promptText | No |
Implementation Reference
- index.js:443-450 (registration)Registration of the 'browser_handle_dialog' tool in index.js. It delegates execution to 'proxyToolCall'.
server.tool('browser_handle_dialog', 'Handle dialog', { accept: z.boolean(), promptText: z.string().optional() }, async (args) => { const check = requireActivePage(); if (check) return check; return proxyToolCall('browser_handle_dialog', args); });