JSDoc
$ jsdoc Community Low RiskJSDoc parses JavaScript source comments to generate static HTML API documentation sites (-d ./out). For agents, the standout flag is -X (--explain), which dumps all parsed doclets as a structured JSON array directly to stdout without writing any HTML files.
npm install -g jsdoc Extracting structured JSDoc AST doclets via jsdoc -X or building local HTML docs runs directly on source files without MCP.
Agent-Readiness Checklist
Static evaluation (not yet probed on this host). Run npm run data:probe locally to capture live verification.
FCRS-1.0 6-Dimension Breakdown
-X (--explain) emits structured JSON doclets cleanly to stdout and -c/-d/-r work headlessly without prompts.
-X/--explainprints parsed doclets as JSON to stdout- Deterministic headless execution with
-cand-d
-X mode is strictly read-only; HTML generation writes into -d (or ./out by default) locally.
-Xperforms zero filesystem writes
Cross-platform Node package via npm install -g jsdoc or npx jsdoc.
- Standard npm / npx installation
Mature standard for plain JavaScript JSDoc extraction, though TypeScript codebases typically favor TypeDoc or API Extractor.
- Focused on JavaScript; TypeScript requires plugins or TypeDoc
Long-standing Apache-2.0 project (jsdoc/jsdoc) in low-churn maintenance.
- Stable
jsdoc/jsdocrepository
Well-documented CLI flags and tag reference at jsdoc.app.
- Official documentation at jsdoc.app/about-commandline
Security, Auth & Guardrails
None required; operates strictly on local JavaScript source and jsdoc.json configs.
100% free, offline, and Apache-2.0 open-source.
# JSDoc Agent Rules - Use `jsdoc -X` (`--explain`) when inspecting doc comments or symbol metadata—it emits JSON to stdout without writing `./out`. - Always pass `-d <dir>` explicitly when generating HTML so docs do not land in the default `./out` folder unexpectedly.
Agent-Ready Command Recipes
Safe Read-Only Queries
jsdoc -X -r src/
Parses src/ recursively and prints all documented symbols as a JSON array to stdout with zero disk writes.
Controlled Writes & Previews
jsdoc -c jsdoc.json -d docs/api -r src/
Generates HTML API docs using jsdoc.json into docs/api.
Strengths for Agents
- +
jsdoc -X(--explain) dumps structured JSON symbol/doclet metadata directly to stdout with zero writes. - + Standard, dependency-light JavaScript API doc generator.
- + Zero-install execution via
npx jsdoc.
Caveats & Pitfalls
- ! Omitting
-Xand-dwrites HTML artifacts into./outin the current directory. - ! Designed primarily for JavaScript rather than native TypeScript syntax.