Skip to main content
Glama

Close a WSL session

wsl_disconnect
Idempotent

Close a WSL session opened with wsl_connect to clear the server's tracked working directory while leaving the distro unchanged.

Instructions

Close a session opened with wsl_connect. Nothing in the distro is affected — only this server's memory of the working directory.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
sessionYesSession id from wsl_connect.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.0.2

TDQS

A4.3/5.0
Behavior4/5

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

Annotations already declare non-destructive and idempotent behavior. The description goes further by scoping the effect precisely — only the server's memory of the working directory is cleared, nothing in the distro changes — which is exactly the reassurance an agent needs before calling a teardown tool.

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 short sentences, effect statement first, safety clarification second. Zero filler and nothing to trim.

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?

For a one-parameter teardown tool with full annotation coverage and no output schema, the description supplies everything needed: what it closes, where the id comes from, and that no distro state is touched.

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 single 'session' parameter is documented as coming from wsl_connect. The description adds no syntax or format detail beyond the schema, so baseline 3 applies.

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 ('Close a session') and ties it to the originating tool 'wsl_connect', which separates it cleanly from sibling lifecycle tools like wsl_connect and wsl_list_sessions.

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?

By naming wsl_connect as the source of the session, it implicitly defines the correct usage context (teardown of a session you opened). It does not state any when-not conditions, but for a paired lifecycle tool that's a minor gap.

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