Act
Tap an element by text label, mark id, or absolute coordinates.
tap(text="Sign In")tap(mark_id=7)tap(x=195, y=480)tap_and_wait_keyboard
Section titled “tap_and_wait_keyboard”Atomic composite: tap a target, wait for the keyboard to slide up, then
observe the result. Use when focusing a text field and you need to confirm
the keyboard appeared before calling type_text. Returns the tap response
plus a post_state key with the post-tap observation. Saves ~2 round-trips
vs chaining tap + sleep + observe manually.
tap_and_wait_keyboard(text="Email")tap_and_wait_keyboard(mark=4, annotate=True)Swipe between two points (absolute or normalized 0–1 coordinates).
swipe(from_x=200, from_y=600, to_x=200, to_y=200, duration_ms=300)type_text
Section titled “type_text”Type into the currently-focused field via the simulator’s HID input stream.
type_text(text="hello@example.com", clear_first=False)press_key
Section titled “press_key”Send a hardware-style key (home, lock, volume_up/down, return).
press_key(key="home")clear_field
Section titled “clear_field”Clear the focused text field (select-all + delete).
clear_field()dismiss_sheet
Section titled “dismiss_sheet”Dismiss the topmost half-sheet or modal via a swipe-down at the grabber.
dismiss_sheet()