Press a hardware/system key
devilge_input_keySend Android key events such as BACK, HOME, or VOLUME_UP to a device via ADB. Use for UI automation and testing.
Instructions
Sends a key event (adb shell input keyevent KEYCODE_<NAME>). Allowed keys: BACK, HOME, MENU, APP_SWITCH, POWER, ENTER, TAB, DEL, FORWARD_DEL, ESCAPE, DPAD_UP, DPAD_DOWN, DPAD_LEFT, DPAD_RIGHT, DPAD_CENTER, VOLUME_UP, VOLUME_DOWN, VOLUME_MUTE, PAGE_UP, PAGE_DOWN, MOVE_HOME, MOVE_END, SEARCH.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| code | Yes | Hardware/system key to press. Mapped internally to KEYCODE_<NAME>. | |
| serial | No | Device serial. Defaults to DEVILGE_DEFAULT_DEVICE_SERIAL or the only attached device. |