Skip to main content
Glama

browser_scroll_to_bottom

Scroll to the bottom of a webpage to load dynamic content or access elements at the end of the page during browser automation.

Instructions

Scroll to the bottom of the page

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Implementation Reference

  • MCP tool registration and handler for 'browser_scroll_to_bottom'. Creates an ActionService instance and calls its scrollToBottom method, with standard try-catch error handling returning markdown content.
    server.tool('browser_scroll_to_bottom', 'Scroll to the bottom of the page', {}, async () => { try { const driver = stateManager.getDriver(); const actionService = new ActionService(driver); await actionService.scrollToBottom(); return { content: [{ type: 'text', text: `Scrolled to bottom of the page` }], }; } catch (e) { return { content: [ { type: 'text', text: `Error scrolling to bottom: ${(e as Error).message}`, }, ], }; } });
  • Core implementation of scrolling to the bottom of the page using Selenium WebDriver's executeScript to run 'window.scrollTo(0, document.body.scrollHeight)'. Called by the tool handler.
    async scrollToBottom(): Promise<void> { await this.driver.executeScript('window.scrollTo(0, document.body.scrollHeight);'); }
  • Top-level registration call for action tools, including browser_scroll_to_bottom, in the tools index file.
    registerActionTools(server, stateManager);

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/pshivapr/selenium-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server