Skip to main content
Glama

navigate

Directs a browser to a specific webpage for automation tasks, enabling LLM-powered clients to control web navigation.

Instructions

Navigate to a URL

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
urlYes
page_idNo

Implementation Reference

  • The handler logic for the 'navigate' tool within the handle_call_tool function. It retrieves the URL from arguments, gets the active page, navigates to the URL using page.goto, and returns a success message.
    if name == "navigate":
        url = arguments.get("url")
        if not url:
            raise ValueError("URL is required")
            
        page = get_active_page(arguments.get("page_id"))
        await page.goto(url)
        return [types.TextContent(type="text", text=f"Navigated to {url}")]
  • Registration of the 'navigate' tool in the list_tools handler, including its name, description, and input schema.
    types.Tool(
        name="navigate",
        description="Navigate to a URL",
        inputSchema={
            "type": "object",
            "properties": {
                "url": {"type": "string"},
                "page_id": {"type": "string"},
            },
            "required": ["url"],
        },
    ),
  • Helper function used by the 'navigate' handler to retrieve the active browser page based on page_id or current default.
    def get_active_page(page_id: Optional[str] = None) -> Page:
        """Get the active page based on page_id or current default."""
        global current_page_id
        
        if page_id is None:
            page_id = current_page_id
        
        if page_id not in pages:
            raise ValueError(f"Page not found: {page_id}")
        
        return pages[page_id]
Behavior1/5

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

With no annotations provided, the description carries the full burden of behavioral disclosure. 'Navigate to a URL' gives minimal information - it doesn't specify what happens after navigation (does it wait for page load?), whether it returns anything, what errors might occur, or any side effects. For a navigation tool with zero annotation coverage, this is inadequate behavioral transparency.

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

Conciseness5/5

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

The description is maximally concise at just 4 words. It's front-loaded with the core action and contains zero wasted words. While it may be too brief for adequate tool understanding, it achieves perfect conciseness within its limited scope.

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

Completeness1/5

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

Given a navigation tool with 2 parameters, no annotations, no output schema, and 0% schema description coverage, the description is completely inadequate. It doesn't explain what the tool returns, how it behaves, what the parameters mean, or how it differs from sibling tools. For a potentially complex navigation operation, this minimal description leaves critical gaps.

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

Parameters2/5

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

With 0% schema description coverage for 2 parameters, the description provides no information about what 'url' or 'page_id' mean, their formats, or their relationship. The description mentions 'URL' which aligns with one parameter name, but doesn't explain the 'page_id' parameter at all. The description fails to compensate for the complete lack of schema documentation.

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

Purpose3/5

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

The description 'Navigate to a URL' clearly states the action (navigate) and target (URL), providing a basic purpose. However, it's vague about scope - it doesn't specify whether this is browser navigation, application navigation, or something else. It also doesn't distinguish from siblings like 'switch_page' which might serve similar navigation functions.

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?

The description provides no guidance on when to use this tool versus alternatives. With siblings like 'switch_page', 'get_pages', and 'new_page' that might relate to navigation or page management, there's no indication of when 'navigate' is appropriate versus these other tools. No context about prerequisites or typical use cases is provided.

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/misanthropic-ai/playwrite-mcp'

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