Skip to main content
Glama

list_console_messages

Read-only

Retrieve console messages from the current page to monitor JavaScript errors, warnings, and logs for debugging and analysis.

Instructions

List all console messages for the currently selected page since the last navigation.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Implementation Reference

  • The tool handler function that instructs the response to include console data.
    handler: async (_request, response) => {
      response.setIncludeConsoleData(true);
    },
  • Empty schema indicating no input parameters required.
    schema: {},
  • Tool registration using defineTool, exporting as consoleTool.
    export const consoleTool = defineTool({
      name: 'list_console_messages',
      description:
        'List all console messages for the currently selected page since the last navigation.',
      annotations: {
        category: ToolCategories.DEBUGGING,
        readOnlyHint: true,
      },
      schema: {},
      handler: async (_request, response) => {
        response.setIncludeConsoleData(true);
      },
    });
Behavior4/5

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

Annotations provide readOnlyHint=true, indicating a safe read operation. The description adds valuable context beyond annotations by specifying the temporal scope ('since the last navigation') and that it applies to the 'currently selected page', which helps the agent understand behavioral constraints not covered by annotations alone.

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 a single, well-structured sentence that efficiently conveys the tool's purpose and scope without any redundant information. It is front-loaded with the core action and resource, making it highly concise and effective.

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

Completeness4/5

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

Given the tool's simplicity (0 parameters, read-only operation, no output schema), the description is mostly complete. It covers the action, resource, and scope adequately. However, it lacks details on output format or potential limitations, which could be helpful but is not critical for this low-complexity tool.

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

Parameters4/5

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

With 0 parameters and 100% schema description coverage, the schema fully documents the input (none required). The description adds no parameter information, which is appropriate here, but does not compensate for any gaps since there are none. Baseline is 4 for zero parameters, as the description need not cover parameters.

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

Purpose5/5

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

The description clearly states the specific action ('List all console messages') and resource ('for the currently selected page'), distinguishing it from siblings like list_network_requests or list_pages. It specifies the scope ('since the last navigation'), making the purpose unambiguous and distinct.

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

Usage Guidelines3/5

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

The description implies usage context by mentioning 'currently selected page' and 'since the last navigation', suggesting it should be used after page navigation. However, it does not explicitly state when to use this tool versus alternatives or provide any exclusions, leaving some ambiguity for the agent.

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/SHAY5555-gif/chrome-devtools-mcp'

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