con un clic
context7-auto-research
// Use this skill when users need current documentation, setup steps, API references, or code examples for a named library, framework, SDK, or API. It fetches up-to-date Context7 docs.
// Use this skill when users need current documentation, setup steps, API references, or code examples for a named library, framework, SDK, or API. It fetches up-to-date Context7 docs.
Generate and edit images with gpt-image-2 through a third-party OpenAI-compatible API using .env-configured OPENAI_API_KEY and OPENAI_BASE_URL values. Use when the user asks to create images, edit reference images, create visual assets, illustrations, or image variations with a configurable API endpoint.
Use this skill when users ask for code review, review pending changes, or inspect the latest commit with Codex-based review workflows. It prepares context, runs project linting, and reviews the result.
Use this skill when users need semantic web search, similar-page discovery, result content retrieval, research-paper lookup, GitHub discovery, or structured Exa-powered research.
Use this skill when users need to scrape web pages, extract structured page data, take website screenshots, parse PDFs, batch-scrape URLs, or crawl a site with Firecrawl.
Use this skill when users need current web research, source discovery, URL content extraction, site mapping, crawling, or structured Tavily-powered research.
| name | context7-auto-research |
| description | Use this skill when users need current documentation, setup steps, API references, or code examples for a named library, framework, SDK, or API. It fetches up-to-date Context7 docs. |
| license | MIT |
| compatibility | Designed for Claude Code; requires Node.js and network access to the Context7 API. |
| metadata | {"author":"BenedictKing","version":"1.0.2","user-invocable":"true"} |
| allowed-tools | Bash Read |
This skill automatically fetches current documentation from Context7 API when detecting library/framework-related queries, ensuring responses use up-to-date information instead of potentially outdated training data.
This skill should activate proactively when the user's message contains:
When triggered, follow this workflow:
Identify the library/framework from the user's query:
Use Task tool to call context7-fetcher sub-skill:
Task parameters:
- subagent_type: Bash
- description: "Search Context7 for library"
- prompt: node scripts/context7-api.cjs search "<library-name>" "<user-query>"
Example:
Task: Search for Next.js
Prompt: node scripts/context7-api.cjs search "next.js" "How to configure middleware in Next.js 15"
Response format:
{
"libraries": [
{
"id": "/vercel/next.js",
"name": "Next.js",
"description": "The React Framework",
"trustScore": 95,
"versions": ["v15.1.8", "v14.2.0", "v13.5.0"]
}
]
}
Why use Task tool?
context: fork from context7-fetcher sub-skillFrom search results, choose the library based on:
Use Task tool to call context7-fetcher sub-skill:
Task parameters:
- subagent_type: Bash
- description: "Fetch documentation from Context7"
- prompt: node scripts/context7-api.cjs context "<library-id>" "<specific-query>"
Example:
Task: Fetch Next.js middleware docs
Prompt: node scripts/context7-api.cjs context "/vercel/next.js" "middleware configuration"
Response format:
{
"results": [
{
"title": "Middleware",
"content": "Middleware allows you to run code before a request is completed...",
"source": "docs/app/building-your-application/routing/middleware.md",
"relevance": 0.95
}
]
}
Why use Task tool?
Use the fetched documentation to:
The scripts/context7-api.cjs script provides two commands:
node scripts/context7-api.cjs search <libraryName> <query>
node scripts/context7-api.cjs context <libraryId> <query>
The script supports two ways to configure the API key:
Create a .env file in the skill directory:
# In .env
CONTEXT7_API_KEY=your_api_key_here
You can copy from the example:
cp .env.example .env
# Then edit .env with your actual API key
export CONTEXT7_API_KEY="your-api-key"
Priority: Environment variable > .env file
Get API Key: Visit context7.com/dashboard to register and obtain your API key.
If not set, the API will use public rate limits (lower quota).
/vercel/next.js/v15.1.8 instead of /vercel/next.jsUser: "How do I use useEffect to fetch data in React 19?"
Skill Actions:
node scripts/context7-api.cjs search "react" "useEffect fetch data"/facebook/react/v19.0.0 (version match)node scripts/context7-api.cjs context "/facebook/react/v19.0.0" "useEffect data fetching"use() hook if applicable)User: "配置 Next.js 15 的中间件"
Skill Actions:
node scripts/context7-api.cjs search "next.js" "middleware configuration"/vercel/next.js/v15.1.8node scripts/context7-api.cjs context "/vercel/next.js/v15.1.8" "middleware"User: "Show me how to define one-to-many relations in Prisma"
Skill Actions:
node scripts/context7-api.cjs search "prisma" "one-to-many relations"/prisma/prisma (highest trust score)node scripts/context7-api.cjs context "/prisma/prisma" "one-to-many relations"This skill adopts a two-phase architecture:
Main Skill (context7-auto-research) - Needs conversation context:
Sub-Skill (context7-fetcher) - Independent context (context: fork):
| Aspect | Main Skill | Sub-Skill |
|---|---|---|
| Context | Full conversation | Fork (independent) |
| Purpose | Intent analysis | API execution |
| Token usage | Higher | Lower |
| Execution | Sequential | Can be parallel |
User Query → Main Skill (detect + analyze)
↓
Task Tool → Sub-Skill (API search)
↓
Main Skill (select best match)
↓
Task Tool → Sub-Skill (API fetch docs)
↓
Main Skill (integrate + respond)
This skill complements the existing documentation-lookup skill:
/context7:docsBoth can coexist - use auto-research for seamless UX, documentation-lookup for explicit queries.