Zum Hauptinhalt springen
tsecurity.de LIVE
Echtzeit-Radar & Feeds
Alle RSS Feeds
👥 Community & Social
Sichere ProgrammierungThe Model Got Better. Your Judgment Got Worse.(22.09.2026 um 03:02 Uhr)
Sichere ProgrammierungAIFeed - signed content permissions for AI web crawlers(22.09.2026 um 03:10 Uhr)
Sichere ProgrammierungThanks, glad you liked it!(22.09.2026 um 03:15 Uhr)
Sichere ProgrammierungA request for /.env shouldn't render your React app(22.09.2026 um 03:17 Uhr)
Sichere ProgrammierungAI-Agent Marketplaces Need Verifiable Delivery, Not More Listings(22.09.2026 um 03:20 Uhr)
AI & KI NachrichtenBeyond Bigger Models: Toward a Modular Cognitive Architecture(22.09.2026 um 03:21 Uhr)
Sichere ProgrammierungMasa Depan Manajemen Data: Mengenal Konsep Data Mesh yang Revolusioner(22.09.2026 um 03:22 Uhr)
Sichere ProgrammierungHow to Search Your Claude Code Conversation History(22.09.2026 um 03:22 Uhr)
Sichere ProgrammierungThe Model Got Better. Your Judgment Got Worse.(22.09.2026 um 03:02 Uhr)
Sichere ProgrammierungAIFeed - signed content permissions for AI web crawlers(22.09.2026 um 03:10 Uhr)
Sichere ProgrammierungThanks, glad you liked it!(22.09.2026 um 03:15 Uhr)
Sichere ProgrammierungA request for /.env shouldn't render your React app(22.09.2026 um 03:17 Uhr)
Sichere ProgrammierungAI-Agent Marketplaces Need Verifiable Delivery, Not More Listings(22.09.2026 um 03:20 Uhr)
AI & KI NachrichtenBeyond Bigger Models: Toward a Modular Cognitive Architecture(22.09.2026 um 03:21 Uhr)
Sichere ProgrammierungMasa Depan Manajemen Data: Mengenal Konsep Data Mesh yang Revolusioner(22.09.2026 um 03:22 Uhr)
Sichere ProgrammierungHow to Search Your Claude Code Conversation History(22.09.2026 um 03:22 Uhr)
Intelligence View
⚡ tsecurity.de Intelligence

I Built a CLI That Gives Your LLM Accurate Library Docs — No MCP Server Needed

The Problem You're building with Next.js 15 and ask your AI assistant to write an API route. It gives you the Pages Router pattern from Next.js 12. You paste React docs into the prompt, but they're already outdated by the time you copy…

0
↗ Quelle (dev.to)
Reagiere als Erste:r — dein Feedback zählt!




The Problem



You're building with Next.js 15 and ask your AI assistant to write an API route. It gives you the Pages Router pattern from Next.js 12. You paste React docs into the prompt, but they're already outdated by the time you copy them.



Context7 solved this by indexing documentation directly from source repos and serving it through an MCP server. Cursor, Claude Code, and other AI editors use it to get real, version-specific docs instead of hallucinated APIs.



But MCP has a constraint: you need an MCP-compatible client. If you're working in the terminal, running a script, or using a local LLM — you're out of luck.






The Solution



I built c7 — a CLI that pulls from the same Context7 database and outputs docs as plain text to stdout.




c7 react hooks
c7 express middleware
c7 nextjs "app router"






That's it. No server, no configuration, no IDE integration. Just text you can pipe anywhere.






How It Works



The CLI does two things:





  1. Resolves a library name to a Context7 ID (e.g., react/websites/react_dev)


  2. Fetches documentation for that library, filtered by topic



Under the hood it's two API calls using Node.js built-in fetch against Context7's v2 API. The entire project is ~220 lines across two files with zero dependencies.




bin/c7.js   — 136 lines (CLI parsing + output formatting)
lib/api.js — 87 lines (Context7 v2 API client)






No axios. No commander. No chalk. Just process.argv and fetch.






The Real Power: Pipes



Because c7 outputs plain text to stdout, it composes with everything:






Pipe into LLMs






