Skip to main content
Glama

google_dialog

Accept or dismiss JavaScript browser dialogs such as alert, confirm, prompt, and beforeunload by setting accept to true or false, with optional prompt text and tab targeting.

Instructions

处理页面 JS 弹窗(alert/confirm/prompt/beforeunload):accept=true 确定,false 取消。

Tool call template

This tool declares no required parameters. Add optional parameters from the input schema as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {},
    "name": "google_dialog"
  }
}

Input Schema

NameRequiredDescriptionDefault
acceptNo
tab_idNo
wait_msNo
prompt_textNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

C2.7/5.0
Behavior2/5

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

No annotations are provided, so the description carries the full burden of disclosure. It reveals only the semantics of accept (confirm versus cancel) and the dialog types; it says nothing about blocking or waiting behavior, what wait_ms governs, which dialogs require text, or whether the call fails when no dialog is present. For a tool that interacts with modal browser state, this leaves the agent guessing at runtime behavior.

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 a single compact sentence that puts the resource first and the accept semantics immediately after, so there is no wasted wording. Its brevity is efficient, though it does not offset the missing detail elsewhere; the structure itself is sound.

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?

With four parameters at 0% schema coverage, no annotations, and no output schema, this tool's definition needs to be considerably richer to be callable with confidence. It covers the purpose and the accept flag but omits the parameters and the behavior that matter most for a dialog handler. It is therefore incomplete relative to the tool's complexity.

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?

Schema description coverage is 0% across four parameters, so the description must compensate. It explains only accept's meaning (true = confirm, false = cancel) and is silent on prompt_text (presumably the answer typed into prompt dialogs), wait_ms (presumably a timeout for the dialog to appear), and tab_id (which tab to act on). Three of the four parameters are therefore undocumented in both the schema and the description.

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 gives a specific verb and resource: handle page JS dialogs, and enumerates the four dialog types (alert/confirm/prompt/beforeunload) so the agent knows exactly what page event this tool addresses. No sibling tool in the catalog covers dialog handling, so differentiation is implicit but unambiguous. It stops short of a 5 only because it does not state scope limits, such as whether this tool applies across tabs or only to the active tab.

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?

It states what the tool does, but it gives no explicit guidance on when to call it: whether the agent should invoke it proactively before a dialog blocks the page, only after detecting one, or what happens if no dialog is pending. It names no alternatives and no timing or ordering constraints, so the agent must infer the invocation context entirely.

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