Handle Dialog
browser.handle_dialogSet handling for upcoming browser dialogs like alerts, confirms, and prompts. Call before the action that triggers the dialog to accept or dismiss it with optional input.
Instructions
Set how the next native dialog (alert/confirm/prompt) will be handled. Call before the action that triggers the 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": {
"sessionId": "<sessionId>",
"accept": "<accept>"
},
"name": "browser.handle_dialog"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| accept | Yes | ||
| sessionId | Yes | ||
| promptText | No |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| success | Yes |