Skip to main content

mobium tap

This tool on every surface: CLI · MCP · Python · JavaScript · Go · Java · .NET

Tap an element or a point

Usage​

mobium tap <@ref | locator | x y> [flags]

Flags​

FlagTypeDefaultWhat it does
--fingersint1how many fingers tap at once, side by side (1 to 5)

And the global flags.

Examples​

Tap an element by its visible text​

mobium tap "text=Network & internet"

Printed on an Android 15 emulator:

tapped text=Network & internet at (407, 867)
BeforeAfter
Before: mobium tap &quot;text=Network &amp; internet&quot; on an Android 15 emulatorAfter: mobium tap &quot;text=Network &amp; internet&quot; on an Android 15 emulator

mobium tap "text=Network & internet" on an Android 15 emulator

Tap a ref from the last map​

mobium tap @e2

Tap right after work the screen does not show, with the gray box on​

mobium tap testid=busyRowB

Printed on an Android 15 emulator:

tapped testid=busyRowB at (540, 1095)
gray box: waited 307 ms for the app to go idle (busy: quiet)

mobium tap testid=busyRowB on MobiumApp&#39;s Busy Demo, Android 15 emulator, launched with --gray-box: the tap waited for the quiet refresh to finish, and Row B is the new generation&#39;s

mobium tap testid=busyRowB on MobiumApp's Busy Demo, Android 15 emulator, launched with --gray-box: the tap waited for the quiet refresh to finish, and Row B is the new generation's

More, from mobium tap --help​

mobium tap @e2 # tap the ref from the last map
mobium tap text="Sign In" # tap by visible text
mobium tap testid=submit_btn # tap by resource-id
mobium tap 540 1200 # tap raw device coordinates
mobium tap @e2 --fingers 2 # a two-finger tap

On a device​

BeforeAfter
Before: mobium double-tap testid=pressTarget on an Android 15 emulatorAfter: mobium double-tap testid=pressTarget on an Android 15 emulator

mobium double-tap testid=pressTarget on an Android 15 emulator

The tool​

tap calls app_tap; its arguments and what every client calls it are there.