Browser Message Box API Reference
Recommended guidance
Use browser message box APIs only when a test must handle JavaScript alerts, confirms, or prompts during playback. Validate behavior in the current Scenario Editor runtime because older Test Designer API examples may depend on legacy browser behavior.
Message box types
- Alert: informational dialog that usually requires OK.
- Confirm: dialog that expects accept or dismiss behavior.
- Prompt: dialog that may require entering controlled text before accepting.
Validation checklist
- Confirm the dialog is application-generated, not a browser permission or security prompt.
- Trigger the dialog in a controlled test environment.
- Handle the dialog before continuing to steps that depend on the page state.
- Assert the expected application result after accepting, dismissing, or entering prompt text.
- Avoid using dialog handling to bypass browser security warnings or customer controls.
Legacy note: Keep old API names only when maintaining existing scripts. New documentation should describe the behavior in Scenario Editor terms.
Last updated: October 6, 2026