Overview
launch
Launch application and wait for window
close-app
Quit application gracefully or force kill
list-windows
List all visible windows (filter by app)
list-apps
List all running GUI applications
focus-window
Bring window to front
resize-window
Resize application window
move-window
Move window to new position
minimize
Minimize application window
maximize
Maximize or zoom application window
restore
Restore minimized or maximized window
Common Patterns
Launch Application
Launch by Bundle ID
Quit Application
Force Quit Application
SIGKILL — immediate termination, no save prompts.
List Running Applications
List All Windows
List Windows for Specific App
Focus Window
Resize Window
Move Window
Minimize Window
Maximize Window
Restore Window
Examples
Use Cases
App Lifecycle Management
App Lifecycle Management
Launch apps, configure them, then quit:
Multi-App Workflows
Multi-App Workflows
Orchestrate tasks across multiple applications:
Window Layout Automation
Window Layout Automation
Arrange windows for optimal workflow:
Clean Up Background Apps
Clean Up Background Apps
Close unused applications to free resources:
Window Identification
Windows are identified by:window-id(e.g.,w-4521) — unique per window, obtained fromlist-windowsorlaunch--app <NAME>— filter to application name--title <TITLE>— filter by window title (partial match)
Error Handling
Common error codes:APP_NOT_FOUND: Application not running or has no windowsWINDOW_NOT_FOUND: No window matched the filterACTION_FAILED: OS rejected the window operationTIMEOUT: App didn’t launch within timeout period