Skip to content

Backstage Plugin Index (Option A)

This page documents the JSON index (dist/index.json) generated by RuleHub for the Backstage UI plugin. The plugin displays data as-is from this index without synthesizing extra metadata.

  • Producer: tools/coverage_map.py
  • Validator: tools/plugin_index_validate.py against tools/schemas/plugin-index.schema.json
  • schemaVersion: default is 1; optional fields are emitted when available.

Structure

Top-level object:

  • schemaVersion (integer, optional; default 1)
  • packages (array, required)

Package (required): id, name, standard, version, coverage[]

Optional: jurisdiction (string|string[]), description, framework, severity, geo, paths[] ({path, exists}), owner, tags[], links.

Generate

python3 -m venv .venv
. .venv/bin/activate
pip install -U pip
pip install -r requirements.txt
python tools/coverage_map.py

Outputs: docs/coverage.md, dist/coverage.html, dist/policies-index.json, dist/coverage.json, dist/index.json, dist/policies.csv.

Validate

python tools/plugin_index_validate.py \
  --schema tools/schemas/plugin-index.schema.json \
  --index dist/index.json

Reports to dist/integrity/ (markdown + JSON). Exit codes: 0 valid, 2 validation errors, 3 IO/parse/schema issues.

Notes

  • The Backstage plugin shows optional fields when present; otherwise cells remain empty.
  • Links in the UI are built from a configurable repo base (default: https://github.com/rulehub/rulehub/tree/main/).