Of the 8 Window methods, browser sessions serve 0, phone sessions 0 and computer sessions 8. A method marked not served answers StrategyUnavailable on that kind of session; check the handshake’s capabilities before relying on one.

Window.list

Browser: not served Phone: not served Computer: served The desktop’s top-level windows as the taskbar lists them (visible, titled, not tool windows), front to back. Computer sessions only.
{"id": 1, "method": "Window.list", "params": {}}
ParamTypeRequiredDescription
idempotencyKeystringNoMakes a re-send after a reconnect safe: a repeated key returns the recorded response without acting again. See Idempotency keys.
Result
FieldTypeDescription
windowsWindowInfo[]

Window.focus

Browser: not served Phone: not served Computer: served Bring a window to the front with the keyboard focus, restoring it first if it is minimized. Computer sessions only.
{"id": 1, "method": "Window.focus", "params": {"windowId": "<windowId>"}}
ParamTypeRequiredDescription
windowIdstringYes
idempotencyKeystringNoMakes a re-send after a reconnect safe: a repeated key returns the recorded response without acting again. See Idempotency keys.
Result
FieldTypeDescription
windowWindowInfoThe window after the action; absent once it no longer exists.

Window.setBounds

Browser: not served Phone: not served Computer: served Move and resize a window’s visible frame in screen pixels; an omitted field keeps its value, and a maximized window is restored first. Computer sessions only.
{"id": 1, "method": "Window.setBounds", "params": {"windowId": "<windowId>"}}
ParamTypeRequiredDescription
windowIdstringYes
xintegerNo
yintegerNo
widthintegerNo
heightintegerNo
idempotencyKeystringNoMakes a re-send after a reconnect safe: a repeated key returns the recorded response without acting again. See Idempotency keys.
Result
FieldTypeDescription
windowWindowInfoThe window after the action; absent once it no longer exists.

Window.minimize

Browser: not served Phone: not served Computer: served Minimize a window. Computer sessions only.
{"id": 1, "method": "Window.minimize", "params": {"windowId": "<windowId>"}}
ParamTypeRequiredDescription
windowIdstringYes
idempotencyKeystringNoMakes a re-send after a reconnect safe: a repeated key returns the recorded response without acting again. See Idempotency keys.
Result
FieldTypeDescription
windowWindowInfoThe window after the action; absent once it no longer exists.

Window.maximize

Browser: not served Phone: not served Computer: served Maximize a window. Computer sessions only.
{"id": 1, "method": "Window.maximize", "params": {"windowId": "<windowId>"}}
ParamTypeRequiredDescription
windowIdstringYes
idempotencyKeystringNoMakes a re-send after a reconnect safe: a repeated key returns the recorded response without acting again. See Idempotency keys.
Result
FieldTypeDescription
windowWindowInfoThe window after the action; absent once it no longer exists.

Window.restore

Browser: not served Phone: not served Computer: served Restore a minimized or maximized window to its normal size. Computer sessions only.
{"id": 1, "method": "Window.restore", "params": {"windowId": "<windowId>"}}
ParamTypeRequiredDescription
windowIdstringYes
idempotencyKeystringNoMakes a re-send after a reconnect safe: a repeated key returns the recorded response without acting again. See Idempotency keys.
Result
FieldTypeDescription
windowWindowInfoThe window after the action; absent once it no longer exists.

Window.close

Browser: not served Phone: not served Computer: served Ask a window to close, as its close button does. The result has no window once it has closed; a window that asks first (unsaved changes) stays open. Computer sessions only.
{"id": 1, "method": "Window.close", "params": {"windowId": "<windowId>"}}
ParamTypeRequiredDescription
windowIdstringYes
idempotencyKeystringNoMakes a re-send after a reconnect safe: a repeated key returns the recorded response without acting again. See Idempotency keys.
Result
FieldTypeDescription
windowWindowInfoThe window after the action; absent once it no longer exists.

Window.waitFor

Browser: not served Phone: not served Computer: served Wait until a window whose title contains title (case-insensitive) and, when given, whose process is process exists, and return it. Running out of timeoutMs (default 5000, at most 60000) is ActionTimeout. Computer sessions only.
{"id": 1, "method": "Window.waitFor", "params": {}}
ParamTypeRequiredDescription
titlestringNoPart of the title, case-insensitive.
processstringNoThe image name, such as notepad.exe.
timeoutMsintegerNoFrom 0 to 60000.
Result
FieldTypeDescription
windowWindowInfoThe window after the action; absent once it no longer exists.