drag
Simulates a mouse press-and-move gesture between two coordinates to automate selections and window interactions while guarding against interrupting active user input.
Instructions
Drag mouse from (x1, y1) to (x2, y2) with User-Activity Guard and cursor/focus restore.
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": {
"x1": "<x1>",
"y1": "<y1>",
"x2": "<x2>",
"y2": "<y2>"
},
"name": "drag"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| x1 | Yes | ||
| x2 | Yes | ||
| y1 | Yes | ||
| y2 | Yes | ||
| hwnd | No | ||
| button | No | left | |
| duration | No | ||
| user_idle_ms | No | ||
| client_coords | No | ||
| restore_focus | No | ||
| restore_cursor | No | ||
| title_contains | No | ||
| respect_user_input | No | ||
| wait_for_idle_seconds | No |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |