browser_scroll_by
Browser Scroll By
Scroll the page by a specified number of pixels vertically and/or horizontally. Positive Y scrolls down, negative scrolls up. Use for incremental scrolling to load lazy content or navigate long pages.
Usage Example
123456789101112
import asyncio
from owl_browser import OwlBrowser, RemoteConfig
# Async usage
async with OwlBrowser(config) as browser:
context = await browser.create_context()
context_id = context["context_id"]
await browser.scroll_by(
context_id=context_id,
y="value"
)
Parameters
Required
context_idstringrequiredThe unique identifier of the browser context (e.g., 'ctx_000001')
ystringrequiredVertical scroll amount in pixels. Positive values scroll down, negative values scroll up. Typical values: 300-500 for one viewport scroll
Optional
xstringHorizontal scroll amount in pixels. Positive values scroll right, negative scroll left. Default: 0 (no horizontal scroll)
verification_levelstringVerification level for scroll action. Options: 'none' (no verification), 'basic', 'standard', 'strict'. Higher levels verify scroll position after scrolling. Default: 'none'
Response
Returns a JSON object with the operation result.
{
"success": true,
"result": <value>
}