Skip to main content
Glama
congzhou09

chrome-dev-mcp

get_console_logs

Read-only

Retrieve browser console messages and uncaught exceptions, including pre-existing entries and new output, with stack traces for errors. Filter by log level or limit to diagnose runtime issues.

Instructions

Return browser console messages and uncaught exceptions. Includes messages already visible in DevTools before this server connected, plus new output produced afterwards. Exceptions are reported with their full stack trace (source-mapped when available).

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
levelNoFilter by log level / type. Omit to return all levels.
limitNoMaximum number of most-recent entries to return

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
logsYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changedv1.4.0
    • removedInput schema / properties / clear
      Removed value: -{
      -  "default": false,
      -  "description": "Clear the buffer after returning entries",
      -  "type": "boolean"
      -}
  2. Changed1 schema field changedv1.3.0
    • changedOutput schema / (root)
      Previous value: -nullNew value: +{
      +  "$schema": "http://json-schema.org/draft-07/schema#",
      +  "additionalProperties": false,
      +  "properties": {
      +    "logs": {
      +      "items": {
      +        "additionalProperties": false,
      +        "properties": {
      +          "stackTrace": {
      +            "items": {
      +              "additionalProperties": false,
      +              "properties": {
      +                "columnNumber": {
      +                  "type": "number"
      +                },
      +                "functionName": {
      +                  "type": "string"
      +                },
      +                "lineNumber": {
      +                  "type": "number"
      +                },
      +                "url": {
      +                  "type": "string"
      +                }
      +              },
      +              "required": [
      +                "functionName",
      +                "url",
      +                "lineNumber",
      +                "columnNumber"
      +              ],
      +              "type": "object"
      +            },
      +            "type": "array"
      +          },
      +          "text": {
      +            "type": "string"
      +          },
      +          "timestamp": {
      +            "type": "string"
      +          },
      +          "type": {
      +            "type": "string"
      +          }
      +        },
      +        "required": [
      +          "timestamp",
      +          "type",
      +          "text"
      +        ],
      +        "type": "object"
      +      },
      +      "type": "array"
      +    }
      +  },
      +  "required": [
      +    "logs"
      +  ],
      +  "type": "object"
      +}
  3. First observedv1.1.0

TDQS

A4/5.0
Behavior4/5

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

Annotations already declare readOnlyHint=true, so the read-only nature is covered. The description adds meaningful behavioral context beyond that: it reports that messages from before the server connection are included and that exceptions include source-mapped stack traces when available. This enriches the agent's understanding of what to expect from the call.

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 three sentences with zero redundancy. The primary purpose is front-loaded, followed by scope and behavior details. Every sentence earns its place, making it easy for an agent to parse quickly.

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?

With an output schema present, the return format is already specified. The description covers the main behavioral aspects (inclusion of pre-existing messages, stack traces) and the parameters are well-documented in the schema. It could optionally mention that results are limited to most-recent entries, but that is already implied by the schema's 'limit' description, so no critical information is missing.

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%, with both parameters (level and limit) fully documented in the schema. The description adds no extra parameter-specific information, so it does not improve on the schema's baseline. A score of 3 is appropriate given the high coverage.

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 opens with a specific verb and resource ('Return browser console messages and uncaught exceptions'), clearly distinguishing it from network or debugger tools. It further specifies the scope (including pre-existing messages) and stack trace details, making the tool's function unambiguous even without reading the schema.

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 explains what the tool returns and the inclusion of pre-existing messages, giving implicit context for when it is useful, but it never explicitly states when to use this tool over alternatives (e.g., get_network_requests) or when not to use it. No exclusions or comparisons are provided.

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