Skip to main content
POST
/
v1
/
browsers
/
{id}
/
scroll-to
Scroll To
curl --request POST \
  --url https://api.example.com/v1/browsers/{id}/scroll-to/ \
  --header 'Content-Type: application/json' \
  --data '
{
  "selector": "<string>",
  "x": 123,
  "y": 123
}
'
{
  "success": true
}

Description

Scrolls the page to bring a specific element or position into view.

Authentication

Authorization: Bearer YOUR_API_KEY

Path Parameters

id
string
required
UUID of the browser.

Request Body

selector
string
CSS selector of the element to scroll into view.
x
number
Absolute horizontal scroll position in pixels.
y
number
Absolute vertical scroll position in pixels.

Response

success
boolean
Whether the scroll was performed successfully.

Example

curl -X POST https://api.rustybrowser.com/v1/browsers/550e8400-e29b-41d4-a716-446655440000/scroll-to/ \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{ "selector": "#footer" }'