Skip to main content
Glama

List DSH sessions

dsh_list_sessions
Read-onlyIdempotent

Lists persisted, resumable DSH root sessions newest first, with an optional absolute working-directory filter. Returns summary details and can show sessions still held by the desktop app.

Instructions

List persisted, resumable DSH root sessions from the ACP session/list method (newest first). Optional cwd filter must be an absolute path inside the allowed directories. Returns only sessionId/cwd/title/updatedAt summaries. WARNING: sessions held by the desktop app are also listed (ACP cannot see cross-process activity); visibility does not mean the session is free.

Input Schema

NameRequiredDescriptionDefault
cwdNoAbsolute working directory to filter by (realpath validated).
limitNoMaximum summaries to return.
cursorNoOpaque cursor from a previous nextCursor field.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A4.7/5.0
Behavior5/5

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

Annotations already declare readOnly/idempotent/non-destructive, and the description adds traits annotations cannot express: results come from ACP session/list, are ordered newest first, only root sessions are included, and cross-process activity is invisible to ACP so a listed session may be locked by the desktop app. That last warning is a genuinely non-obvious behavioral hazard an agent would otherwise get wrong.

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?

Four sentences, front-loaded with purpose, then filtering constraint, then return shape, then the capitalized warning. No filler, and the ordering places the operational caveat where it is most likely to be read before invocation.

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 read-only three-parameter list tool with no output schema, the description covers purpose, filtering constraint, ordering, returned fields (sessionId/cwd/title/updatedAt), and pagination via the schema's cursor. Nothing an agent needs to call it correctly or interpret results is missing.

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 100%, so the baseline is 3, but the description adds a constraint the schema does not state: cwd must be an absolute path inside the allowed directories (the schema only mentions realpath validation). It also clarifies that limit bounds 'summaries' rather than full session records.

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 and resource ("List persisted, resumable DSH root sessions") plus the underlying source (ACP session/list) and ordering (newest first). Against siblings like dsh_create_session and dsh_resume_session, there is no ambiguity about which tool enumerates 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?

The description establishes the context for calling it (enumerate persisted root sessions, optionally narrowed by cwd) and supplies a non-obvious caveat that governs how to act on results: listed sessions may be held by the desktop app, so visibility does not imply availability. It does not explicitly name a sibling or say 'call this before dsh_resume_session', so it falls short of full when/when-not routing.

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