Skip to main content
Glama

get-library-docs

get-library-docs

Fetch up-to-date library documentation and code examples to ensure development work uses current API references and conceptual guides.

Instructions

Fetches up-to-date documentation for a library. You must call 'resolve-library-id' first to obtain the exact Context7-compatible library ID required to use this tool, UNLESS the user explicitly provides a library ID in the format '/org/project' or '/org/project/version' in their query. Use mode='code' (default) for API references and code examples, or mode='info' for conceptual guides, narrative information, and architectural questions.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
context7CompatibleLibraryIDYes
modeNo
topicNo
pageNo
Behavior4/5

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

With no annotations provided, the description carries the full burden of behavioral disclosure. It effectively describes key behavioral traits: the prerequisite of calling 'resolve-library-id' first (unless specific ID format is provided), the two operational modes with their distinct purposes, and the fact that documentation is 'up-to-date.' It doesn't mention error handling, rate limits, or authentication requirements, but provides substantial operational context.

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?

The description is efficiently structured with two sentences that each serve distinct purposes: the first establishes the core functionality and prerequisites, the second explains the mode parameter usage. Every word contributes necessary information with zero wasted content.

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 tool with 4 parameters, 0% schema description coverage, no annotations, and no output schema, the description does an excellent job covering the most critical aspects: purpose, prerequisites, and key parameter usage. It doesn't explain the 'topic' or 'page' parameters or describe the return format, but provides sufficient context for basic usage given the complexity.

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?

With 0% schema description coverage, the description must compensate for the lack of parameter documentation. It provides meaningful context for two parameters: it explains the 'context7CompatibleLibraryID' parameter's relationship with the sibling tool and acceptable formats, and details the two possible values for 'mode' parameter and when to use each. It doesn't mention 'topic' or 'page' parameters, leaving some 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 clearly states the tool's purpose with specific verbs ('fetches up-to-date documentation for a library') and distinguishes it from its sibling 'resolve-library-id' by explaining the relationship between them. It specifies the exact resource being accessed.

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

Usage Guidelines5/5

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

The description provides explicit guidance on when to use this tool versus alternatives: it instructs to call 'resolve-library-id' first unless the user provides a specific library ID format, and distinguishes between two modes ('code' vs 'info') for different types of documentation needs. It clearly defines the prerequisites and alternatives.

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/xiaobenyang-com/context7-mcp'

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