session_select
Selects an option in a dropdown by value, visible text, substring, or index, including when native value setters fail. Returns chosen option details and lists available options if no match.
Instructions
Choose an option in a dropdown, by value, by visible text, or by index. Filling a select as though it were a text field does nothing — the native value setter belongs to HTMLInputElement and has no effect here — which is the silent failure this tool exists to prevent. Matches value first, then exact visible text, then a substring, then index. Returns {selected, value, text} for the chosen option, and on no match fails with the available options listed.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| ref | No | A ref from session_snapshot, such as @e12, used instead of selector | |
| text | No | Visible option text to choose; matched exactly first, then by substring | |
| index | No | Zero-based option index to choose; tried last | |
| tabId | No | Tab to act on; uses the active tab when omitted | |
| value | No | Option value to choose; tried first | |
| selector | Yes | CSS selector for the <select> |