Scrolls through the page

Options:

OptionRequiredDescriptionExample
totrue(string) The point up to where the scrolling to be done. Possible Values : bottom | componentcomponent
querySelectorfalse(string) Query selector of the element to be scrolled up to. Required if "to" is set to "component"div.main-container
speedfalse(string) Speed at which the scroll to be done (helps to simulate real user) . Possible Values : slow | medium | fastmedium
withInfalse(string) Query selector of the parent element to be scrolled within. Default Value bodybody
scrollForfalse(number) Number of milliseconds to scroll for.5000

Example 1: Scroll the page to bottom in medium speed for 5s

{
  "action": "scroll",
  "options": {
    "to": "bottom",
    "speed": "medium",
    "scrollFor": 5000
  }
}

Example 2: Scroll the page up to a given element

{
  "action": "scroll",
  "options": {
    "to": "component",
    "querySelector": "div.main-container"
  }
}

Example 3: Scroll the page with in a given parent element

{
  "action": "scroll",
  "options": {
    "to": "bottom",
    "withIn": "div.main-container"
  }
}