Stop letting Cursor, Claude, and Windsurf hallucinate deprecated APIs. DocOrbit reconciles lockfiles across 8 ecosystems, serves local FTS5 search in 1.3ms, and enforces closed-loop AST contracts.
$ npx -y docorbit mcp
DocOrbit runs silently inside Cursor, Claude, Windsurf, or custom agents. You don't need to manually read 50 pages of docs or paste massive text files. Give your agent the task and the documentation link — DocOrbit automates tree crawling, AST slicing, and contract verification in milliseconds.
Add DocOrbit to your harness config once (.cursor/mcp.json, Claude Desktop, Windsurf, or Roo Code). Zero external dependencies, local SQLite engine.
Mention the documentation URL or library name in your regular prompt and tell your agent to use DocOrbit for grounding and verification.
The agent calls ingest_doc, get_implementation_context, and check_api to generate 100% build-passing, contract-verified code.
docorbit, your agent bypasses its training cutoff and queries the local MCP server directly for active API contracts.
import { NextResponse } from 'next/server';
import Stripe from 'stripe';
const stripe = new Stripe(process.env.STRIPE_SECRET_KEY!, {
apiVersion: '2024-12-18.acacia',
});
export async function POST(req: Request) {
const { items } = await req.json();
// DocOrbit AST verified: stripe.checkout.sessions.create parameters
const session = await stripe.checkout.sessions.create({
payment_method_types: ['card'],
line_items: items.map((item: any) => ({
price: item.priceId,
quantity: item.quantity,
})),
mode: 'payment',
success_url: `${process.env.NEXT_PUBLIC_URL}/success?session_id={CHECKOUT_SESSION_ID}`,
cancel_url: `${process.env.NEXT_PUBLIC_URL}/canceled`,
});
return NextResponse.json({ url: session.url });
}
params and searchParams are Promises. Without DocOrbit, LLMs output Next 14 sync params.id causing immediate runtime exceptions.
import { NextResponse } from 'next/server';
export async function GET(
request: Request,
{ params }: { params: Promise<{ id: string }> }
) {
// DocOrbit AST verified: params is a Promise in Next.js 15
const { id } = await params;
return NextResponse.json({ userId: id, status: 'active' });
}
@validator and v2 @field_validator(mode='before'). DocOrbit inspects pyproject.toml or requirements.txt to ground the exact v2 syntax.
from fastapi import FastAPI
from pydantic import BaseModel, EmailStr, field_validator
app = FastAPI()
class UserCreate(BaseModel):
email: EmailStr
age: int
# DocOrbit verified: Pydantic v2 @field_validator with @classmethod
@field_validator('email')
@classmethod
def normalize_email(cls, v: str) -> str:
return v.lower().strip()
@app.post('/users')
def create_user(user: UserCreate):
return {'email': user.email, 'status': 'created'}
tailwind.config.js in favor of CSS-first @theme blocks. DocOrbit ensures agents don't create obsolete JavaScript config files.
@import 'tailwindcss';
/* DocOrbit verified: Tailwind v4 CSS-first @theme directive */
@theme {
--color-brand-primary: #10b981;
--color-brand-accent: #34d399;
--font-display: 'Inter', system-ui, sans-serif;
}
Coding agents don't fail because LLMs lack intelligence. They fail because documentation is unversioned, full of escaped JSON bloat, or lacks AST validation.
An agent working in a Next.js 14 project gets fed Next.js 15 documentation and uses await params, breaking your build. DocOrbit reconciles your installed lockfile against documentation branches with SemVer laddering.
DocOrbit parses generated API calls with an AST engine to catch wrong HTTP methods, missing required params, and deprecated endpoints before your code is saved.
SQLite WAL mode, memory-mapped I/O (256MB), and prepared statement batching reduce search latency from 45ms to 1.3ms.
No JSON escaping, no duplicated schemas. Direct GitHub Markdown delivery cuts token context consumption by 55%.
Strict RFC 1918/4193 blocklist, cloud metadata protection (169.254.169.254), and untrusted content provenance annotations.
DocOrbit runs as an agent-native MCP server over stdio or HTTP. Select your IDE or harness below to copy the drop-in configuration.
{
"mcpServers": {
"docorbit": {
"command": "npx",
"args": ["-y", "docorbit", "mcp"]
}
}
}
{
"mcpServers": {
"docorbit": {
"command": "npx",
"args": ["-y", "docorbit", "mcp"]
}
}
}
claude mcp add docorbit -- npx -y docorbit mcp
{
"mcpServers": {
"docorbit": {
"command": "npx",
"args": ["-y", "docorbit", "mcp"]
}
}
}
{
"experimental": {
"model_context_protocol": {
"servers": {
"docorbit": {
"command": "npx",
"args": ["-y", "docorbit", "mcp"]
}
}
}
}
}
{
"mcpServers": {
"docorbit": {
"command": "npx",
"args": ["-y", "docorbit", "mcp"]
}
}
}
{
"experimental": {
"modelContextProtocolServers": [
{
"transport": {
"type": "stdio",
"command": "npx",
"args": ["-y", "docorbit", "mcp"]
}
}
]
}
}
require("avante").setup({
mcp_servers = {
docorbit = { command = "npx", args = { "-y", "docorbit", "mcp" } }
}
})
import { Client } from "@modelcontextprotocol/sdk/client/index.js";
import { StdioClientTransport } from "@modelcontextprotocol/sdk/client/stdio.js";
const transport = new StdioClientTransport({ command: "npx", args: ["-y", "docorbit", "mcp"] });
const client = new Client({ name: "my-agent", version: "1.0.0" }, { capabilities: {} });
await client.connect(transport);
const res = await client.callTool({ name: "get_implementation_context", arguments: { task: "Stripe payment" } });
Empirical evaluation comparing DocOrbit against Context7, Firecrawl, and raw docs crawling across accuracy, latency, and AST verification.
| Dimension / Metric | Official Docs Fetch | Firecrawl Scraper | Context7 (Upstash) | DocOrbit (v0.2.4) |
|---|---|---|---|---|
| Search Latency | ~350ms (HTTP) | ~150ms+ (Cloud API) | ~45ms (Network API) | ~1.3ms (SQLite FTS5) |
| Context Assembly Latency | ~220ms | ~140ms | ~50ms | ~2.8ms (Prepared) |
| Held-Out Eval Accuracy | 83.3% (-16.7%) | 83.3% (-16.7%) | 83.3% (-16.7%) | 100.0% (0 Hallucinated) |
| Overall Task Success Rate | 70.6% | 76.5% | 82.4% | 88.2% |
| Retrieval Precision@k | 58.2% | 61.5% | 69.1% | 94.1% |
| Retrieval Recall@k | 63.4% | 70.9% | 75.3% | 94.1% |
| AST Code Verification | None | None | None | 9 Catches / 0 False Pos |
| Payload Delivery Format | Raw HTML / MD | Raw HTML / MD | Escaped JSON Wrapper | Pure Clean Markdown |
| Token Consumption | Excessive (HTML bloat) | High (Boilerplate) | High (JSON stringify) | -55% to -60% Tokens |
| Local-First & Offline | No | No | No | Yes (Embedded SQLite) |
Engineered specifically for LLMs. Delivers clean Markdown by default, with optional structured JSON mode.
Deterministic hybrid search over sliced documentation chunks with SemVer boosting.
Retrieve a complete normalized document or specific section chunk by URL or ID.
Structured OpenAPI & Swagger search with exact parameters, methods, and schemas.
Find verified code snippets filtered by programming language, framework, or task.
Search explicit breaking changes, deprecation warnings, and runtime gotchas.
Verify generated API calls against indexed documentation contracts via AST parsing.
Compare two documentation versions to identify added, removed, or changed APIs.
Scan project workspace source code against deprecated APIs between versions.
Pack holistic multi-dimensional context (APIs + examples + pitfalls) within token limits.
List all indexed documentation sources, formats, snapshots, and authority scores.
Fetch, normalize, slice, and index external documentation from URL or raw markdown.
Return hierarchical tree of available documentation sections and token budgets.
Inspect project workspace dependencies and resolve authoritative doc versions.
Synthesize evidence-grounded implementation recipes with step-by-step guidance.
Export standardized agent guidance files: AGENTS.md, CLAUDE.md, skill.md, llms.txt.