session_input
Type text into an input/textarea element by its index (from session_state output), focusing it and dispatching input/change events. events:"full" is the complete human typing gesture: per-character keydown/keypress/input/keyup cycles, trailing change, then blur — the tail blur commits on forms that save in onBlur (React capture listeners, #100). In full mode a newline in the text types as the Enter key (key:'Enter', keyCode 13 — "type + Enter submit"): a textarea keeps the newline in its value, a single-line input stays single-line, the page's Enter listeners fire before the blur, and if the key wasn't canceled the input's form submits implicitly (Chrome's default action; preventDefault on the key or submit events vetoes it, so chat inputs that swallow Enter stay unsubmitted). Any characters — newlines, quotes, backslashes — ride through as-is. A refused fill answers filled:false with a reason (readonly/disabled/detached/no-element/wrong-tag/script-error) instead of a silent write. Hidden inputs are legitimate targets and are filled normally.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| text | Yes | Text to type into the input field | |
| index | Yes | Element index (from /state output) | |
| events | No | Event fidelity: "full" types one character at a time with a keydown/keypress/input/keyup cycle per character, for pages whose listeners key on keyboard events (e.g. keypress-Enter login forms). Default fires a single input+change pair after the value is set. | |
| session_id | Yes | Session ID |