Skip to main content
Glama

list_sessions

Find coding agent sessions across Claude Code, Codex, Copilot, Cursor, Gemini, Grok, and OpenCode. Filter by working directory, agent, branch, or text query, with live agents listed first.

Instructions

List Claude Code, Codex, Copilot, Cursor, Gemini, Grok, and OpenCode sessions. Live agents first.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
cwdNoWorking directory to match (canonical or prefix)
agentNoclaude, codex, copilot, cursor, gemini, grok, or opencode
limitNo
queryNo
branchNoGit branch name
live_onlyNo
include_archivedNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.11.0

TDQS

C2.9/5.0
Behavior2/5

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

No annotations are provided, so the description must carry the burden of behavioral disclosure. It does not reveal that sessions come from seven different tools, which is implied by the list, nor does it disclose ordering, filtering semantics, or what 'live' means (e.g., active processes vs. recent). It does not mention whether archived sessions are excluded by default, which is a key behavioral detail. The description gives some context via agent names but falls short of the needed transparency.

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?

The description is a single sentence of about 15 words, which is efficient and to the point. It front-loads the resource type and includes a meaningful ordering note. There is no waste, but it omits essential details that would make it more useful, so while concise, it is not a model of completeness.

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

Completeness2/5

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

The tool lists sessions across seven tools with seven parameters nine of which are undocumented (43% coverage). There is no output schema, so the agent must rely on the description to know what the response contains. The description does not describe the output format, how to handle pagination (limit), or what 'live' implies. For a list operation with significant filter parameters)Skip, as in previous, this is inadequate.

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 description coverage is only 43% (3 of 7 parameters have no description: limit, query, live_only, include_archived). The description does not explain any parameter semantics, so it does not compensate for the uncovered parameters. For the parameters that are described, the schema already provides adequate descriptions, so the description adds no value beyond schema. Baseline is 3 because schema covers a significant portion, but the 43% coverage is a gap that the definition should address.

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?

The definition names a specific verb ('List') and a clear resource ('sessions') across seven named tools, and adds a scope qualifier ('Live agents first'). It is more specific than a mere restatement of the tool name. However, it does not explicitly distinguish itself from closely related siblings like 'get_session' or 'session_digest', so the purpose is clear but lacks differentiation.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description says 'List ... sessions' which implies it is for discovery, but gives no explicit when-to-use guidance or conditions that would route an agent to an alternative, such as 'get_session' for a single session or 'session_digest' for a summary. The phrase 'Live agents first' hints at a default ordering but not when to use the live_only filter. With siblings present assuredly, the definition is strongly lacking.

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