Installation
fetch API). Zero runtime dependencies.
Quick Start
Configuration
execute() method always uses a 120-second timeout, regardless of the client timeout.
Method Reference
Desktop CRUD
| Method | Returns | Description |
|---|---|---|
createDesktop(desktopType?) | Promise<Desktop> | Create a new desktop ("sandbox" by default) |
listDesktops() | Promise<Desktop[]> | List all active desktops |
getDesktop(desktopId) | Promise<Desktop> | Get a single desktop by ID |
updateDesktop(desktopId, { name }) | Promise<Desktop> | Rename a desktop |
deleteDesktop(desktopId) | Promise<DeleteResponse> | Delete a desktop |
Computer-Use Helpers
Typed shortcuts — no need to know the wire format:| Method | Description |
|---|---|
screenshot(desktopId) | Take a screenshot |
leftClick(desktopId, x, y) | Left click at coordinate |
rightClick(desktopId, x, y) | Right click at coordinate |
doubleClick(desktopId, x, y) | Double click at coordinate |
middleClick(desktopId, x, y) | Middle click at coordinate |
mouseMove(desktopId, x, y) | Move cursor to coordinate |
typeText(desktopId, text) | Type text |
keyPress(desktopId, key) | Press a key or combo (e.g. "ctrl+a") |
scroll(desktopId, x, y, { direction, amount? }) | Scroll at coordinate |
cursorPosition(desktopId) | Get current cursor position |
Tool Execution
| Method | Returns | Description |
|---|---|---|
execute(desktopId, { tool, action, params? }) | Promise<ExecuteResult> | Execute any tool action (raw) |
listTools(desktopId) | Promise<ToolSchema[]> | List available tools as JSON Schema |
getToolLogs(desktopId) | Promise<unknown[]> | Get tool execution logs |
Sessions
| Method | Returns | Description |
|---|---|---|
createSession(desktopId) | Promise<SessionInfo> | Create or reconnect an RDP session |
getSession(desktopId) | Promise<SessionInfo> | Get current session status |
deleteSession(desktopId) | Promise<void> | Disconnect the session |
Error Handling
All API errors throwNenDesktopError, which carries statusCode and responseBody:
e.statusCode to differentiate (401, 404, 409, 5xx).