type_text
Types text into Swing text fields, text areas, password fields, spinners, and editable combo boxes using real key events, replacing or appending content and optionally pressing Enter to submit.
Instructions
Type into a text field, text area, password field, spinner or editable combo box like a user: the field gets the focus (the previous field's input verifier runs; if it refuses, nothing is typed and the result says why), the old text is selected and each character is sent as real key events, so key listeners, document filters and formatters run. Replaces the content unless append=true; submit=true then presses Enter. "\n" types Enter and "\t" types Tab (moves to the next field). Formatted fields and spinners commit on Enter or when the focus leaves them. The application window does not need to be in front. mode=set sets the text directly without key events (faster, but skips key listeners). Waits first (up to timeoutMs) until the component is visible, enabled, editable where needed, and not blocked by a modal dialog or busy overlay, so no wait_for is needed for a component that is about to become usable. Returns the new snapshot.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"ref": "<ref>",
"text": "<text>"
},
"name": "type_text"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| ref | Yes | ||
| mode | No | keys (default): key events inside the application; set: set the text directly; os: real keyboard through the operating system (brings the window to the front; rarely needed) | |
| text | Yes | ||
| append | No | Keep the current text and type at its end | |
| dialog | No | Answer the modal dialog this action opens with this button (text, or ok/yes/no/cancel); its message is reported. An error if no dialog opens within 3 s | |
| submit | No | Press Enter afterwards | |
| timeoutMs | No | How long to wait for the component to become usable (default 10000) |