Skip to main content
Glama

safari_handle_dialog

Configure handling for the next Safari alert, confirm, or prompt dialog by choosing to accept or dismiss it, and supply text for prompt inputs before the dialog appears.

Instructions

Set up handler for the next alert/confirm/prompt dialog

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": "safari_handle_dialog"
  }
}

Input Schema

NameRequiredDescriptionDefault
textNoText to enter for prompt dialogs
actionNoAccept or dismiss (default: accept)
receiptNoOmit it: Daylight has no tab receipts and refuses a call that passes one

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

B3.1/5.0
Behavior2/5

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

With no annotations, the description carries the full behavioral burden. It omits critical traits: whether the handler persists after one dialog or only fires once (despite 'next'), what happens if no dialog appears, the timeout behavior, and that merely registering a handler changes Safari's default auto-dismiss handling. These are exactly the facts an agent needs to avoid hangs or unintended dismissals.

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?

A single front-loaded sentence with zero filler, so nothing is wasted. Its brevity is clean but borders on under-specification given the stateful behavior left unexplained.

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?

For a stateful handler with no annotations and no output schema, the definition is too thin. It should specify handler scope (one dialog vs. persistent), interaction with default auto-dismiss behavior, and whether 'text' is required for prompt dialogs and ignored otherwise.

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%, so the schema already documents 'text', the 'action' enum and default 'accept', and the unusual 'receipt' constraint. The description adds nothing about parameter meaning, which is the acceptable baseline when the schema does the work.

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 ('set up handler') and a specific resource type ('alert/confirm/prompt dialog'), which is enough for an agent to identify this as the dialog-handling tool. It does not name or contrast itself with any sibling, though no sibling in the supplied list is dialog-related, so ambiguity is low.

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?

'For the next ... dialog' implies a one-shot handler that must be registered before the triggering action, which is useful implicit ordering guidance. It never states explicitly when to call it relative to the click/evaluate that opens the dialog, nor what to do if a dialog is already open, leaving the sequencing to inference.

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

Deploy Server

Other Tools