一键导入
docs-context7
Query up-to-date library documentation via Context7 MCP. Use when needing current docs, code examples, or API references for any library or framework.
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
菜单
Query up-to-date library documentation via Context7 MCP. Use when needing current docs, code examples, or API references for any library or framework.
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
基于 SOC 职业分类
Git commit message conventions and pre-commit guidance. Use when committing code.
Analyze memory files for generally applicable learnings and extract them to AGENTS.md, skills, or other permanent locations. Use when reviewing accumulated corrections and decisions for broader applicability.
Report autonomous decisions made during the current session. Use when the user asks what decisions were made, wants a decision audit, asks about choices, trade-offs, or alternatives the agent picked without asking.
Browser debugging and visual verification using Playwright CLI. Use when needing to take screenshots, verify a page loads correctly, debug visual issues, check localhost web apps, or inspect UI rendered by dev servers.
Capture corrections, decisions, or learnings to persistent agent memory files
Pre-commit review checklist to verify code quality before committing
| name | docs-context7 |
| description | Query up-to-date library documentation via Context7 MCP. Use when needing current docs, code examples, or API references for any library or framework. |
Context7 provides up-to-date documentation and code examples for libraries and frameworks. When working with fast changing libraries always use this skill instead of relying on potentially stale training data.
bun add -d mcporter) or available via npx.env.local for higher rate limits. Without a key, calls are rate-limited.npx mcporter call 'context7.resolve-library-id(query: "react useEffect cleanup", libraryName: "react")'
Both parameters are required:
libraryName — the package/library name to search forquery — your actual question or task; Context7 uses this to rank results by relevanceUse specific, descriptive queries for better ranking. query: "react" returns generic results; query: "react useEffect cleanup" returns results weighted toward that topic.
The response lists matching libraries with their Context7-compatible IDs (format: /org/project). Pick the best match.
npx mcporter call 'context7.query-docs(libraryId: "/websites/react_dev", query: "react useEffect cleanup")'
Both parameters are required:
libraryId — the ID from step 1 (e.g., /websites/react_dev)query — a specific question; be detailed for better resultsReturns documentation snippets with code examples and source links.
# Resolve + query in sequence (same query threads through both steps)
npx mcporter call 'context7.resolve-library-id(query: "zod parse vs safeParse", libraryName: "zod")' && \
npx mcporter call 'context7.query-docs(libraryId: "/colinhacks/zod", query: "zod parse vs safeParse")'
resolve-library-id and query-docs (not get-library-docs)query parameter alongside the primary identifierGET /api/v2/libs/search and GET /api/v2/context — see context7.com/docs/api-guideThe scripts/ subfolder contains reference TypeScript code using mcporter's programmatic API:
scripts/context7-client.ts — Reusable client: resolve libraries, query docs, extract headlinesscripts/context7-docs.ts — CLI demo: bun .agents/skills/docs-context7/scripts/context7-docs.ts [library] [query]These scripts require mcporter to be installed (bun add -d mcporter).