long_press
Simulate a touch-and-hold on an Android screen at specified coordinates for a set duration. Enables UI automation and testing of press-and-hold interactions.
Instructions
Long-press at (x, y) for duration_ms (implemented as a zero-distance swipe).
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": {
"x": "<x>",
"y": "<y>"
},
"name": "long_press"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| x | Yes | ||
| y | Yes | ||
| serial | No | ||
| duration_ms | No |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||