agentleFS
BhavinMBhavinM/my-claude-setup/.claude/skills/context7-mcp/SKILL.md

context7-mcp

Skill0 starsChanged 10 months agoMITView on GitHub

Query up-to-date library and framework documentation via the Context7 MCP server. Use when user asks 'how does X work in Next.js?', 'show me the React docs for Y', 'what's the API for Supabase Z?', 'latest docs for tanstack-query', or needs current documentation for any library/framework. Do NOT use for general web search or current events (use tavily-mcp instead).

18 other projects use a version of this.

Adopted by

Most recently taken up by

Used with

Projects with it also use to-tickets, writing-plans and 10 more.

Other files people use alongside this one.

Files found in the same public projects as a version of this one, more often than they turn up anywhere else. Each project counts once, large collections count for less, and this file's own repository is left out.
  • AWSSkill

    to-tickets

    Break a plan, spec, or the current conversation into a set of tracer-bullet tickets, each declaring its blocking edges, published to the configured tracker (edges as text in one file per ticket locally, or native blocking links on a real tracker).

    Also in 3 projects that use this

  • OpenAISkill

    writing-plans

    Use when you have a spec or requirements for a multi-step task, before touching code

    Also in 4 projects that use this

  • VercelSkill

    find-skills

    Helps users discover and install agent skills when they ask questions like "how do I do X", "find a skill for X", "is there a skill that can...", or express interest in extending capabilities. This skill should be used when the user is looking for functionality that might exist as an installable skill.

    Also in 5 projects that use this

  • OpenAISkill

    executing-plans

    Use when you have a written implementation plan to execute in a separate session with review checkpoints

    Also in 3 projects that use this

  • SentrySkill

    diagnosing-bugs

    A discipline for hard bugs, flaky tests, CI hangs, and performance regressions in this SDK. Use when the user says "diagnose" or "debug this", reports something broken/throwing/failing/hanging/slow, or a test is flaky. Builds a tight, red-capable feedback loop before hypothesizing.

    Also in 3 projects that use this

  • AWSSkill

    grill-me

    A relentless interview to sharpen a plan or design.

    Also in 7 projects that use this

  • +2 more from aws
  • +3 more from openai

The file

We split this skill into the rules it gives an agent

5 rules. 0 are common, 3 are distinctive, and 2 are very specific to this project.

  • 0

    Common

    Most of the 18 edited versions we read keep these.

  • 3

    Distinctive

    This author's own choices. Worth a look.

  • 2

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Very specific:

    All Context7 MCP tools use the mcp__context7__ prefix.

    line 30
  2. Distinctive:

    Note: If a common ID stops working, re-resolve it — library IDs can change when repos are reorganized.

    line 101
  3. Very specific:

    Add version context: "Next.js 15 app router middleware" vs just "middleware"

    line 116
  4. Distinctive:

    Ask about one feature at a time rather than broad overviews

    line 121
  5. Distinctive:

    If output is still large, extract the relevant section and summarize for the user

    line 122

“Common” is measured: kept by at least 6 in 10 of the 18 edited versions of this file we could read. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

Context7 Library Documentation

You are an expert at using the Context7 MCP server to retrieve current, accurate library documentation. Context7 provides up-to-date docs for thousands of libraries and frameworks, eliminating outdated training data issues.

Critical: These Are Direct Tool Calls

MCP tools are direct tool calls — exactly like Read, Grep, or Bash. They are NOT CLI commands.

CORRECT — call the tool directly:

Tool: mcp__context7__resolve-library-id
Parameters: { "libraryName": "next.js" }

WRONG — do NOT shell out:

Bash: claude mcp call context7 resolve-library-id ...  # This does not work

All Context7 MCP tools use the mcp__context7__ prefix.

Critical: Always Resolve Library ID First

You must call resolve-library-id before query-docs unless you already have a confirmed /org/project ID from a previous call in this session.

Critical: Output Size Awareness

ToolOutput SizeNotes
resolve-library-idSmallReturns list of matching library IDs
query-docsMedium-LargeDocumentation content — scales with topic breadth. Use specific queries to limit size.

Workflow: Find & Query Documentation

Trigger: User asks about library APIs, framework patterns, configuration options, or "how to do X with Y library"

Steps

  1. Resolve the library ID:
    resolve-library-id({ libraryName: "next.js" })
    → returns matching libraries with /org/project IDs
  2. Query documentation with a specific question:
    query-docs({ libraryId: "/vercel/next.js", query: "how to use middleware for authentication" })
    → returns relevant documentation sections
  3. Refine if needed (max 3 calls per tool per question):
    query-docs({ libraryId: "/vercel/next.js", query: "middleware matcher config" })
    → more specific follow-up

Key Patterns

  • Be specific in queries: "How to set up authentication with JWT in Express.js" beats "auth"
  • Max 3 calls per tool per question — if 3 queries don't answer it, use a different approach
  • One library per query — don't try to query multiple libraries in a single query-docs call
  • Use the full /org/project format for libraryId (e.g., /vercel/next.js, /supabase/supabase)

Decision Tree

User NeedsAction
Docs for a known libraryresolve-library-id → query-docs
Not sure which library to useresolve-library-id with general term, review matches
Already have library ID from this sessionSkip resolve, go straight to query-docs
Library not found in Context7Fall back to tavily-mcp search or WebFetch for official docs site

Common Library IDs

These are frequently used in this project — skip resolve-library-id for these:

LibraryID
Next.js/vercel/next.js
React/facebook/react
Supabase JS/supabase/supabase-js
TanStack Query/tanstack/query
Zod/colinhacks/zod
React Hook Form/react-hook-form/react-hook-form
Tailwind CSS/tailwindlabs/tailwindcss
date-fns/date-fns/date-fns
Radix UI/radix-ui/primitives
Playwright/microsoft/playwright
Vitest/vitest-dev/vitest

Note: If a common ID stops working, re-resolve it — library IDs can change when repos are reorganized.

Troubleshooting

"Library not found"

  1. Try alternate names: "react-query" vs "tanstack query" vs "@tanstack/react-query"
  2. Try the npm package name: "next" vs "next.js"
  3. Try the GitHub org/repo format directly: "vercel/next.js"
  4. Fall back to tavily-mcp search for the official docs URL, then use WebFetch

Query Returns Irrelevant Results

  1. Make your query more specific — include the exact API name or concept
  2. Try rephrasing: "server actions" vs "use server directive" vs "form actions"
  3. Add version context: "Next.js 15 app router middleware" vs just "middleware"

Query Returns Too Much Content

  1. Narrow the query to a specific function or concept
  2. Ask about one feature at a time rather than broad overviews
  3. If output is still large, extract the relevant section and summarize for the user

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.