Skip to main content
Glama

safari_verify_state

Verifies that an editor's internal framework state matches expected value before submitting forms. Prevents submission of stale data from modern UI frameworks.

Instructions

Verify the framework-level state of an editor/input matches the expected value. Returns JSON {match, mode, actual, expected, hint?}. Modern editors (ProseMirror, Lexical, Closure, React-controlled inputs) maintain state separately from the DOM — .value or .textContent may show new text while the internal store still holds old data, so a Submit click sends stale data. Call this AFTER safari_fill and BEFORE clicking Submit on critical forms (Featured.com, LinkedIn share, Medium, Reddit).

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
receiptNoTab receipt from safari_new_tab — pins this call to that tab (survives reconnects/subagents)
expectedYesExpected value or text fragment that should appear in framework state
selectorYesCSS selector of the editor/input to verify

Schema Changelog

Changes observed during successful MCP inspections. Dates show when Glama detected each change.

  1. Changed1 schema field changedv2.18.1
    • addedInput schema / properties / receipt
      Added value: +{
      +  "description": "Tab receipt from safari_new_tab — pins this call to that tab (survives reconnects/subagents)",
      +  "type": "string"
      +}
  2. Addedv2.11.6
  3. Removedv2.11.3
  4. Addedv2.10.9
  5. Removedv2.10.8
  6. Addedv2.10.5
  7. Removedv2.10.4
  8. Addedv2.1.7

TDQS

A4.3/5.0
Behavior4/5

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

With no annotations, the description carries the full burden. It discloses the return JSON structure ({match, mode, actual, expected, hint?}) and the rationale for the tool's existence. It does not explicitly state that it is read-only, but the nature of 'verify' implies it. It also doesn't describe failure behavior or edge cases, but the provided rationale is substantial.

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 slightly long but every sentence serves a purpose: it states the action, explains the underlying problem, gives the return type, and provides usage timing. It front-loads the core purpose and then adds context. It is efficient, though the list of editor types could be trimmed without losing meaning.

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 complexity and the absence of an output schema, the description adequately explains what the tool does, why it is needed, and when to call it. It mentions the return format, the problem with modern editors, and the workflow context. It does not cover error handling or what happens if the selector is invalid, but these are minor for a verification tool.

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 coverage is 100% — each parameter has a clear description ('CSS selector of the editor/input to verify', 'Expected value or text fragment', 'Tab receipt from safari_new_tab'). The tool description adds no additional parameter-specific meaning beyond what the schema already provides, so a baseline 3 is appropriate.

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 states a specific verb ('Verify') and resource ('framework-level state of an editor/input'), with a precise scope ('matches the expected value'). It distinguishes itself from DOM-reading tools by explaining the divergence between internal state and DOM, and names the exact return format. This clearly separates it from siblings like safari_read_page or safari_get_element.

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

Usage Guidelines5/5

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

The description gives explicit timing ('AFTER safari_fill and BEFORE clicking Submit') and identifies critical contexts (Featured.com, LinkedIn share, Medium, Reddit). It implicitly tells when not to use it (non-critical forms) and explains why the DOM check is insufficient, making the decision boundary clear.

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/achiya-automation/safari-mcp'

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