session_press
Press a single keyboard key on the focused element or a named selector to submit forms, dismiss dialogs, or navigate suggestion lists. Returns the pressed key for confirmation.
Instructions
Press a single keyboard key on the focused element, or on a named element after focusing it. Use it to submit a form with Enter, dismiss a dialog with Escape, or walk a suggestion list with ArrowDown. Returns {pressed} naming the key. Supported keys are Enter, Tab, Escape, Backspace, Delete, ArrowUp, ArrowDown, ArrowLeft, ArrowRight, Home, End, PageUp, PageDown and Space; anything else fails with the supported list rather than doing nothing.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| key | Yes | One of Enter, Tab, Escape, Backspace, Delete, ArrowUp, ArrowDown, ArrowLeft, ArrowRight, Home, End, PageUp, PageDown, Space | |
| ref | No | A ref from session_snapshot, such as @e12, used instead of selector | |
| tabId | No | Tab to act on; uses the active tab when omitted | |
| selector | No | CSS selector for the element to press the key on; uses the focused element when omitted |