Connect a desktop
SetOFFSTAGE_API_KEY in the environment that runs the helper. Install the SDK and download the helper in the same directory.
Try it with a computer-use agent
Give the agent the sandbox ID and this task:Tested with OpenAI Codex
In a fresh Codex session, we opened a TextEdit document containing a random code. Codex read the code from a screenshot, clicked into the document, replaced its contents and pressed Command-S. We then read the saved file through the SDK and verified its contents byte for byte.Desktop commands
Take a screenshot before choosing coordinates and after each action whose result matters. A successful input command means the desktop accepted the event. Inspect the screen or read the saved file to verify what the app did. Screenshots stay in the reported temporary directory on your computer.
Use the input API directly
The helper is a thin wrapper over the SDK. Take a screenshot, read coordinates from it, and send input in its pixels with its size asscreen:
move, click (with button, count and modifiers), drag, scroll, type, key and wait, performed in order. Over HTTP it is POST /v1/sandboxes/:id/input (reference), and Claude Code’s offstage plugin offers it as offstage_sandbox_input.
GUI sandboxes record by default. For work that needs recording off, create the GUI sandbox with the SDK’s record: false option and give the helper its ID. Close the sandbox when finished. If you need the files again, capture a snapshot before closing.