Skip to main content
Glama

Close a browser session

writ_browser_cancel
DestructiveIdempotent

Close an open browser session to stop execution time consumption. Auto-saves unsaved work as a workflow unless discard=true.

Instructions

Close an open browser session. Call this when the task is done and the user does not want to reuse it, or when abandoning a session — an open cloud browser keeps consuming execution time until it is closed. Work you never saved is NOT lost: a session with defined functions, or a recording that did more than visit pages, is auto-saved as a workflow first (the reply names it; inactive draft when it would not replay). Pass discard=true to close without keeping anything. A session bound to a build is settled by that auto-save, or marked cancelled.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
discardNotrue = throw the session's unsaved steps and functions away instead of auto-saving them. Default false.
session_idYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv1.1.0

TDQS

A4.3/5.0
Behavior5/5

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

Annotations already flag destructiveHint=true and idempotentHint=true, and the description goes well beyond them: unsaved work is auto-saved as a workflow first, the reply names it, it may be an inactive draft if it would not replay, and build-bound sessions are settled or marked cancelled. This is exactly the mutation-side effect an agent could not infer from structured fields.

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?

Three dense sentences, front-loaded with the action and reason, and each clause adds real information (auto-save, discard, build-bound handling). Slightly compressed in the final sentence, but nothing is padding.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

No output schema exists, yet the description still explains what the reply contains (the workflow name) and how the session is finalized. For a destructive, non-idempotent-looking close operation with no annotation-level detail on data retention, this is complete.

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 coverage is 50%: discard is documented in the schema and the description reinforces it meaningfully ('Pass discard=true to close without keeping anything', default false). session_id is undocumented in both, but its meaning is unambiguous. The description adds the consequence of discard that the schema only hints at.

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?

States a specific verb and resource — 'Close an open browser session' — with clear scope (session is not being reused, or is being abandoned). An agent can distinguish it from session-management siblings, though no sibling is named to draw an explicit contrast.

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?

Gives concrete when-to-use conditions: task finished and no reuse intended, or abandoning a session, with the rationale that an open cloud browser keeps consuming execution time. It does not name an alternative tool for cases where the user does want to keep going, so context is clear but exclusion logic is left implicit.

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