Directory Compare FCRS-1.0 /llms.txt
← Back to Directory

Redocly CLI

$ redocly Official Low Risk
Redocly · Design & Docs · MIT · macos / linux / windows

Redocly CLI (@redocly/cli) is the flagship OpenAPI 2.0/3.0/3.1 toolchain for linting (redocly lint), multi-file bundling (redocly bundle), stats (redocly stats), and rendering static Redoc HTML docs (redocly build-docs). Rich --format=json / github-actions output and zero-JVM Node execution make it ideal for API-first coding agents.

FCRS-1.0 Score
91 /100
Excellent
Medium Confidence
Zero-Friction Install
npm install -g @redocly/cli
CLI vs MCP Decision CLI Only

redocly validates, bundles, and builds static docs locally over OpenAPI specs with --format=json in under a second.

Agent-Readiness Checklist

✓ JSON Output
— Field Filtering
✓ Non-Interactive
— Dry-Run
— Read-Only Mode
— NO_COLOR Clean
✓ Self-Describing
— Official SKILL.md

Static evaluation (not yet probed on this host). Run npm run data:probe locally to capture live verification.

FCRS-1.0 6-Dimension Breakdown

Agent-Readiness 23 / 25

Fast Node.js CLI with --format=json, github-actions, summary, and checkstyle formatters plus non-interactive flags.

  • --format=json on lint and stats
  • Zero interactive prompts during validation, bundling, or build-docs
Trust & Safety 23 / 25

Lint, stats, and bundling run purely offline on local specs; remote cloud push is isolated behind explicit push command and REDOCLY_AUTHORIZATION.

  • Read-only lint and stats
  • Explicit -o output path for bundle and build-docs
Setup & Portability 14 / 15

Lightweight pure-JS/TS npm package (@redocly/cli) runnable globally or via npx @redocly/cli with no JVM.

  • npm install -g @redocly/cli and npx @redocly/cli
Utility & Efficiency 14 / 15

Solves OpenAPI 3.1 validation, $ref bundling, splitting, and HTML doc generation cleanly in one tool.

  • Supports lint, bundle, split, stats, and build-docs
Maintenance & Lineage 9 / 10

Official Redocly repository (Redocly/redocly-cli) actively maintained under MIT.

  • Official Redocly GitHub organization
Docs & Verifiability 8 / 10

Thorough official CLI reference docs and rule explanations at redocly.com/docs/cli/.

  • Official docs at redocly.com/docs/cli/

Security, Auth & Guardrails

Auth Modes
No Auth Env API Key
Credential Storage

No credentials needed for lint/bundle/build-docs; optional Redocly Cloud push reads REDOCLY_AUTHORIZATION.

Side Effects
Read-Only Local Write Remote Write
Cost & Quotas

CLI is free open-source software (MIT); optional Redocly Cloud portal hosting has free and paid tiers.

Copyable Guardrail for CLAUDE.md / AGENTS.md
# Redocly CLI Agent Rules
- Run `redocly lint <spec> --format=json` after any OpenAPI schema edit.
- Use `redocly bundle -o dist/...` into a separate artifact path rather than overwriting source `$ref` files.
- Do not invoke `redocly push` to Redocly Cloud without explicit human approval.

Agent-Ready Command Recipes

Safe Read-Only Queries

Lint an OpenAPI spec with JSON diagnostics
redocly lint openapi.yaml --format=json

Validates OpenAPI 3.0/3.1 rules and outputs machine-parseable JSON problem records.

Compute OpenAPI spec metrics as JSON
redocly stats openapi.yaml --format=json

Reports counts of paths, operations, schemas, and parameters in JSON.

Controlled Writes & Previews

Bundle multi-file OpenAPI specs into one artifact
redocly bundle openapi.yaml -o dist/openapi.bundled.yaml

Resolves external $ref files and writes a clean single-file spec to dist/openapi.bundled.yaml.

Strengths for Agents

  • + --format=json on redocly lint and redocly stats makes OpenAPI diagnostics trivial for agents.
  • + Pure Node.js execution without Java/JVM overhead.
  • + Handles multi-file $ref bundling (redocly bundle) and static Redoc HTML docs (build-docs).

Caveats & Pitfalls

  • ! redocly preview-docs starts a blocking local web server.
  • ! Telemetry is enabled unless opted out via REDOCLY_TELEMETRY=off in strict air-gapped/privacy setups.

Tested Agent Hosts

Claude Code Codex CLI Gemini CLI