Run pan, fling, swipe, pinch, rotate, transform, tap, or drag gestures
gestureExecute structured touch actions—pan, fling, swipe, pinch, rotate, tap, or drag—on mobile, desktop, and TV apps to automate complex UI interactions.
Instructions
Perform a structured pan, fling, swipe, pinch, rotate, transform, tap, or drag gesture. Each gesture kind has its own inputs. A tap touches 2 to 5 points at once; count and pauseMs control repetition. A drag takes a source and a destination ref or selector and holds the source down for 800 ms by default before carrying it over, which is how a list item changes position or a drop target is hit. Times out after 90s.
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": {
"kind": "<kind>"
},
"name": "gesture"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| kind | Yes | Gesture variant. | |
| udid | No | Apple device or simulator UDID. | |
| count | No | Tap repetitions; the same contacts run this many times. | |
| delta | No | Movement delta for pan or transform gestures. | |
| scale | No | Pinch or transform scale. | |
| device | No | Device name; ids go in udid or serial. | |
| holdMs | No | Tap contact hold duration. | |
| moveMs | No | Drag movement duration. | |
| origin | No | Gesture origin point. | |
| points | No | Tap contact points, held together for holdMs. | |
| preset | No | Swipe preset. | |
| serial | No | Android, HarmonyOS, or Vega VVD serial. | |
| source | No | Drag source @ref or selector. | |
| degrees | No | Rotation in degrees. | |
| pauseMs | No | Delay between tap repetitions, added to each repetition’s own time. | |
| session | No | Session name. | |
| distance | No | Fling distance. | |
| noRecord | No | Do not record this action. | |
| platform | No | Device platform. | |
| direction | No | Fling direction. | |
| durationMs | No | Pan/transform duration. | |
| destination | No | Drag destination @ref or selector. | |
| deviceTarget | No | Device form factor. | |
| pointerCount | No | Pan touch pointer count (1 or 2). | |
| sourceHoldMs | No | Drag activation hold duration. | |
| destinationHoldMs | No | Hold before releasing at the destination. |