Skip to main content
Glama

dsh_find_sessions

Read-onlyIdempotent

Find existing root sessions by exact title or substring, exact workspace path, or idle state, returning exact session ID and attach-precondition fields before connecting.

Instructions

Read bounded metadata for existing root sessions from DSH session.list. It can filter titles exactly or by a case-sensitive substring, or narrow candidates by an exact canonical cwd, an unambiguous BridgeTask mapping, or idle state; it returns no history or raw projections. These filters narrow candidates but never authorize automatic selection, history reads, attachment, or prompting. Use the returned exact sessionId and precondition fields with dsh_attach_session; never select a session by title alone.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
cwdNoOptional absolute existing workspace path; matches only sessions whose advertised cwd resolves to the same canonical directory.
titleNo
idleOnlyNoReturn only sessions whose root turn is not running.
mappedOnlyNoReturn only sessions with one unambiguous existing BridgeTask mapping.
maxResultsNo
titleMatchNoexact
includeBlankNo
Behavior5/5

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

Annotations already declare read-only, idempotent, non-destructive behavior, and the description adds valuable limits beyond annotations: it returns no history/raw projections, filters never authorize automatic selection or attachment, and results are limited to bounded metadata. This gives an agent a precise behavioral contract.

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?

Three tight sentences, front-loaded with the core operation and followed by filter semantics and a critical usage warning. Every sentence earns its place; there is no redundant filler.

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?

For a 7-parameter tool with no output schema and only 43% schema description coverage, the description covers the main purpose, key filters, return usage, and boundary behavior. It omits maxResults and includeBlank semantics, so it is not fully complete, but it is notably stronger than the median 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?

The description maps four semantic filters to parameters: exact/case-sensitive title matching (title/titleMatch), canonical cwd (cwd), idle state (idleOnly), and BridgeTask mapping (mappedOnly). However, schema coverage is only 43%, and maxResults and the opaque includeBlank are never explained. The description partially compensates but leaves real gaps.

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 opens with a specific verb and resource: 'Read bounded metadata for existing root sessions from DSH session.list.' It then lists the exact filter dimensions and states what the tool does not return ('no history or raw projections'), which clearly separates it from session-history and attach-type siblings.

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?

It gives an explicit downstream directive: use the returned exact sessionId and precondition fields with dsh_attach_session, and never select a session by title alone. It does not fully enumerate when to prefer this tool over every sibling, but it gives strong context on how to consume the result.

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/Fly2Kiana/Codex-DSH-Orchestrator'

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