CLI Reference ​
The richview CLI generates, validates, lints, verifies, and publishes reports from the command line.
Global options ​
| Flag | Description |
|---|---|
-o, --output <dir> | Output directory |
-f, --format <format> | Output format: json or pretty (default: pretty) |
--verbose | Enable verbose output |
--no-color | Disable colored output |
-v, --version | Print version |
Commands ​
generate <schema> ​
Generate an HTML report from a JSON or YAML schema file. Alias: render.
richview generate report.yaml
richview generate report.json -o dist/validate <schema> ​
Validate a schema file against the RichView report schema without rendering.
richview validate report.yamllint <schema> ​
Check a report for quality issues across data quality, chart quality, accessibility, best practices, structure, and provenance.
richview lint report.yaml
richview lint report.yaml --severity warning
richview lint report.yaml --category data-quality,chart-quality
richview lint report.yaml --disable missing-alt-text,missing-provenance| Flag | Description |
|---|---|
--severity <level> | Minimum severity: error, warning, info (default: info) |
--category <cat> | Filter by category (comma-separated) |
--disable <rules> | Disable specific rules (comma-separated) |
verify [report] ​
Run verification assertions on a report file.
richview verify report.yaml
richview verify --list-typescheck <schema> ​
Combined quality check: validates schema, lints, and verifies assertions in one pass.
richview check report.yaml
richview check report.yaml --verify-only
richview check report.yaml --lint-onlyinit [name] ​
Scaffold a new report project with an example schema.
richview init my-report
richview init dashboard --template dashboard
richview init report --jsonTemplates: starter, dashboard, analysis, charts, blank, postmortem, monthly-review, data-quality, sales-pipeline, executive-summary.
serve <schema> ​
Start a local dev server with live reload.
richview serve report.yaml
richview serve report.yaml --port 8080 --openexport <schema> ​
Export a report to PDF.
richview export report.yaml
richview export report.yaml --paper Letter --landscapepublish <schema> ​
Package a report as a deployable static site.
richview publish report.yaml
richview publish report.yaml --slug my-report --no-badge
richview publish report.yaml --server https://reports.example.com| Flag | Description |
|---|---|
--slug <slug> | Custom URL slug (default: slugified title) |
--no-badge | Omit the "Made with RichView" badge |
--server <url> | Custom server URL for publishing (default: https://richview.uk) |
watch <schema> ​
Watch a schema file and rebuild on every change.
richview watch report.yaml
richview watch report.yaml --include data.csvconvert <schema> ​
Convert a report between JSON and YAML formats.
richview convert report.yaml --to json
richview convert report.json -o report.yamldiff <base> <head> ​
Compare two report versions and show what changed.
richview diff v1.yaml v2.yamlmerge <files...> ​
Merge multiple report files into a single report.
richview merge part1.yaml part2.yaml
richview merge *.yaml --title "Combined Report" --duplicates renamestats <schema> ​
Show comprehensive statistics about a report: section counts, word counts, data coverage.
richview stats report.yamlinfo <schema> ​
Show a one-screen overview of a report: title, section breakdown, word count, and lint status.
richview info report.yaml
richview info report.yaml -f jsondescribe <schema> ​
Generate a text description of a report for agent self-verification.
richview describe report.yaml
richview describe report.yaml --text-only
richview describe report.yaml --section revenue-chartsummary <schema> ​
Show a compact text summary for agent pipelines. Alias: toc.
richview summary report.yaml --plaininspect <schema> ​
Deep introspection: data profiling, assertion coverage, column statistics.
richview inspect report.yamlextract <schema> ​
Extract structured data from report sections.
richview extract report.yaml --type chart
richview extract report.yaml --section revenue-chart --what datatransform <schema> ​
Apply transformations to a report.
richview transform report.yaml --keep-type chart,table
richview transform report.yaml --head 5
richview transform report.yaml --strip-assertions --anonymizeimport <file> ​
Import CSV or JSON data as a report section.
richview import data.csv
richview import data.json --type chart --chart-type lineembed <schema> ​
Generate embeddable HTML for a report or section.
richview embed report.yaml
richview embed report.yaml --section revenue-chart --mode htmldata <subcommand> ​
Data source guidance, diagnostics, and live data fetch.
data guide ​
Show a guide to all supported data sources (inline, file, SQL, slash-command, fetch).
richview data guide
richview data guide -f jsondata check <report> ​
Inspect a report file and list every data source used, with type and status.
richview data check report.yaml
richview data check report.yaml -f jsondata fetch <provider> <query> ​
Fetch live data from built-in providers. Returns a preview table by default, or full JSON with -f json.
Stocks (Yahoo Finance):
richview data fetch stocks AAPL
richview data fetch stocks MSFT -f jsonReturns daily OHLCV (open, high, low, close, volume) for the past 30 trading days.
Crypto (CoinGecko):
richview data fetch crypto BTC
richview data fetch crypto ETH -f jsonSupported symbols: BTC, ETH, SOL, ADA, DOT, AVAX, MATIC, LINK, DOGE, XRP, BNB, LTC, ATOM, UNI, SHIB. Returns daily price and volume for the past 30 days.
Weather (Open-Meteo):
richview data fetch weather London
richview data fetch weather "New York" -f jsonReturns daily temperature (max/min in Celsius) and precipitation for the next 7 days.
connect <subcommand> ​
Manage database connections for SQL data sources. Requires the RichView API server (richview serve or pnpm dev). Set RICHVIEW_SERVER env var to point to a remote server.
connect list ​
List all configured database connections.
richview connect list
richview connect list -f jsonconnect add ​
Register a new database connection.
richview connect add \
--name my-postgres \
--type postgres \
--database mydb \
--host localhost \
--port 5432 \
--username admin \
--password secret \
--ssl \
--test| Flag | Description |
|---|---|
--name <name> | Connection name (required) |
--type <type> | Database type: postgres, mysql, sqlite (required) |
--database <db> | Database name or file path (required) |
--host <host> | Database host |
--port <port> | Database port |
--username <user> | Database username |
--password <pass> | Database password |
--ssl | Enable SSL |
--test | Test the connection immediately after creating |
connect remove <id> ​
Remove a database connection by ID.
richview connect remove conn_abc123connect test <id> ​
Test an existing connection.
richview connect test conn_abc123connect query <id> <sql> ​
Run a SQL query against a connection and display results.
richview connect query conn_abc123 "SELECT * FROM sales LIMIT 10"
richview connect query conn_abc123 "SELECT date, SUM(revenue) FROM metrics GROUP BY date" -f jsontemplate <subcommand> ​
List, preview, apply, export, or import report templates.
template list ​
List all built-in templates.
richview template list
richview template list -f jsontemplate show <name> ​
Show details about a specific template.
richview template show dashboardtemplate apply <name> ​
Generate a report file from a template.
richview template apply dashboard --title "Q4 Dashboard"
richview template apply analysis --json -o reports/template export <name> ​
Export a built-in template as a standalone JSON or YAML file. Useful for sharing or customizing templates.
richview template export dashboard -o dashboard-template.json
richview template export starter --yaml -o starter-template.yamltemplate import <file> ​
Validate and inspect an external template file. Checks that the file has the required fields (name, description, template) and that the embedded report schema is valid.
richview template import my-template.json
richview template import custom-template.yaml -f jsonfeedback <subcommand> [report] ​
Manage a human-agent feedback loop. Feedback is stored in a sidecar file next to the report (e.g., report.feedback.json).
richview feedback init report.yaml
richview feedback show report.yaml
richview feedback show report.yaml --unresolved-only
richview feedback add report.yaml --section intro --type suggestion --message "Add more context"
richview feedback resolve report.yaml --id <uuid> --by reviewertheme <subcommand> ​
Manage corporate branding.
richview theme init
richview theme validate brand.yaml
richview theme preview brand.yamlschema ​
Output the RichView report JSON Schema for IDE autocomplete.
richview schema
richview schema --compact
richview schema --search chart
richview schema --section big-numberscreenshot <schema> ​
Take a PNG screenshot of a rendered report for agent verification.
richview screenshot report.yaml
richview screenshot report.yaml --width 1440 --full-pagegallery <dir> ​
Generate an index page listing all reports in a directory.
richview gallery ./reports --recursivedb <subcommand> ​
Database management for self-hosted instances. Requires the RichView API server. Set RICHVIEW_SERVER env var or use --server to point to a remote server. Authentication uses RICHVIEW_API_KEY.
db stats ​
Show database statistics: report count, section count, user count, and database file size.
richview db stats
richview db stats -f json
richview db stats --server https://my-richview.example.comdb clean ​
Remove test and orphan reports matching known patterns. Performs a dry run first and shows what would be deleted. Use --force to actually delete.
richview db clean
richview db clean --force
richview db clean --server https://my-richview.example.com --forcedb vacuum ​
Run SQLite VACUUM to reclaim disk space after deleting reports.
richview db vacuum
richview db vacuum --server https://my-richview.example.com| Flag | Description |
|---|---|
--server <url> | Server URL (default: https://richview.uk or RICHVIEW_SERVER env var) |
--force | Skip confirmation for destructive operations |
chart <subcommand> ​
Work with RichView chart YAML specs outside of a full report. Useful for iterating on chart design before embedding in a report.
chart preview <file.yaml> ​
Render a chart YAML spec as a standalone HTML page and open it in your browser. Writes to a temp file by default, or to a specific path with -o.
richview chart preview my-chart.yaml
richview chart preview my-chart.yaml -o preview.htmlchart validate <file.yaml> ​
Validate a chart YAML spec against the chart schema without rendering.
richview chart validate my-chart.yaml
richview chart validate my-chart.yaml -f jsonchart convert <file.json> ​
Convert a JSON chart section object to YAML format. Accepts either a full chart section or a bare { chartType, config } object.
richview chart convert chart-section.json
richview chart convert chart-section.json -o chart.yamlcompletions [shell] ​
Generate shell completion scripts.
richview completions bash >> ~/.bashrc
richview completions zsh >> ~/.zshrc
richview completions fish > ~/.config/fish/completions/richview.fish