context7-mcp
v1.0.1MCP server for Context7
These tools were reported by the server itself during our smoke test (tools/list), not copied from the README.
resolve-library-id Resolve Context7 Library ID
Resolves a package/product name to a Context7-compatible library ID and returns a list of matching libraries. You MUST call this function before 'get-library-docs' to obtain a valid Context7-compatible library ID UNLESS the user explicitly provides a library ID in the format '/org/project' or '/org/project/version' in their query. Selection Process: 1. Analyze the query to understand what library/package the user is looking for 2. Return the most relevant match based on: - Name similarity to the query (exact matches prioritized) - Description relevance to the query's intent - Documentation c…
| Parameter | Type | Description |
|---|---|---|
libraryName * | string | Library name to search for and retrieve a Context7-compatible library ID. |
get-library-docs Get Library Docs
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.
| Parameter | Type | Description |
|---|---|---|
context7CompatibleLibraryID * | string | Exact Context7-compatible library ID (e.g., '/mongodb/docs', '/vercel/next.js', '/supabase/supabase', '/vercel/next.js/v14.3.0-canary.87') retrieved from 'resolve-library-id' or directly from user que… |
tokens | number | Maximum number of tokens of documentation to retrieve (default: 5000). Higher values provide more context but consume more tokens. |
topic | string | Topic to focus documentation on (e.g., 'hooks', 'routing'). |