Actions45
- Manager Actions
- Mouse Actions
- Keyboard Actions
- Browser Control Actions
- Element Actions
- Image Actions
- Others Actions
- Email Actions
- Developer Actions
- General Debug Actions
Mouse → mouse_scroll_top
AI-generatedSummary
Publish an MQTT message to instruct the connected mouse interface to scroll the view to the top position over a specified duration.
Inputs
- Topic (required) — The MQTT topic to which the scroll command will be published, e.g., 'playwright/mouse/scroll'.
- QoS — Quality of Service level for MQTT message delivery: 0 (at most once), 1 (at least once), or 2 (exactly once). Defaults to 1.
- Include Input Items — Boolean indicating whether to include selected fields from the node's input items in the MQTT message payload under 'inputItems'.
- Include Input Items Fields — Comma- or newline-separated list of fields from the input items to include in the payload if including input items is enabled.
- Wait For Response — Boolean to wait for a response message from the MQTT broker before the node outputs data.
- Response Topic (required) — MQTT topic to subscribe to and listen for response messages if waiting for a response; defaults to 'RES_' plus the main topic.
- Response Timeout (ms) — Maximum time in milliseconds to wait for a response message before timing out; defaults to 10000 ms.
- Parse Response As JSON — Boolean indicating whether to parse the response payload as JSON if a response is received.
- Duration (ms) — Optional expected duration in milliseconds for the initial scroll action to the top; subsequent adjustments are computed automatically.
Output shape
a list of output items, each containing the original input data augmented with MQTT action details and optionally the response data received from the MQTT broker if 'Wait For Response' is enabled.
The MQTT message payload includes the action key 'mouse.mouse_scroll_top' with inputs containing optional 'duration_ms' and included input item fields if specified. If waiting for response is enabled, the node subscribes to the specified response topic and outputs the response payload. On errors (e.g., MQTT publish failure or timeout), the node throws an error unless 'Continue On Fail' is enabled.
Examples
Example 1: Scroll the mouse view to the top over 800 milliseconds by publishing to topic 'playwright/mouse/scroll'.
Set 'Topic' to 'playwright/mouse/scroll', QoS to 1, optionally specify 'Duration (ms)' as 800, and disable 'Wait For Response' if immediate output is acceptable.
Example 2: Scroll to top and wait for response to confirm the action.
Enable 'Wait For Response', specify 'Response Topic' (or accept default 'RES_playwright/mouse/scroll'), set 'Duration (ms)' as needed, ensuring the node waits for and parses response data before outputting.