Skip to main content
Glama

Search sessions

search_sessions
Read-onlyIdempotent

Find prior agent sessions by keyword to recover earlier prompts, reviews, or file-changing tasks. Provide agent and query, optionally set a result limit.

Instructions

Search an agent's past sessions by keyword.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
agentYesAgent name from list_agents, e.g. 'codex' or 'claude'.
limitNo
queryYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv1.2.2

TDQS

C2.7/5.0
Behavior2/5

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

Annotations already declare readOnlyHint, idempotentHint, openWorldHint=false, and destructiveHint=false, covering the safety profile. The description adds almost no behavioral context beyond the basic operation—it does not describe matching behavior, result limits, pagination, or what a session search covers.

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 front-loaded sentence with no wasted words. It is efficient, though its extreme brevity leaves important details unstated for a 3-parameter tool.

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?

With no output schema, annotations covering mostly safety, and only 33% schema description coverage, the description is too incomplete. It omits usage guidance, parameter details for limit and query, and any return or pagination context.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters2/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is only 33%, so the description must compensate but does not. It vaguely maps 'agent's past sessions' to agent and 'keyword' to query, but says nothing about the limit parameter, its default, its maximum of 100, or how query matching works.

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 (Search) and resource (an agent's past sessions) with the keyword filter. It is clear what the tool does, but it does not distinguish itself from the sibling list_sessions or explain how keyword search differs from listing sessions.

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?

There is no guidance on when to use this tool versus list_sessions, get_transcript, or other siblings. The description implies a keyword-search use case but provides no conditions, prerequisites, or exclusions.

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