Skip to main content
Glama
FutureAtoms

Agentic Control Framework (ACF)

by FutureAtoms

browser_console_messages

Access browser console messages to debug web applications and track runtime logs in real time.

Instructions

browser console messages

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Implementation Reference

  • The core handler function that retrieves console messages from the browser page. It initializes a console message listener on the page (if not already set up) and returns all captured console messages with their type, text, location, and timestamp.
    async function browserConsoleMessages() {
      try {
        const page = await getPage();
        
        // Set up console message collection if not already done
        if (!page._consoleMessages) {
          page._consoleMessages = [];
          page.on('console', msg => {
            page._consoleMessages.push({
              type: msg.type(),
              text: msg.text(),
              location: msg.location(),
              timestamp: new Date().toISOString()
            });
          });
        }
    
        return {
          success: true,
          messages: page._consoleMessages || [],
          count: (page._consoleMessages || []).length
        };
    
      } catch (error) {
        logger.error(`Error getting console messages: ${error.message}`);
        return {
          success: false,
          message: error.message
        };
      }
    }
  • Tool registration: 'browser_console_messages' is listed in the browserExtras array (line 129) and gets a generated description. Also appears in the tools/call switch case (line 286) where it calls browserTools.browserConsoleMessages().
    const browserExtras = [
      { n:'browser_navigate_back' }, { n:'browser_navigate_forward' }, { n:'browser_hover' }, { n:'browser_drag' },
      { n:'browser_select_option' }, { n:'browser_press_key' }, { n:'browser_snapshot' }, { n:'browser_console_messages' },
      { n:'browser_network_requests' }, { n:'browser_tab_list' }, { n:'browser_tab_new' }, { n:'browser_tab_select' },
      { n:'browser_tab_close' }, { n:'browser_file_upload' }, { n:'browser_wait' }, { n:'browser_wait_for' },
      { n:'browser_resize' }, { n:'browser_handle_dialog' }
    ];
    for (const b of browserExtras) {
      tools.push({ name: b.n, description: b.n.replace(/_/g,' '), inputSchema: { type:'object', properties:{} } });
    }
  • The input schema for 'browser_console_messages' is an empty object (no parameters required), as generated by the loop on line 135 for all browserExtras tools.
    for (const b of browserExtras) {
      tools.push({ name: b.n, description: b.n.replace(/_/g,' '), inputSchema: { type:'object', properties:{} } });
    }
  • The getPage() helper function used by browserConsoleMessages to obtain the current browser page instance.
    async function getPage() {
      if (!page || page.isClosed()) {
        const browser = await getBrowser();
        if (!context) {
          context = await browser.newContext();
        }
        page = await context.newPage();
      }
      return page;
    }
Behavior1/5

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

No annotations are provided, and the description offers zero behavioral details. It does not disclose whether the tool is read-only, destructive, requires authentication, or has side effects. For a tool that likely interacts with browser state, this omission is critical.

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

Conciseness2/5

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

While extremely short, the description is under-specified rather than concise. It contains only a single noun phrase, wasting the opportunity to provide essential context. An effective description could be brief but informative.

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?

Given the simplicity of the tool (no parameters, no output schema), a minimal description might suffice, but 'browser console messages' is insufficient. It fails to explain what the tool does (e.g., fetch logs, display errors) or how results are presented. Sibling tools with more descriptive names compound the need for clarity.

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?

There are no parameters, and the schema coverage is 100%. Per the rubric, the baseline is 3 even without parameter info. The description adds no parameter meaning, but none is needed. However, it fails to explain what the tool returns or how it behaves.

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

Purpose2/5

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

The description merely repeats the tool name, lacking a verb or specific action. It vaguely indicates the domain (browser console messages) but does not clarify what operation is performed (e.g., retrieve, clear, monitor). Compared to siblings like 'browser_network_requests' which imply retrieval, this tool's purpose is ambiguous.

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 alternatives (e.g., browser_snapshot, browser_network_requests). No context about typical scenarios or constraints, leaving the agent to infer usage without support.

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/FutureAtoms/agentic-control-framework'

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