Using the API
Browser Elements
Element types and parameters for browser interactions
Browser elements define the parameters that can be passed to browser interactions. Each element type serves a specific purpose in browser automation.
WebElement
Represents an element on the webpage with its description and coordinates.
Parameters
Natural language description of the element (e.g., “login button”, “email input field”)
X,Y coordinates of the element on the page
Example
Text
Represents text input for typing actions.
Parameters
The text to be typed into an element
Example
Duration
Represents a time duration for wait actions.
Parameters
Duration in seconds (can be fractional)
Example
ActionParam Type
ActionParam is a union type that can be any of the above parameter types:
This allows browser interactions to accept different parameter types depending on the action being performed:
- CLICK, SCROLL, HOVER actions require WebElement
- TYPE actions require Text
- WAIT actions require Duration