Actions57
- 1. Manager Actions
- 2. Mouse Actions
- 3. Keyboard Actions
- 4. Browser Control Actions
- 5. Element Actions
- 6. Image Actions
- 7. Others Actions
- 8. Email Actions
- 9. Developer Actions
- 10. General Debug Actions
9. Developer → count_element
AI-generatedSummary
Publishes an MQTT request to count elements matching a target selector or XPath in a browser session. Provide the required topic and remote port, then optionally set a target and/or XPath; configure input item forwarding, response waiting, timeout, QoS, and delay as needed.
Inputs
- Topic (required) — MQTT topic used to route the request to a client.
- Remote Port (required) — CDP port used to route the command to the intended worker session; use the upstream profile node’s
remote_port, or127001for a local session. - Target — Optional selector for the elements to count. Supports prefixes such as
css=,id=, andtext=. - XPath — Optional XPath for the elements to count.
- QoS — MQTT delivery quality level, defaulting to 1 (at least once).
- Include Input Items — When enabled, attaches selected fields from incoming items to
payload.inputItems. - Include Input Fields — Comma-separated field paths to forward when input item inclusion is enabled; supports nested paths and array indexes.
- Wait For Response — When enabled, waits for an MQTT response before returning; defaults to false.
- Response Timeout (sec) — Maximum response wait when waiting is enabled; defaults to 60 seconds.
- Delay Next Step (ms) — Delay before continuing after publish, or after receiving the response when response waiting is enabled. Defaults to
rand(200,1000).
Output shape
A single output item containing the MQTT response when waiting is enabled; otherwise the operation publishes the request and continues without waiting for a response.
The properties identify the action as equivalent to Element → count_element and describe it as counting elements matched by selector/XPath. The exact response fields and count representation are not shown in the provided source view.
