Skip to main content
Glama
helmif

semantic-dom-mcp

by helmif

session_open

Open a persistent browser session at a staging URL for multi-step flows (login, cart, checkout), keeping the page open across action and extraction calls until closed.

Instructions

Open a persistent browser session at a staging URL for a MULTI-STEP flow (login → cart → checkout). The page stays open across calls: use session_act to perform declared actions and session_extract to snapshot or diff, then session_close. Fresh context per session (storageState applied if configured). Sessions expire after an idle TTL and are capped in number; the allowlist is re-checked after every step.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
urlYesThe page to extract. Must be http/https and on an allowlisted host.
viewportNoViewport preset — 'mobile' is 375x812 with touch, for responsive states.desktop
wait_forNoNavigation wait. 'auto' (default) waits for load, then until the DOM has been quiet for 500ms (max 6s) — works on SPAs that render after load and on pages whose analytics never let the network go idle. 'networkidle' times out on such pages.auto
wait_selectorNoOptional selector to await before extracting (for SPA content).

Schema Changelog

Changes observed during successful MCP inspections.

  1. Addedv0.8.0

TDQS

A4.4/5.0
Behavior4/5

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

Annotations declare openWorldHint=false, readOnlyHint=false, non-idempotent, non-destructive. The description adds substantial context beyond that: persistent-across-calls page, fresh context per session with storageState applied if configured, idle-TTL expiry, session count cap, and allowlist re-check after every step. These are non-obvious operational constraints an agent must know, though the description doesn't cover reset/cleanup semantics explicitly.

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?

Front-loads purpose, then the lifecycle (open → act → extract → close), then operational constraints. Every sentence carries a distinct fact; no filler or repetition.

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?

Covers the lifecycle, state model (fresh context, storageState), lifecycle limits (TTL, cap), and security re-check — enough to call correctly without an output schema. Minor gaps remain (does the description note what session_open returns, e.g., a session id, and what triggers immediate expiration?), but for a tool with full schema coverage this is strong.

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%, and the schema already documents url, viewport, wait_for, and wait_selector with rich enum semantics. The description adds little parameter-level meaning (URL must be staging, allowlisted is echoed by schema), so baseline 3 is appropriate when the schema does the heavy lifting.

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?

States a specific verb+resource (open a persistent browser session) with an explicit scope constraint (staging URL, MULTI-STEP flow). Clearly distinguishes itself from sibling session_act/session_extract/session_close by naming them as the follow-on workflow.

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 when-to-use ('MULTI-STEP flow') and names the exact alternatives to chain (session_act to act, session_extract to snapshot/diff, then session_close). It also implies the boundary: this is the entry point of a multi-step session rather than a one-shot extract.

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