Skip to main content
Glama

browser_navigate

Navigate to a specified URL with optional timeout and wait criteria. Use this tool to direct the browser to a web page for subsequent interaction.

Instructions

Navigate to a specific URL

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
urlYesURL to navigate to
timeoutNoNavigation timeout in milliseconds
waitUntilNoNavigation wait criteria

Implementation Reference

  • The actual handler function that executes the browser_navigate tool logic. Uses Playwright's page.goto() to navigate to a URL with configurable timeout and waitUntil options.
    async function handleBrowserNavigate(page: Page, args: any): Promise<{ toolResult: CallToolResult }> {
      try {
        await page.goto(args.url, {
          timeout: args.timeout || 30000,
          waitUntil: args.waitUntil || "load"
        });
        return {
          toolResult: {
            content: [{
              type: "text",
              text: `Navigated to ${args.url}`,
            }],
            isError: false,
          },
        };
      } catch (error) {
        return {
          toolResult: {
            content: [{
              type: "text",
              text: `Navigation failed: ${(error as Error).message}`,
            }],
            isError: true,
          },
        };
      }
    }
  • The input schema definition for browser_navigate. Defines the tool's name, description, and input schema with properties: url (required string), timeout (optional number), and waitUntil (optional string with enum values).
    {
      name: "browser_navigate",
      description: "Navigate to a specific URL",
      inputSchema: {
        type: "object",
        properties: {
          url: { type: "string", description: "URL to navigate to" },
          timeout: { type: "number", description: "Navigation timeout in milliseconds" },
          waitUntil: { 
            type: "string", 
            description: "Navigation wait criteria",
            enum: ["load", "domcontentloaded", "networkidle", "commit"]
          }
        },
        required: ["url"]
      }
    },
  • The switch-case dispatch in executeToolCall() that routes the 'browser_navigate' tool name to the handleBrowserNavigate handler function.
    case "browser_navigate":
      return await handleBrowserNavigate(activePage!, args);
  • src/tools.ts:3-12 (registration)
    The BROWSER_TOOLS constant list that includes 'browser_navigate' as one of the registered browser tool names.
    export const BROWSER_TOOLS = [
      "browser_navigate",
      "browser_screenshot",
      "browser_click",
      "browser_fill",
      "browser_select",
      "browser_hover",
      "browser_evaluate",
      "browser_set_viewport"
    ];
Behavior2/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

No annotations are provided, and the description does not disclose behavioral traits such as whether navigation replaces the current page, how timeouts affect behavior, or what happens on failure. The parameters timeout and waitUntil are defined in the schema but not mentioned in the description.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is extremely concise with no unnecessary words. However, it could be slightly expanded to include key behavioral details without losing conciseness, but as is, it is efficient and to the point.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness2/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a tool with 3 parameters (one with enum), sibling tools, and no output schema, the description is too brief. It does not cover return values, error handling, or when to use timeout/waitUntil. The agent receiving this description would need to rely entirely on the schema for context.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 100%, so the description does not need to add much. The description itself adds no parameter information beyond the schema, but given full coverage, a baseline score of 3 is appropriate.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states the action of navigating to a URL, which is the primary purpose. However, it does not differentiate from sibling browser tools like browser_click or browser_fill, but the verb 'navigate' and parameter 'url' make it unambiguous.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

No guidance on when to use this tool versus other browser actions such as browser_click or browser_fill. The description lacks context for appropriate usage scenarios or prerequisites like requiring a current page.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

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/imprvhub/mcp-browser-agent'

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