ahk_control_send
Send keystrokes or text to background windows and controls without focusing them, enabling reliable GUI automation on headless desktops.
Instructions
Send text or keystrokes to a background window/control via AutoHotkey ControlSend.
Works without focusing the window and is often more reliable than raw WM_CHAR for complex apps. Target a HWND with 'ahk_id '.
Args: params (AhkControlSendInput): text, window/control targets, as_keys, timeout.
Returns: str: JSON with the AHK run result.
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": {
"params": "<params>"
},
"name": "ahk_control_send"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| params | Yes |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |