ComputerBox API is Python and Node; other SDKs drive the desktop through low-level exec.
Quick Example
The minimal flow: start the desktop, wait until ready, then take a screenshot and save it locally. The code is ready to copy and run.Python
Node
Parameters & Returns
Constructor parameters
PythonComputerBox(...) (keyword arguments):
Node
new ComputerBox(options?) (ComputerBoxOptions):
The image is fixed tolscr.io/linuxserver/webtop:ubuntu-xfce, and the display resolution is fixed to1024x768(DISPLAY=:1). These are set by environment variables injected by the SDK and are not changed via constructor parameters.
GUI automation methods (Python / Node equivalents)
screenshot() return fields
Watching the desktop live in a browser
The desktop ports are mapped to the host (default HTTP3000 / HTTPS 3001). After the box starts, open https://localhost:3001 (or http://localhost:3000) in a browser to see the live desktop.
HTTPS uses a self-signed certificate, so the browser will show a security warning: click “Advanced” then “Proceed” to continue.
Full automation example (screenshot, click, type)
Troubleshooting
Feeding screenshots to a vision model (computer-use loop)
The base64 PNG returned byscreenshot() can be passed directly as image input to a model that supports computer-use. The actions the model emits (click coordinates, text to type, keys to press) are then mapped back to the mouse_move / left_click / type / key methods above, forming a “look at the screen, decide, act, look again” loop. The coordinate origin is the top-left corner, and the range matches the value returned by get_screen_size().
