Skip to main content
Glama

puppeteer_navigate

Direct a real browser to a specified URL on a Linux display server, enabling web interaction, screenshots, and JavaScript execution for browser automation tasks.

Instructions

Navigate to a URL

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
urlYes

Implementation Reference

  • Handler implementation for the 'puppeteer_navigate' tool. Navigates the Puppeteer-controlled page to the specified URL and returns a confirmation message.
    case "puppeteer_navigate": await page.goto(args.url); return { content: [{ type: "text", text: `Navigated to ${args.url}`, }], isError: false, };
  • Input schema definition for the 'puppeteer_navigate' tool, specifying an object with a required 'url' string property.
    inputSchema: { type: "object", properties: { url: { type: "string" }, }, required: ["url"], },
  • index.ts:103-113 (registration)
    Registration of the 'puppeteer_navigate' tool in the TOOLS array, including name, description, and schema.
    { name: "puppeteer_navigate", description: "Navigate to a URL", inputSchema: { type: "object", properties: { url: { type: "string" }, }, required: ["url"], }, },
  • index.ts:448-449 (registration)
    Registration via the ListToolsRequestSchema handler that returns the TOOLS array containing puppeteer_navigate.
    tools: TOOLS, }));
  • Helper function to initialize and ensure the Puppeteer browser and page instance is ready, called before tool execution.
    async function ensureBrowser() { if (!browser) { browser = await puppeteer.launch({ headless: false, env: processEnvironment // Pass the X11 environment variables }); const pages = await browser.pages(); page = pages[0]; page.on("console", (msg) => { const logEntry = `[${msg.type()}] ${msg.text()}`; consoleLogs.push(logEntry); server.notification({ method: "notifications/resources/updated", params: { uri: "console://logs" }, }); }); } return page; }

Other Tools

Related 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/PhialsBasement/MCP-Puppeteer-Linux'

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