Skip to main content
Glama

scroll_up

Scroll up web pages by pixel amounts or full pages to navigate content in Steel MCP Server's browser automation.

Instructions

Scroll up the page by a pixel amount - if no pixels are specified, scrolls up one page

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
pixelsNoThe number of pixels to scroll up. If not specified, scrolls up one page.

Implementation Reference

  • The handler function for the scroll_up tool. It scrolls up the page by the specified pixels or one page using PageUp if not specified.
    async function handleScrollUp(page: Page, args: any): Promise<CallToolResult> {
      const { pixels } = args;
      if (pixels !== undefined) {
        await page.evaluate((scrollAmount) => {
          window.scrollBy(0, -scrollAmount);
        }, pixels);
      } else {
        await page.keyboard.press("PageUp");
      }
    
      return {
        isError: false,
        content: [{ type: "text", text: `Scrolled up by ${pixels ?? "one page"}` }],
      };
    }
  • The input schema and metadata definition for the scroll_up tool, including name, description, and inputSchema.
    {
      name: "scroll_up",
      description:
        "Scroll up the page by a pixel amount - if no pixels are specified, scrolls up one page",
      inputSchema: {
        type: "object",
        properties: {
          pixels: {
            type: "integer",
            description:
              "The number of pixels to scroll up. If not specified, scrolls up one page.",
          },
        },
        required: [],
      },
    },
  • src/index.ts:931-932 (registration)
    The switch case in handleToolCall that registers and dispatches to the scroll_up handler.
    case "scroll_up":
      result = await handleScrollUp(page, args);

Tool Definition Quality

Score is being calculated. Check back soon.

Install Server

Other Tools

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/steel-dev/steel-mcp-server'

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