Skip to main content
Glama
docs-mcp-server

docs-mcp-server

search_docs

Read-only

Search documentation for a library or package by query, optionally limiting results to a specific version or version range.

Instructions

Search up-to-date documentation for a library or package. Examples:

  • {library: "react", query: "hooks lifecycle"} -> matches latest version of React

  • {library: "react", version: "18.0.0", query: "hooks lifecycle"} -> matches React 18.0.0 or earlier

  • {library: "typescript", version: "5.x", query: "ReturnType example"} -> any TypeScript 5.x.x version

  • {library: "typescript", version: "5.2.x", query: "ReturnType example"} -> any TypeScript 5.2.x version

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "library": "<library>",
      "query": "<query>"
    },
    "name": "search_docs"
  }
}

Input Schema

NameRequiredDescriptionDefault
limitNoMaximum number of results.
queryYesDocumentation search query.
libraryYesLibrary name.
versionNoLibrary version (exact or X-Range, optional).

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv3.4.1

TDQS

A3.7/5.0
Behavior3/5

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

Annotations already declare readOnlyHint=true and destructiveHint=false, so the safety profile is covered. The description adds only the 'up-to-date' framing and version-resolution behavior; it says nothing about result format, rate limits, or whether unpinned searches hit the network versus a cache.

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?

Purpose is front-loaded in a single sentence followed by a scannable example list. The four examples are slightly redundant — the React pair and TypeScript pair each cover the same point — but none is outright waste.

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

Completeness3/5

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

With four parameters and no output schema, an agent still cannot tell what a result looks like (page titles, URLs, snippets) or what an empty search yields. Version semantics are well covered, so the remaining gap is moderate rather than critical.

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 would be 3, but the four examples genuinely extend the schema's terse 'exact or X-Range' note by showing that a pinned version matches that version or earlier and that X-ranges (5.x, 5.2.x) are accepted. The limit parameter is left entirely to the schema.

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 opening sentence names a specific verb and resource ('Search ... documentation for a library or package') and adds the 'up-to-date' qualifier. It is clearly distinguishable from siblings like scrape_docs or read_page, but it never explicitly contrasts itself with them.

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 worked examples make clear when to omit version (latest) versus when to pin it, and how a version narrows results — that is practical when-to-use context. There is no explicit exclusion or 'use X instead' guidance, so it falls short of a 5.

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