@swmansion/argent 0.21.1-next.9 → 0.22.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Binary file
Binary file
Binary file
Binary file
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@swmansion/argent",
3
- "version": "0.21.1-next.9",
3
+ "version": "0.22.0",
4
4
  "mcpName": "io.github.software-mansion/argent",
5
5
  "description": "MCP server for iOS Simulator and Android Emulator control",
6
6
  "license": "Apache-2.0",
@@ -56,27 +56,28 @@ Common schemes: `messages://`, `settings://`, `maps://?q=<query>`, `tel://<numbe
56
56
 
57
57
  ## 4. Choosing the Right Tool
58
58
 
59
- | Action | Tool | Notes |
60
- | ----------------- | ------------------- | ---------------------------------------------------------------- |
61
- | Multiple actions | `run-sequence` | Batch steps in one call (no intermediate screenshots) |
62
- | Open an app | `launch-app` | **Always — never tap home-screen icons** |
63
- | Restart an app | `restart-app` | Terminate and relaunch by bundle ID |
64
- | Open URL/scheme | `open-url` | Web pages, deep links, URL schemes |
65
- | Single tap | `gesture-tap` | Buttons, links, checkboxes |
66
- | Scroll/swipe | `gesture-swipe` | Straight-line scroll or swipe |
67
- | Scroll (Chromium) | `gesture-scroll` | Wheel-based; deltas are window fractions, positive deltaY = down |
68
- | Drag (Chromium) | `gesture-drag` | Sliders, drag-and-drop, text selection |
69
- | Long press | `gesture-custom` | Context menus, drag start |
70
- | Drag & drop | `gesture-custom` | Complex drag interactions |
71
- | Pinch/zoom | `gesture-pinch` | Two-finger pinch with auto-interpolation |
72
- | Rotation | `gesture-rotate` | Two-finger rotation with auto-interpolation |
73
- | Custom gesture | `gesture-custom` | Arbitrary touch sequences, optional interpolation |
74
- | Hardware key | `button` | Home, back, power, volume, appSwitch, actionButton |
75
- | Type text | `keyboard` | Every platform. Text or one named key per call, never both |
76
- | Rotate device | `rotate` | Orientation changes |
77
- | Shake device | `shake` | Shake handlers (sim/emu only), Undo-typing prompt, RN dev menu |
78
- | Wait for UI | `await-ui-element` | Block until an element is visible/hidden/exists/contains text |
79
- | Wait for idle | `await-screen-idle` | Block until a non-empty screen tree stops changing |
59
+ | Action | Tool | Notes |
60
+ | ----------------- | ------------------- | ----------------------------------------------------------------- |
61
+ | Multiple actions | `run-sequence` | Batch steps in one call (no intermediate screenshots) |
62
+ | Open an app | `launch-app` | **Always — never tap home-screen icons** |
63
+ | Restart an app | `restart-app` | Terminate and relaunch by bundle ID |
64
+ | Open URL/scheme | `open-url` | Web pages, deep links, URL schemes |
65
+ | Single tap | `gesture-tap` | Buttons, links, checkboxes |
66
+ | Scroll/swipe | `gesture-swipe` | Straight-line scroll or swipe |
67
+ | Scroll (Chromium) | `gesture-scroll` | Wheel-based; deltas are window fractions, positive deltaY = down |
68
+ | Drag (Chromium) | `gesture-drag` | Sliders, drag-and-drop, text selection |
69
+ | Long press | `gesture-custom` | Context menus, drag start |
70
+ | Drag & drop | `gesture-custom` | Complex drag interactions |
71
+ | Pinch/zoom | `gesture-pinch` | Two-finger pinch with auto-interpolation |
72
+ | Rotation | `gesture-rotate` | Two-finger rotation with auto-interpolation |
73
+ | Custom gesture | `gesture-custom` | Arbitrary touch sequences, optional interpolation |
74
+ | Hardware key | `button` | Home, back, power, volume, appSwitch, actionButton |
75
+ | Type text | `keyboard` | Every platform. Text or one named key per call, never both |
76
+ | Paste text | `paste` | Only where a user would paste (OTP code, long link). Sim/emu only |
77
+ | Rotate device | `rotate` | Orientation changes |
78
+ | Shake device | `shake` | Shake handlers (sim/emu only), Undo-typing prompt, RN dev menu |
79
+ | Wait for UI | `await-ui-element` | Block until an element is visible/hidden/exists/contains text |
80
+ | Wait for idle | `await-screen-idle` | Block until a non-empty screen tree stops changing |
80
81
 
81
82
  ## 5. Finding Tap Targets
82
83
 
@@ -197,6 +198,18 @@ Rules:
197
198
  - Nothing outside those sources is reachable; never ask the user to paste a secret value into the conversation. Ask them to put it in a secrets file instead — a file edit applies to the next call, while an exported env var only reaches a tool-server started afterwards.
198
199
  - The project sources are found by walking up from the tool-server's working directory. If a project file is not being picked up, the failure's source list shows the paths actually consulted; `~/.argent/secrets.env` needs no project and always applies.
199
200
 
201
+ ### paste — Paste text into the focused field
202
+
203
+ ```json
204
+ { "udid": "<UDID>", "text": "482913" }
205
+ ```
206
+
207
+ Puts `text` on the **device** clipboard (the host clipboard is untouched) and triggers the platform's paste shortcut. iOS simulator and Android emulator only; a TV target, a physical device, Chromium and Vega are rejected.
208
+
209
+ `paste` is **not** a faster `keyboard`. `keyboard` types the way a user types and stays the default for every text entry — a search query, a login, a form field. Reach for `paste` only where a real user would paste: a 2FA / OTP code copied from another app, a long link or token, or to test how the app handles pasted input. It also carries what `keyboard` can't type on a given platform (multi-line text, non-ASCII on Android), but that alone is not a reason to paste — ask whether the user would.
210
+
211
+ Tap the field first so it has focus; pasting with no focused field is a silent no-op, as with `keyboard`. `text` accepts the same `{{secret:<NAME>}}` placeholders as `keyboard`, with the same auto-screenshot skip.
212
+
200
213
  ### rotate — Change orientation
201
214
 
202
215
  ```json
@@ -297,7 +310,7 @@ Use the sequencing when:
297
310
 
298
311
  ### Allowed tools inside `run-sequence`
299
312
 
300
- `gesture-tap`, `gesture-swipe`, `gesture-scroll`, `gesture-drag`, `gesture-custom`, `gesture-pinch`, `gesture-rotate`, `button`, `keyboard`, `rotate`, `await-ui-element`
313
+ `gesture-tap`, `gesture-swipe`, `gesture-scroll`, `gesture-drag`, `gesture-custom`, `gesture-pinch`, `gesture-rotate`, `button`, `keyboard`, `paste`, `rotate`, `shake`, `tv-remote`, `await-ui-element`
301
314
 
302
315
  The `udid` is shared — do **not** include it in each step's `args`. Optional `delayMs` per step (default 100ms).
303
316