Decide what the page’s own native dialogs do
qa_dialogsSuppress or answer browser dialogs like confirm(), alert(), prompt(), and "Leave site?" prompts by setting a per-tab policy, so navigation and flows proceed without blocking. Every suppressed dialog is logged as a finding.
Instructions
The browser's OWN dialogs — “Leave site? Changes you made may not be saved”, confirm(), alert(), prompt() — are drawn outside the document, so no click of any kind can reach their buttons. Nothing on this bridge can press them and nothing in any page can. What IS reachable is the page's REQUEST for them, and that is what this changes: beforeunload:true stops the app from asking, so the navigation simply proceeds; confirm:"accept"|"dismiss" decides what confirm() returns; alert:true swallows alerts; prompt supplies the string (or null to cancel). op:'list' is free and reads the policy in force; setting one needs the Agent control consent, because an auto-accepted confirm can be the one in front of Delete. SCOPE: this tab, until it closes; it survives reloads of it. EVERY suppressed dialog is logged as a finding carrying the question the page asked and the answer given — so never report that the app stopped asking. It asked; Qiksy answered. Clear it (op:'clear') as soon as the flow is through.
Tool call template
This tool declares no required parameters. Add optional parameters from the input schema as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {},
"name": "qa_dialogs"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| op | No | Default 'set' | |
| alert | No | true = swallow alert() instead of blocking on it | |
| tabId | No | Target tab (from qa_tabs); omit for the active tab | |
| prompt | No | What prompt() returns; null cancels it | |
| confirm | No | What confirm() returns; null removes the override | |
| beforeunload | No | true = let navigation through without the browser’s “Leave site?” prompt |