Skip to main content
Glama
yinnho

AginxBrowser

session_dialog

Inspect or change how browser session dialogs (alert/confirm/prompt) are answered. Dialogs auto-dismiss by default, log to console; list policy, accept to return text, or dismiss.

Instructions

Inspect or flip the session's dialog policy for window.alert/confirm/prompt. Dialogs never block the page: each is auto-answered (default dismiss) and logged into session_console at level "dialog". action "list" reports {policy, prompt_text, dialogs}; "accept" makes subsequent confirm() true and prompt() return prompt_text (or the call's default argument); "dismiss" restores the default.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
actionYes"list" reports the policy and dialog history; "accept"/"dismiss" set the answer applied to subsequent window.confirm/prompt calls (alert is always logged, never blocking).
session_idYesSession ID
prompt_textNoWith action "accept": text window.prompt returns once accepted (omitted keeps the current text).

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changedv0.5.1
    • removedInput schema / title
      Removed value: -"SessionDialogParams"
  2. Addedv0.3.0

TDQS

A4.6/5.0
Behavior5/5

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

With minimal annotations (only title), the description carries the full burden. It discloses that dialogs never block the page, are auto-answered with default dismiss, and are logged to session_console at level 'dialog'. It also details the exact behavioral changes for 'accept' and 'dismiss' actions, including how prompt() returns prompt_text.

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?

Two well-structured sentences pack all necessary information with zero fluff. The purpose is front-loaded, and behavioral details follow logically. Every clause earns its place.

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?

The description covers the tool's purpose, all actions, the non-blocking behavior, logging, and the return structure for 'list'. While it doesn't detail error handling or the exact contents of 'dialogs', the provided information is sufficient for an agent to call the tool correctly given the lack of output schema.

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?

Schema description coverage is 100%, so the baseline is 3. The description adds meaningful context by explaining how 'action' values behave and how 'prompt_text' interacts with the 'accept' action. This goes beyond the schema's terse descriptions, justifying a slightly higher score.

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 a specific verb (inspect or flip) and resource (the session's dialog policy for window.alert/confirm/prompt). It distinguishes itself from siblings by focusing solely on dialogs, which no other sibling handles.

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

Usage Guidelines4/5

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

The description explains the three actions and their effects, making it clear when to use this tool (to inspect or change dialog policy). It doesn't explicitly mention alternatives because none exist, but it does refer to session_console for logging, which provides context without contradicting usage.

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