Skip to main content
Glama

Search the knowledge base

searchDocuments
Read-onlyIdempotent

Search the workspace's indexed documents for relevant content. Use whenever the question is about something the workspace has written down.

Input Schema

NameRequiredDescriptionDefault
queryYesNatural-language search query
maxResultsNoMaximum number of chunks to return
workspaceIdNoThe workspace, as listWorkspaces gives it (its id or slug). Leave it out when this connection reaches one workspace.

Output Schema

NameRequiredDescriptionDefault
countYes
chunksYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A3.8/5.0
Behavior3/5

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

The annotations already declare readOnly, idempotent, non-destructive and closed-world behavior, so the safety profile is fully covered. The description adds only that searches run against indexed content and return 'relevant' results, without saying whether ranking is semantic or keyword-based, how chunks relate to documents, or what happens when nothing matches. A 3 is appropriate against an already-rich annotation set.

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 sentences with zero filler: the first states what is searched, the second states when to reach for it. The usage trigger is front-loaded and nothing repeats the title or schema.

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?

With an output schema for return values and annotations covering the safety profile, the description needs to carry little. It is nearly complete, but for a search tool among listDocuments and readDocument siblings a sentence on when to prefer those alternatives would close the remaining gap.

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 100%, so all three parameters (query, maxResults, workspaceId) are already documented, including the workspaceId fallback for single-workspace connections. The description adds no parameter-level detail beyond the schema, which is the baseline 3.

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 description gives a specific verb (search) and resource (the workspace's indexed documents) and adds scope ('relevant content'). It is clearly distinct from listDocuments and readDocument in practice, but it never names a sibling, so it stops short of a 5.

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?

'Use whenever the question is about something the workspace has written down' gives a concrete triggering condition, which is genuinely useful. It offers no exclusions or alternatives, though – it never says to use readDocument when you already know the document id, or listDocuments to enumerate everything.

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

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.

Resources