context7

Solid

Fetch up-to-date library/framework/API documentation from Context7, bypassing training-cutoff limits. Use when: (1) User asks how to use/configure/install a library, framework, or SDK, (2) Code examples or API reference needed for a specific package, (3) Version-specific behavior questions (e.g., "React 19", "Next.js 15"), (4) Any npm package, GitHub repo, or framework mention (React/Vue/Next/Prisma/Tailwind/Supabase/...). Triggers: "如何实现", "怎么写", "配置", "安装", "文档", "How do I", "Show me how", "generate code", library/framework names. Differentiator: Real-time authoritative docs via Context7 API, complements grok-search (real-time news) and exa (semantic web research) — use this for library/API specifics, not general web search.

Web & Frontend 64 stars 6 forks Updated yesterday MIT

Install

View on GitHub

Quality Score: 85/100

Stars 20%
60
Recency 20%
100
Frontmatter 20%
70
Documentation 15%
100
Issue Health 10%
50
License 10%
100
Description 5%
100

Skill Content

# Context7 Fetches current library/framework/API documentation from the Context7 API, so responses cite authoritative docs rather than potentially outdated training data. Standalone Node CLI only (no MCP dependency). ## Architecture: Two-Skill Split | Skill | Role | Context | Token Cost | |-------|------|---------|------------| | **context7** (this file) | Intent detection, library selection, response integration | Full conversation | Higher | | [context7-fetcher](context7-fetcher.md) | Pure API calls (`search` / `context`) | `context: fork` (isolated) | Lower | The main skill never calls the API directly. It delegates each HTTP call to `context7-fetcher` via the Task tool so the forked subagent executes without carrying conversation history. The fetcher's contract is defined in [`context7-fetcher.md`](context7-fetcher.md). ### Call Flow ``` User Query → context7 (detect trigger + extract library) ↓ Task(context7-fetcher) → search <library> <query> → JSON libraries[] context7 (select best match: name / trustScore / version) ↓ Task(context7-fetcher) → context <libraryId> <query> → JSON results[] context7 (integrate relevant snippets into answer) ``` ## Implementation Layout - `context7-api.cjs` - Node CLI entrypoint (HTTPS client, .env + env-var API key, MSYS path fix) - `context7-fetcher.md` - Sub-skill definition (forked context, API executor) - `.env.example` - API key template (copy to `.env`) ## Execution Method ```bash # Prerequisites: Node.js 18+ (no...

Details

Author
Dianel555
Repository
Dianel555/DSkills
Created
6 months ago
Last Updated
yesterday
Language
Python
License
MIT

Integrates with

Bundled in these plugins

Similar Skills

Semantically similar based on skill content — not just same category