# Claude
c7 react hooks | claude "summarize the key patterns and show examples"

# Ollama (local models)
c7 express middleware | ollama run codellama "explain this middleware pattern"

# Any LLM CLI
c7 nextjs "api routes" | llm "write an API route based on these docs"









Pipe into Unix tools






# Search docs
c7 nextjs "api routes" | grep "export"

# Page through docs
c7 prisma "schema" | less

# Copy to clipboard
c7 react "useEffect" | pbcopy

# Build context files
c7 nextjs "app router" >> context.txt
c7 react "server components" >> context.txt









Use in scripts






# Pre-load context for a coding agent
DOCS=$(c7 nextjs "app router middleware")
claude "Build a Next.js middleware that handles auth. Use these docs:\n$DOCS"









c7 vs MCP Server






































MCP Server c7 CLI
Setup Install server, configure MCP client, restart editor npx @vedanth/context7
Works in MCP-compatible editors Terminal, scripts, CI, anywhere
Composable Limited to MCP protocol Pipes, redirects, subshells
Dependencies Several npm packages Zero
Lines of code ~1000+ ~220


They're complementary. Use the MCP server in your editor, use c7 everywhere else.






Getting Started






# Run without installing
npx @vedanth/context7 react hooks

# Or install globally
npm install -g @vedanth/context7
c7 react hooks
c7 express middleware
c7 nextjs "app router" | claude "summarize"






No API key required for basic usage. For higher rate limits, get a free key at context7.com/dashboard.






Links








Built by Vedanth Bora. If this saves you from one hallucinated API, it was worth building.

Ähnliche Beiträge
🔍 Verwandte News

Auch interessante Nachrichten I Built a CLI That Gives Your LLM Accurate Library Docs — No MCP Server Needed

Thematisch verwandte Begriffe: Built, That, Gives, Your · 6 Treffer

Laden...

Beiträge werden geladen ...

Laden...

Videos werden geladen ...

Laden...

Beiträge werden geladen ...

Laden...

Videos werden geladen ...

Laden...

Beiträge werden geladen ...

Laden...

Videos werden geladen ...

Laden...

Beiträge werden geladen ...

Laden...

Videos werden geladen ...

Zum Aktualisieren ziehen
ZERO-DAY CVE-2026-49449 | Joplin is an open source note-taking and to-do application that organise…
Advisory →
TTS Reader • tsecurity.de Voice
tsecurity.de Icon
tsecurity.de App
Offline-Lesen, Eilmeldungen & 0ms Ladezeit

Installiere tsecurity.de direkt auf deinen Home-Bildschirm für das ultimative Vollbild-Magazinerlebnis ohne Browser-Leisten.

Nächster Beitrag
Themen-Radar & Intelligence Matrix
Echtzeit-Taxonomie nach Angriffsvektoren & Plattformen

tsecurity.de Live Threat Radar

🔴 LIVE RADAR
MONITORING
AKTIV
CVE-DATENBANK
LIVE
🔍
Community Radar & Live Chat
Sentinel Bot online • Live-Stream
Dein Cluster: Security Explorer
Match:
lädt…
Verbindung zum Community-Stream wird aufgebaut...
Bearbeitungsmodus — Senden überschreibt deine Nachricht
Community-Puls — was gerade passiert
lädt…
Aktivitäten deiner Analysten
lädt…
Neues Thema oder Eilmeldung einreichen

Reiche interessante Links, Zero-Days oder Debatten ein. Die Community entscheidet per Upvote über die Veröffentlichung.

Heiß diskutierte Einreichungen
🔖 Gespeicherte Artikel
📂 Keine gespeicherten Artikel vorhanden.
Zurück Ziehen Vor
Links: vorheriger Artikel Rechts: nächster Artikel unten: schließen
News NIS-2 Frühwarnung Tier-1 Intel ⏱️ 3 Min vor 10 Min
Artikeldaten werden geladen...

Zurück: vorheriger Vor: nächster
↗ Original-Quelle
Social Reaktionen Deine Reaktion zählt
Einstufung & Relevanz-Poll 0 Stimmen
In sozialen Netzwerken teilen 1-Klick