{
  "$comment": "GENERATED FILE — do not edit. See x-generated below.",
  "x-generated": {
    "warning": "GENERATED FILE — do not edit.",
    "copyright": "© 2026 Extenza Works. All rights reserved.",
    "source": "src/app-cli/src/commands.ts, and the kq-command.ts of export-svg, export-png, export-portal and export-threats",
    "generator": "src/public-docs/scripts/generate.mts",
    "spec": "adr/0146-a-command-is-declared-once-as-a-spec.md",
    "version": "0.4.1",
    "regenerate": "pnpm --filter @extenza-works/kanoniq-public-docs generate"
  },
  "commands": [
    {
      "package": "@extenza-works/kanoniq-app-cli",
      "command": "init",
      "name": "init",
      "synopsis": "kq init [options] [<path>]",
      "summary": "Make a repository: kanoniq.repository.json, model/ with one Ecosystem, portal/Home.page.yml, and AGENTS.md for AI assistants",
      "description": "Make a repository that builds as it stands: kanoniq.repository.json, model/ with one Ecosystem named after the folder, its .g.kq, portal/Home.page.yml, how-to-use-kanoniq.md and a .gitignore line; and the authoring brief, AGENTS.md, which tells an AI assistant how to write the model, with CLAUDE.md and .github/copilot-instructions.md pointing at it. Writes nothing where a repository is already at, above or below the folder.",
      "positionals": [
        {
          "name": "path",
          "required": false,
          "repeatable": false,
          "description": "The folder to make the repository in, created if missing. Default: the current directory."
        }
      ],
      "options": [
        {
          "name": "no-agents",
          "type": "boolean",
          "multiple": false,
          "required": false,
          "description": "Leave out AGENTS.md, CLAUDE.md and .github/copilot-instructions.md."
        },
        {
          "name": "help",
          "short": "h",
          "type": "boolean",
          "multiple": false,
          "required": false,
          "description": "Show this help."
        }
      ],
      "environment": [
        {
          "name": "KANONIQ_TELEMETRY",
          "description": "off, 0 or false stops kq reporting the run; so does DO_NOT_TRACK=1."
        }
      ],
      "exitCodes": [
        {
          "code": 0,
          "meaning": "Done"
        },
        {
          "code": 1,
          "meaning": "Failed: the model has an error, a check found a change, or a file could not be read or written"
        },
        {
          "code": 2,
          "meaning": "Usage error: an unknown command or option, a missing or extra argument, a path that does not exist, or an output folder kq will not clear"
        }
      ],
      "examples": [
        {
          "command": "kq init my-model",
          "description": "Make the repository my-model, with the Ecosystem my-model."
        },
        {
          "command": "kq init --no-agents my-model",
          "description": "Make it without the authoring brief."
        }
      ]
    },
    {
      "package": "@extenza-works/kanoniq-app-cli",
      "command": "build",
      "name": "build",
      "synopsis": "kq build [options] <path>...",
      "summary": "Derive the model each path belongs to, write its .g.kq, and validate it",
      "description": "Derive the model each path belongs to, give every element its Id, write model/<name>.g.kq and model/<name>.model.json, and validate the model; then, on a valid model, judge it against its policies, where the repository turns them on. Never writes a file you wrote. An error, or a policy finding at error, fails the run, but the files are still written.",
      "positionals": [
        {
          "name": "path",
          "required": true,
          "repeatable": true,
          "description": "A file or folder of each model to build."
        }
      ],
      "options": [
        {
          "name": "check",
          "type": "boolean",
          "multiple": false,
          "required": false,
          "description": "Write nothing; exit 1 if a .g.kq file would change."
        },
        {
          "name": "require-license",
          "type": "boolean",
          "multiple": false,
          "required": false,
          "description": "Fail with exit 3 where a policy set needs a feature no license grants, instead of skipping it with a warning."
        },
        {
          "name": "help",
          "short": "h",
          "type": "boolean",
          "multiple": false,
          "required": false,
          "description": "Show this help."
        }
      ],
      "environment": [
        {
          "name": "KANONIQ_TELEMETRY",
          "description": "off, 0 or false stops kq reporting the run; so does DO_NOT_TRACK=1."
        }
      ],
      "exitCodes": [
        {
          "code": 0,
          "meaning": "Done"
        },
        {
          "code": 1,
          "meaning": "Failed: the model has an error, a check found a change, or a file could not be read or written"
        },
        {
          "code": 2,
          "meaning": "Usage error: an unknown command or option, a missing or extra argument, a path that does not exist, or an output folder kq will not clear"
        },
        {
          "code": 3,
          "meaning": "A paid feature that no license found grants"
        }
      ],
      "examples": [
        {
          "command": "kq build models/my-model",
          "description": "Build the model and write its .g.kq."
        },
        {
          "command": "kq build --check models/my-model",
          "description": "In CI: fail if someone forgot to build."
        }
      ]
    },
    {
      "package": "@extenza-works/kanoniq-app-cli",
      "command": "validate",
      "name": "validate",
      "synopsis": "kq validate [options] <path>...",
      "summary": "Check the model each path belongs to against every rule; write nothing",
      "description": "Run every validation rule on the model each path belongs to, as kq build would build it, and print each finding; then, on a valid model, its policies, where the repository turns them on. Writes nothing. A folder outside every repository validates each model under it.",
      "positionals": [
        {
          "name": "path",
          "required": true,
          "repeatable": true,
          "description": "A file or folder of each model to check."
        }
      ],
      "options": [
        {
          "name": "strict",
          "type": "boolean",
          "multiple": false,
          "required": false,
          "description": "Fail on a lint as well as an error."
        },
        {
          "name": "format",
          "type": "string",
          "multiple": false,
          "required": false,
          "value": "format",
          "allowed": [
            "text",
            "github",
            "sarif"
          ],
          "default": "text",
          "description": "How findings are written: a text line each, a GitHub Actions workflow command each, or one SARIF 2.1.0 log on standard output."
        },
        {
          "name": "as-of",
          "type": "string",
          "multiple": false,
          "required": false,
          "value": "yyyy-mm-dd",
          "description": "Judge policies as of this day instead of today, to reproduce a past run or see what a later date breaks: an exemption past its until lifts nothing."
        },
        {
          "name": "require-license",
          "type": "boolean",
          "multiple": false,
          "required": false,
          "description": "Fail with exit 3 where a policy set needs a feature no license grants, instead of skipping it with a warning."
        },
        {
          "name": "help",
          "short": "h",
          "type": "boolean",
          "multiple": false,
          "required": false,
          "description": "Show this help."
        }
      ],
      "environment": [
        {
          "name": "KANONIQ_TELEMETRY",
          "description": "off, 0 or false stops kq reporting the run; so does DO_NOT_TRACK=1."
        }
      ],
      "exitCodes": [
        {
          "code": 0,
          "meaning": "Done"
        },
        {
          "code": 1,
          "meaning": "Failed: the model has an error, a check found a change, or a file could not be read or written"
        },
        {
          "code": 2,
          "meaning": "Usage error: an unknown command or option, a missing or extra argument, a path that does not exist, or an output folder kq will not clear"
        },
        {
          "code": 3,
          "meaning": "A paid feature that no license found grants"
        }
      ],
      "examples": [
        {
          "command": "kq validate --strict models/my-model",
          "description": "Fail on a lint too."
        },
        {
          "command": "kq validate --format sarif models/my-model > kq.sarif",
          "description": "Write a SARIF log for a CI system."
        }
      ]
    },
    {
      "package": "@extenza-works/kanoniq-app-cli",
      "command": "audit",
      "name": "audit",
      "synopsis": "kq audit [options] <path>...",
      "summary": "Check the model each path belongs to against its policies, however the repository sets them",
      "description": "Judge the model each path belongs to against its policies and print every finding, whatever kanoniq.repository.json says: every policy set is checked, those it turns off included, and every finding is reported as info, or as error with --enforce. An invalid model is reported and not judged. Writes nothing.",
      "positionals": [
        {
          "name": "path",
          "required": true,
          "repeatable": true,
          "description": "A file or folder of each model to audit."
        }
      ],
      "options": [
        {
          "name": "enforce",
          "type": "boolean",
          "multiple": false,
          "required": false,
          "description": "Report every finding as an error and fail on any, an exempted breach aside."
        },
        {
          "name": "format",
          "type": "string",
          "multiple": false,
          "required": false,
          "value": "format",
          "allowed": [
            "text",
            "github",
            "sarif"
          ],
          "default": "text",
          "description": "How findings are written: a text line each, a GitHub Actions workflow command each, or one SARIF 2.1.0 log on standard output."
        },
        {
          "name": "as-of",
          "type": "string",
          "multiple": false,
          "required": false,
          "value": "yyyy-mm-dd",
          "description": "Judge policies as of this day instead of today, to reproduce a past run or see what a later date breaks: an exemption past its until lifts nothing."
        },
        {
          "name": "require-license",
          "type": "boolean",
          "multiple": false,
          "required": false,
          "description": "Fail with exit 3 where a policy set needs a feature no license grants, instead of skipping it with a warning."
        },
        {
          "name": "help",
          "short": "h",
          "type": "boolean",
          "multiple": false,
          "required": false,
          "description": "Show this help."
        }
      ],
      "environment": [
        {
          "name": "KANONIQ_TELEMETRY",
          "description": "off, 0 or false stops kq reporting the run; so does DO_NOT_TRACK=1."
        }
      ],
      "exitCodes": [
        {
          "code": 0,
          "meaning": "Done"
        },
        {
          "code": 1,
          "meaning": "Failed: the model has an error, a check found a change, or a file could not be read or written"
        },
        {
          "code": 2,
          "meaning": "Usage error: an unknown command or option, a missing or extra argument, a path that does not exist, or an output folder kq will not clear"
        },
        {
          "code": 3,
          "meaning": "A paid feature that no license found grants"
        }
      ],
      "examples": [
        {
          "command": "kq audit models/my-model",
          "description": "See what your policies would report before you turn them on."
        },
        {
          "command": "kq audit --enforce --as-of 2027-07-01 models/my-model",
          "description": "Fail on anything that breaches a policy on that day."
        }
      ]
    },
    {
      "package": "@extenza-works/kanoniq-app-cli",
      "command": "prune",
      "name": "prune",
      "synopsis": "kq prune [options] <path>...",
      "summary": "Build, and remove orphaned derived elements and Ids from .g.kq",
      "description": "Build the model each path belongs to, then remove every derived element marked orphan and every orphaned Id from its .g.kq, printing each, and validate what is left. A removed Id is gone for good.",
      "positionals": [
        {
          "name": "path",
          "required": true,
          "repeatable": true,
          "description": "A file or folder of each model to prune."
        }
      ],
      "options": [
        {
          "name": "check",
          "type": "boolean",
          "multiple": false,
          "required": false,
          "description": "Write nothing; exit 1 if a .g.kq file would change."
        },
        {
          "name": "help",
          "short": "h",
          "type": "boolean",
          "multiple": false,
          "required": false,
          "description": "Show this help."
        }
      ],
      "environment": [
        {
          "name": "KANONIQ_TELEMETRY",
          "description": "off, 0 or false stops kq reporting the run; so does DO_NOT_TRACK=1."
        }
      ],
      "exitCodes": [
        {
          "code": 0,
          "meaning": "Done"
        },
        {
          "code": 1,
          "meaning": "Failed: the model has an error, a check found a change, or a file could not be read or written"
        },
        {
          "code": 2,
          "meaning": "Usage error: an unknown command or option, a missing or extra argument, a path that does not exist, or an output folder kq will not clear"
        }
      ],
      "examples": [
        {
          "command": "kq prune --check models/my-model",
          "description": "In CI: fail if there are orphans."
        }
      ]
    },
    {
      "package": "@extenza-works/kanoniq-app-cli",
      "command": "fmt",
      "name": "fmt",
      "synopsis": "kq fmt [options] <path>...",
      "summary": "Rewrite .kq files to canonical form",
      "description": "Rewrite each .kq file you wrote under each path in canonical form, keeping comments and blank lines. Leaves .g.kq files alone.",
      "positionals": [
        {
          "name": "path",
          "required": true,
          "repeatable": true,
          "description": "A .kq file, or a folder of them."
        }
      ],
      "options": [
        {
          "name": "check",
          "type": "boolean",
          "multiple": false,
          "required": false,
          "description": "Write nothing; exit 1 if a file would change."
        },
        {
          "name": "help",
          "short": "h",
          "type": "boolean",
          "multiple": false,
          "required": false,
          "description": "Show this help."
        }
      ],
      "environment": [
        {
          "name": "KANONIQ_TELEMETRY",
          "description": "off, 0 or false stops kq reporting the run; so does DO_NOT_TRACK=1."
        }
      ],
      "exitCodes": [
        {
          "code": 0,
          "meaning": "Done"
        },
        {
          "code": 1,
          "meaning": "Failed: the model has an error, a check found a change, or a file could not be read or written"
        },
        {
          "code": 2,
          "meaning": "Usage error: an unknown command or option, a missing or extra argument, a path that does not exist, or an output folder kq will not clear"
        }
      ],
      "examples": [
        {
          "command": "kq fmt --check models/my-model",
          "description": "In CI: fail if a file is not formatted."
        }
      ]
    },
    {
      "package": "@extenza-works/kanoniq-app-cli",
      "command": "arrange",
      "name": "arrange",
      "synopsis": "kq arrange [options] <path>...",
      "summary": "Rewrite the model each path belongs to into the conventional layout",
      "description": "Move the declarations of the model each path belongs to into the conventional layout of folders and files, renaming and deleting through git where it tracks them. Ids are untouched, and a second run changes nothing.",
      "positionals": [
        {
          "name": "path",
          "required": true,
          "repeatable": true,
          "description": "A file or folder of each model to arrange."
        }
      ],
      "options": [
        {
          "name": "check",
          "type": "boolean",
          "multiple": false,
          "required": false,
          "description": "Write nothing; list what would be created, rewritten, renamed or deleted, and exit 1 if anything would."
        },
        {
          "name": "help",
          "short": "h",
          "type": "boolean",
          "multiple": false,
          "required": false,
          "description": "Show this help."
        }
      ],
      "environment": [
        {
          "name": "KANONIQ_TELEMETRY",
          "description": "off, 0 or false stops kq reporting the run; so does DO_NOT_TRACK=1."
        }
      ],
      "exitCodes": [
        {
          "code": 0,
          "meaning": "Done"
        },
        {
          "code": 1,
          "meaning": "Failed: the model has an error, a check found a change, or a file could not be read or written"
        },
        {
          "code": 2,
          "meaning": "Usage error: an unknown command or option, a missing or extra argument, a path that does not exist, or an output folder kq will not clear"
        }
      ],
      "examples": [
        {
          "command": "kq arrange models/shop",
          "description": "Arrange the model shop."
        }
      ]
    },
    {
      "package": "@extenza-works/kanoniq-app-cli",
      "command": "materialize",
      "name": "materialize",
      "synopsis": "kq materialize [options] [<path>]",
      "summary": "Write the repository's preset out as a policy set you can edit",
      "description": "Write the policy preset kanoniq.repository.json names out as an explicit policy set in model/policies.kq, every policy as Kanoniq ships it, keeping the Ids its findings and exemptions already use, and remove preset from kanoniq.repository.json. Refuses where no preset is set or the model already has a set under its Code.",
      "positionals": [
        {
          "name": "path",
          "required": false,
          "repeatable": false,
          "description": "A file or folder of the model; the current folder by default."
        }
      ],
      "options": [
        {
          "name": "check",
          "type": "boolean",
          "multiple": false,
          "required": false,
          "description": "Write nothing; list what would be written and removed, and exit 1 if anything would."
        },
        {
          "name": "help",
          "short": "h",
          "type": "boolean",
          "multiple": false,
          "required": false,
          "description": "Show this help."
        }
      ],
      "environment": [
        {
          "name": "KANONIQ_TELEMETRY",
          "description": "off, 0 or false stops kq reporting the run; so does DO_NOT_TRACK=1."
        }
      ],
      "exitCodes": [
        {
          "code": 0,
          "meaning": "Done"
        },
        {
          "code": 1,
          "meaning": "Failed: the model has an error, a check found a change, or a file could not be read or written"
        },
        {
          "code": 2,
          "meaning": "Usage error: an unknown command or option, a missing or extra argument, a path that does not exist, or an output folder kq will not clear"
        }
      ],
      "examples": [
        {
          "command": "kq materialize models/shop",
          "description": "Turn the baseline into the organization's own policy set."
        }
      ]
    },
    {
      "package": "@extenza-works/kanoniq-app-cli",
      "command": "dissolve",
      "name": "dissolve",
      "synopsis": "kq dissolve --into previous|next [options] <plateau> [<path>]",
      "summary": "Fold a plateau into its neighbor and remove it",
      "description": "Fold a plateau into the one before or after it and remove it, so the model has one point in time fewer. Shows the plan, then asks you to type the plateau's Code, unless --dry-run or --apply.",
      "positionals": [
        {
          "name": "plateau",
          "required": true,
          "repeatable": false,
          "description": "The Code of the plateau to dissolve."
        },
        {
          "name": "path",
          "required": false,
          "repeatable": false,
          "description": "A file or folder of the model. Default: the current directory."
        }
      ],
      "options": [
        {
          "name": "into",
          "type": "string",
          "multiple": false,
          "required": true,
          "value": "direction",
          "allowed": [
            "previous",
            "next"
          ],
          "description": "The neighbor that takes the dissolved plateau: next takes its changes, previous takes its state."
        },
        {
          "name": "dry-run",
          "type": "boolean",
          "multiple": false,
          "required": false,
          "description": "Show the plan and write nothing."
        },
        {
          "name": "apply",
          "type": "boolean",
          "multiple": false,
          "required": false,
          "description": "Dissolve without showing the plan or asking."
        },
        {
          "name": "help",
          "short": "h",
          "type": "boolean",
          "multiple": false,
          "required": false,
          "description": "Show this help."
        }
      ],
      "environment": [
        {
          "name": "KANONIQ_TELEMETRY",
          "description": "off, 0 or false stops kq reporting the run; so does DO_NOT_TRACK=1."
        }
      ],
      "exitCodes": [
        {
          "code": 0,
          "meaning": "Done"
        },
        {
          "code": 1,
          "meaning": "Failed: the model has an error, a check found a change, or a file could not be read or written"
        },
        {
          "code": 2,
          "meaning": "Usage error: an unknown command or option, a missing or extra argument, a path that does not exist, or an output folder kq will not clear"
        }
      ],
      "examples": [
        {
          "command": "kq dissolve as-is --into next models/shop",
          "description": "Fold the as-is plateau into the next one, after asking."
        },
        {
          "command": "kq dissolve as-is --into next --dry-run models/shop",
          "description": "Show what that would do."
        }
      ]
    },
    {
      "package": "@extenza-works/kanoniq-app-cli",
      "command": "plan",
      "name": "plan",
      "synopsis": "kq plan [options] [<path>]",
      "summary": "Print the model's data migrations, gap by gap, in time order; write nothing",
      "description": "Print every data migration of the model a path belongs to, gap by gap between its plateaus and in time order within each: its dates, its name or Code, each Domain Object whose authority it moves and from which holding to which, and whether it is derived. A derived orphan is left out. Writes nothing.",
      "positionals": [
        {
          "name": "path",
          "required": false,
          "repeatable": false,
          "description": "A file or folder of the model. Default: the current directory."
        }
      ],
      "options": [
        {
          "name": "format",
          "type": "string",
          "multiple": false,
          "required": false,
          "value": "format",
          "allowed": [
            "text",
            "json",
            "markdown"
          ],
          "default": "text",
          "description": "How the plan is written: a block of lines per gap, one JSON document of its rows, or the migration plan document in Markdown."
        },
        {
          "name": "help",
          "short": "h",
          "type": "boolean",
          "multiple": false,
          "required": false,
          "description": "Show this help."
        }
      ],
      "environment": [
        {
          "name": "KANONIQ_TELEMETRY",
          "description": "off, 0 or false stops kq reporting the run; so does DO_NOT_TRACK=1."
        }
      ],
      "exitCodes": [
        {
          "code": 0,
          "meaning": "Done"
        },
        {
          "code": 1,
          "meaning": "Failed: the model has an error, a check found a change, or a file could not be read or written"
        },
        {
          "code": 2,
          "meaning": "Usage error: an unknown command or option, a missing or extra argument, a path that does not exist, or an output folder kq will not clear"
        }
      ],
      "examples": [
        {
          "command": "kq plan models/shop",
          "description": "Show every gap and the migrations delivering it."
        },
        {
          "command": "kq plan --format markdown models/shop > migration-plan.md",
          "description": "Write the migration plan document to attach."
        }
      ]
    },
    {
      "package": "@extenza-works/kanoniq-app-cli",
      "command": "guide",
      "name": "guide",
      "synopsis": "kq guide [options] [<id>] [<path>]",
      "summary": "Show how much of Kanoniq the model puts to work, and the next steps",
      "description": "Show the Kanoniq Guide's goals and capabilities for the model a path belongs to, with the level the model reaches on each; or, given a goal's or a capability's id, its next steps, each element left with why. Reads .kq/guide.json and writes nothing. A first argument that is not a goal's or a capability's id is the path.",
      "positionals": [
        {
          "name": "id",
          "required": false,
          "repeatable": false,
          "description": "A goal's or a capability's id, such as roles. Default: every goal and capability."
        },
        {
          "name": "path",
          "required": false,
          "repeatable": false,
          "description": "A file or folder of the model. Default: the current directory."
        }
      ],
      "options": [
        {
          "name": "scope",
          "type": "string",
          "multiple": true,
          "required": false,
          "value": "path",
          "description": "Count only within this element, by its path, such as shop/sales. Default: a goal's journey, else the whole model."
        },
        {
          "name": "json",
          "type": "boolean",
          "multiple": false,
          "required": false,
          "description": "Write JSON on standard output instead of text."
        },
        {
          "name": "report",
          "type": "boolean",
          "multiple": false,
          "required": false,
          "description": "Write the model depth report: the picked goals, or every goal where none is picked, and every capability's level."
        },
        {
          "name": "help",
          "short": "h",
          "type": "boolean",
          "multiple": false,
          "required": false,
          "description": "Show this help."
        }
      ],
      "environment": [
        {
          "name": "KANONIQ_TELEMETRY",
          "description": "off, 0 or false stops kq reporting the run; so does DO_NOT_TRACK=1."
        }
      ],
      "exitCodes": [
        {
          "code": 0,
          "meaning": "Done"
        },
        {
          "code": 2,
          "meaning": "Usage error: an unknown command or option, a missing or extra argument, a path that does not exist, or an output folder kq will not clear"
        }
      ],
      "examples": [
        {
          "command": "kq guide models/shop",
          "description": "Show every goal and capability, and the level the model reaches."
        },
        {
          "command": "kq guide roles models/shop",
          "description": "Show what is left for roles, and why."
        },
        {
          "command": "kq guide --report --json models/shop > depth.json",
          "description": "Write the model depth report for a script."
        }
      ]
    },
    {
      "package": "@extenza-works/kanoniq-lib-licensing",
      "command": "license",
      "name": "license",
      "synopsis": "kq license [options]",
      "summary": "Show every license kq finds, what each grants, and the status they make together",
      "description": "Show every license kq finds, where it found each, its plan, dates and status, and the status they make together. Always exits 0.",
      "positionals": [],
      "options": [
        {
          "name": "license",
          "type": "string",
          "multiple": true,
          "required": false,
          "value": "file",
          "description": "Read a license from this file, as well as KANONIQ_LICENSE and the configuration directory."
        },
        {
          "name": "help",
          "short": "h",
          "type": "boolean",
          "multiple": false,
          "required": false,
          "description": "Show this help."
        }
      ],
      "environment": [
        {
          "name": "KANONIQ_LICENSE",
          "description": "A license's text, read as well as each --license file and the configuration directory."
        },
        {
          "name": "KANONIQ_TELEMETRY",
          "description": "off, 0 or false stops kq reporting the run; so does DO_NOT_TRACK=1."
        }
      ],
      "exitCodes": [
        {
          "code": 0,
          "meaning": "Done"
        },
        {
          "code": 2,
          "meaning": "Usage error: an unknown command or option, a missing or extra argument, a path that does not exist, or an output folder kq will not clear"
        }
      ],
      "examples": [
        {
          "command": "kq license --license team.license",
          "description": "Show that file's license with the others kq finds."
        }
      ]
    },
    {
      "package": "@extenza-works/kanoniq-lib-licensing",
      "command": "login",
      "name": "login",
      "synopsis": "kq login [options]",
      "summary": "Sign this machine in to Kanoniq, to the seat assigned to you or the free plan",
      "description": "Show a code and the Customer Hub page to confirm it at, wait while you confirm it, and keep this machine's sign-in and its lease in the configuration directory, shared with the VS Code extension. Exits 0 once signed in, 1 when the code is refused, expires or the service cannot be reached.",
      "positionals": [],
      "options": [
        {
          "name": "help",
          "short": "h",
          "type": "boolean",
          "multiple": false,
          "required": false,
          "description": "Show this help."
        }
      ],
      "environment": [
        {
          "name": "KANONIQ_LICENSE_SERVICE",
          "description": "The license service to sign in and renew leases at, such as a local Worker; the production one by default."
        },
        {
          "name": "KANONIQ_TELEMETRY",
          "description": "off, 0 or false stops kq reporting the run; so does DO_NOT_TRACK=1."
        }
      ],
      "exitCodes": [
        {
          "code": 0,
          "meaning": "Done"
        },
        {
          "code": 1,
          "meaning": "Failed: the model has an error, a check found a change, or a file could not be read or written"
        },
        {
          "code": 2,
          "meaning": "Usage error: an unknown command or option, a missing or extra argument, a path that does not exist, or an output folder kq will not clear"
        }
      ],
      "examples": [
        {
          "command": "kq login",
          "description": "Sign in, then confirm the code in your browser."
        }
      ]
    },
    {
      "package": "@extenza-works/kanoniq-lib-licensing",
      "command": "logout",
      "name": "logout",
      "synopsis": "kq logout [options]",
      "summary": "Sign this machine out of Kanoniq",
      "description": "Release this machine at the license service and forget its sign-in and lease. Exits 0 whether or not the service is reached, and says when it was not.",
      "positionals": [],
      "options": [
        {
          "name": "help",
          "short": "h",
          "type": "boolean",
          "multiple": false,
          "required": false,
          "description": "Show this help."
        }
      ],
      "environment": [
        {
          "name": "KANONIQ_LICENSE_SERVICE",
          "description": "The license service to sign in and renew leases at, such as a local Worker; the production one by default."
        },
        {
          "name": "KANONIQ_TELEMETRY",
          "description": "off, 0 or false stops kq reporting the run; so does DO_NOT_TRACK=1."
        }
      ],
      "exitCodes": [
        {
          "code": 0,
          "meaning": "Done"
        },
        {
          "code": 2,
          "meaning": "Usage error: an unknown command or option, a missing or extra argument, a path that does not exist, or an output folder kq will not clear"
        }
      ],
      "examples": [
        {
          "command": "kq logout",
          "description": "Sign this machine out."
        }
      ]
    },
    {
      "package": "@extenza-works/kanoniq-export-svg",
      "command": "svg",
      "name": "svg",
      "synopsis": "kq svg [options] <path>",
      "summary": "Draw one view of the model as an SVG file",
      "description": "Draw one view of the model a path belongs to as an SVG file: the picture the editor shows, as vector shapes and text with the fonts inside it. The same model and options give the same file.",
      "feature": "svg-export",
      "positionals": [
        {
          "name": "path",
          "required": true,
          "repeatable": false,
          "description": "A file or folder of the model to draw."
        }
      ],
      "options": [
        {
          "name": "at",
          "type": "string",
          "multiple": false,
          "required": false,
          "value": "plateau",
          "description": "Draw the model as it is in this plateau, by its Code. Default: the initial plateau."
        },
        {
          "name": "to",
          "type": "string",
          "multiple": false,
          "required": false,
          "value": "plateau",
          "description": "A later plateau: draw the transition from --at to it, with what goes and what arrives marked."
        },
        {
          "name": "domain",
          "type": "string",
          "multiple": false,
          "required": false,
          "value": "path",
          "description": "Draw the layered view of this Domain, by its path (shop/orders). Default: the whole model."
        },
        {
          "name": "focus",
          "type": "string",
          "multiple": false,
          "required": false,
          "value": "path",
          "description": "Refocus the whole model on this element."
        },
        {
          "name": "lens",
          "type": "string",
          "multiple": false,
          "required": false,
          "value": "lens",
          "allowed": [
            "all",
            "implementation",
            "communication",
            "data"
          ],
          "default": "all",
          "description": "Which relationships the view draws."
        },
        {
          "name": "interfaces",
          "type": "string",
          "multiple": false,
          "required": false,
          "value": "which",
          "allowed": [
            "all",
            "used",
            "none"
          ],
          "default": "all",
          "description": "Which Interfaces the view draws."
        },
        {
          "name": "structure",
          "type": "boolean",
          "multiple": false,
          "required": false,
          "description": "Draw Realization and Containment on the layered view."
        },
        {
          "name": "channels",
          "type": "boolean",
          "multiple": false,
          "required": false,
          "description": "Draw Channels in their own band on the layered view, or inside their broker on a deployment view."
        },
        {
          "name": "hide-enablers",
          "type": "boolean",
          "multiple": false,
          "required": false,
          "description": "Leave out the Enablers band, or an Enabler Domain's callers, on the layered view."
        },
        {
          "name": "contexts",
          "type": "boolean",
          "multiple": false,
          "required": false,
          "description": "Draw each bounded context's boundary on the layered view, and the lines crossing one in the crossing color."
        },
        {
          "name": "functions",
          "type": "boolean",
          "multiple": false,
          "required": false,
          "description": "Add the layered view's Functions band, each Function over the Components realizing it."
        },
        {
          "name": "iam-idp",
          "type": "string",
          "multiple": false,
          "required": false,
          "value": "path",
          "description": "Draw the IAM view of this Identity Provider, by its path."
        },
        {
          "name": "iam-platform",
          "type": "string",
          "multiple": false,
          "required": false,
          "value": "path",
          "description": "Draw the IAM view of this Platform or monolith, by its path."
        },
        {
          "name": "other-providers",
          "type": "boolean",
          "multiple": false,
          "required": false,
          "description": "Add the other providers' Roles, dimmed, to an Identity Provider's IAM view."
        },
        {
          "name": "job-roles",
          "type": "boolean",
          "multiple": false,
          "required": false,
          "description": "Add the job roles holding the IAM view's Roles, in a band of their own."
        },
        {
          "name": "motivation",
          "type": "string",
          "multiple": false,
          "required": false,
          "value": "path",
          "description": "Draw the motivation view of this Ecosystem, by its path."
        },
        {
          "name": "no-realizations",
          "type": "boolean",
          "multiple": false,
          "required": false,
          "description": "Leave out the motivation view's Realized by band and its lines."
        },
        {
          "name": "value-stream",
          "type": "string",
          "multiple": false,
          "required": false,
          "value": "path",
          "description": "Draw the value-stream view of this value stream, by its path."
        },
        {
          "name": "impact-map",
          "type": "string",
          "multiple": false,
          "required": false,
          "value": "path",
          "description": "Draw the impact map of this Goal, by its path."
        },
        {
          "name": "no-components",
          "type": "boolean",
          "multiple": false,
          "required": false,
          "description": "Leave out the impact map's Built by band and its lines."
        },
        {
          "name": "env",
          "type": "string",
          "multiple": false,
          "required": false,
          "value": "path",
          "description": "Draw the deployment view of this stage, by its path (shop/PRD)."
        },
        {
          "name": "process",
          "type": "string",
          "multiple": false,
          "required": false,
          "value": "path",
          "description": "Draw the process view of this business process, by its path."
        },
        {
          "name": "data-flow",
          "type": "string",
          "multiple": false,
          "required": false,
          "value": "path",
          "description": "Draw the data-flow view of this value stream stage, by its path."
        },
        {
          "name": "scenario",
          "type": "string",
          "multiple": false,
          "required": false,
          "value": "path",
          "description": "Draw the scenario view of this scenario, by its path, at one plateau: it has no transition, so it takes no --to."
        },
        {
          "name": "context-map",
          "type": "string",
          "multiple": false,
          "required": false,
          "value": "path",
          "description": "Draw the context map of this Ecosystem, by its path, at one plateau: it has no transition, so it takes no --to."
        },
        {
          "name": "theme",
          "type": "string",
          "multiple": false,
          "required": false,
          "value": "theme",
          "allowed": [
            "light",
            "dark"
          ],
          "default": "light",
          "description": "The colors the view is drawn in."
        },
        {
          "name": "out",
          "type": "string",
          "multiple": false,
          "required": false,
          "value": "file",
          "description": "Where to write; - for standard output. Default: <model>.svg, <model>-<domain>.svg for a Domain's view, <model>-iam-idp-<path>.svg or <model>-iam-platform-<path>.svg for an IAM view, <model>-motivation-<path>.svg for a motivation view, <model>-value-stream-<path>.svg for a value-stream view, <model>-impact-map-<path>.svg for an impact map, <model>-env-<path>.svg for a deployment view, <model>-process-<path>.svg for a process view, <model>-data-flow-<path>.svg for a data-flow view, or <model>-scenario-<path>.svg for a scenario view, or <model>-context-map-<path>.svg for a context map, in the current directory."
        },
        {
          "name": "license",
          "type": "string",
          "multiple": true,
          "required": false,
          "value": "file",
          "description": "Read a license from this file, as well as KANONIQ_LICENSE and the configuration directory."
        },
        {
          "name": "help",
          "short": "h",
          "type": "boolean",
          "multiple": false,
          "required": false,
          "description": "Show this help."
        }
      ],
      "environment": [
        {
          "name": "KANONIQ_LICENSE",
          "description": "A license's text, read as well as each --license file and the configuration directory."
        },
        {
          "name": "KANONIQ_TELEMETRY",
          "description": "off, 0 or false stops kq reporting the run; so does DO_NOT_TRACK=1."
        }
      ],
      "exitCodes": [
        {
          "code": 0,
          "meaning": "Done"
        },
        {
          "code": 1,
          "meaning": "Failed: the model has an error, a check found a change, or a file could not be read or written"
        },
        {
          "code": 2,
          "meaning": "Usage error: an unknown command or option, a missing or extra argument, a path that does not exist, or an output folder kq will not clear"
        },
        {
          "code": 3,
          "meaning": "A paid feature that no license found grants"
        }
      ],
      "examples": [
        {
          "command": "kq svg models/my-model",
          "description": "Draw the whole model to my-model.svg."
        },
        {
          "command": "kq svg --domain shop/selling models/my-model",
          "description": "Draw the Selling Domain's layered view to my-model-shop-selling.svg."
        },
        {
          "command": "kq svg --at as-is --to to-be models/my-model",
          "description": "Draw what goes and what arrives between two plateaus."
        },
        {
          "command": "kq svg --motivation shop models/my-model",
          "description": "Draw the Shop Ecosystem's motivation view to my-model-motivation-shop.svg."
        },
        {
          "command": "kq svg --value-stream shop/order models/my-model",
          "description": "Draw the Order value stream's view to my-model-value-stream-shop-order.svg."
        },
        {
          "command": "kq svg --process shop/fulfil models/my-model",
          "description": "Draw the Fulfil process's view to my-model-process-shop-fulfil.svg."
        },
        {
          "command": "kq svg --data-flow shop/order/pay models/my-model",
          "description": "Draw the Pay stage's data flow to my-model-data-flow-shop-order-pay.svg."
        },
        {
          "command": "kq svg --scenario shop/checkout --at to-be models/my-model",
          "description": "Draw the Checkout scenario at the To be plateau to my-model-scenario-shop-checkout.svg."
        },
        {
          "command": "kq svg --context-map shop models/my-model",
          "description": "Draw the Shop Ecosystem's context map to my-model-context-map-shop.svg."
        },
        {
          "command": "kq svg --impact-map shop/growth models/my-model",
          "description": "Draw the Growth goal's impact map to my-model-impact-map-shop-growth.svg."
        },
        {
          "command": "kq svg --env shop/PRD models/my-model",
          "description": "Draw what runs in the Shop Ecosystem's PRD stage to my-model-env-shop-PRD.svg."
        },
        {
          "command": "kq svg --out - models/my-model > view.svg",
          "description": "Write the SVG to standard output."
        }
      ]
    },
    {
      "package": "@extenza-works/kanoniq-export-png",
      "command": "png",
      "name": "png",
      "synopsis": "kq png [options] <path>",
      "summary": "Draw one view of the model as a PNG file",
      "description": "Draw one view of the model a path belongs to as a PNG file: the picture kq svg draws, rasterized, with the view's title and description in the file. The same model and options give the same file.",
      "feature": "png-export",
      "positionals": [
        {
          "name": "path",
          "required": true,
          "repeatable": false,
          "description": "A file or folder of the model to draw."
        }
      ],
      "options": [
        {
          "name": "at",
          "type": "string",
          "multiple": false,
          "required": false,
          "value": "plateau",
          "description": "Draw the model as it is in this plateau, by its Code. Default: the initial plateau."
        },
        {
          "name": "to",
          "type": "string",
          "multiple": false,
          "required": false,
          "value": "plateau",
          "description": "A later plateau: draw the transition from --at to it, with what goes and what arrives marked."
        },
        {
          "name": "domain",
          "type": "string",
          "multiple": false,
          "required": false,
          "value": "path",
          "description": "Draw the layered view of this Domain, by its path (shop/orders). Default: the whole model."
        },
        {
          "name": "focus",
          "type": "string",
          "multiple": false,
          "required": false,
          "value": "path",
          "description": "Refocus the whole model on this element."
        },
        {
          "name": "lens",
          "type": "string",
          "multiple": false,
          "required": false,
          "value": "lens",
          "allowed": [
            "all",
            "implementation",
            "communication",
            "data"
          ],
          "default": "all",
          "description": "Which relationships the view draws."
        },
        {
          "name": "interfaces",
          "type": "string",
          "multiple": false,
          "required": false,
          "value": "which",
          "allowed": [
            "all",
            "used",
            "none"
          ],
          "default": "all",
          "description": "Which Interfaces the view draws."
        },
        {
          "name": "structure",
          "type": "boolean",
          "multiple": false,
          "required": false,
          "description": "Draw Realization and Containment on the layered view."
        },
        {
          "name": "channels",
          "type": "boolean",
          "multiple": false,
          "required": false,
          "description": "Draw Channels in their own band on the layered view, or inside their broker on a deployment view."
        },
        {
          "name": "hide-enablers",
          "type": "boolean",
          "multiple": false,
          "required": false,
          "description": "Leave out the Enablers band, or an Enabler Domain's callers, on the layered view."
        },
        {
          "name": "contexts",
          "type": "boolean",
          "multiple": false,
          "required": false,
          "description": "Draw each bounded context's boundary on the layered view, and the lines crossing one in the crossing color."
        },
        {
          "name": "functions",
          "type": "boolean",
          "multiple": false,
          "required": false,
          "description": "Add the layered view's Functions band, each Function over the Components realizing it."
        },
        {
          "name": "iam-idp",
          "type": "string",
          "multiple": false,
          "required": false,
          "value": "path",
          "description": "Draw the IAM view of this Identity Provider, by its path."
        },
        {
          "name": "iam-platform",
          "type": "string",
          "multiple": false,
          "required": false,
          "value": "path",
          "description": "Draw the IAM view of this Platform or monolith, by its path."
        },
        {
          "name": "other-providers",
          "type": "boolean",
          "multiple": false,
          "required": false,
          "description": "Add the other providers' Roles, dimmed, to an Identity Provider's IAM view."
        },
        {
          "name": "job-roles",
          "type": "boolean",
          "multiple": false,
          "required": false,
          "description": "Add the job roles holding the IAM view's Roles, in a band of their own."
        },
        {
          "name": "motivation",
          "type": "string",
          "multiple": false,
          "required": false,
          "value": "path",
          "description": "Draw the motivation view of this Ecosystem, by its path."
        },
        {
          "name": "no-realizations",
          "type": "boolean",
          "multiple": false,
          "required": false,
          "description": "Leave out the motivation view's Realized by band and its lines."
        },
        {
          "name": "value-stream",
          "type": "string",
          "multiple": false,
          "required": false,
          "value": "path",
          "description": "Draw the value-stream view of this value stream, by its path."
        },
        {
          "name": "impact-map",
          "type": "string",
          "multiple": false,
          "required": false,
          "value": "path",
          "description": "Draw the impact map of this Goal, by its path."
        },
        {
          "name": "no-components",
          "type": "boolean",
          "multiple": false,
          "required": false,
          "description": "Leave out the impact map's Built by band and its lines."
        },
        {
          "name": "env",
          "type": "string",
          "multiple": false,
          "required": false,
          "value": "path",
          "description": "Draw the deployment view of this stage, by its path (shop/PRD)."
        },
        {
          "name": "process",
          "type": "string",
          "multiple": false,
          "required": false,
          "value": "path",
          "description": "Draw the process view of this business process, by its path."
        },
        {
          "name": "data-flow",
          "type": "string",
          "multiple": false,
          "required": false,
          "value": "path",
          "description": "Draw the data-flow view of this value stream stage, by its path."
        },
        {
          "name": "scenario",
          "type": "string",
          "multiple": false,
          "required": false,
          "value": "path",
          "description": "Draw the scenario view of this scenario, by its path, at one plateau: it has no transition, so it takes no --to."
        },
        {
          "name": "context-map",
          "type": "string",
          "multiple": false,
          "required": false,
          "value": "path",
          "description": "Draw the context map of this Ecosystem, by its path, at one plateau: it has no transition, so it takes no --to."
        },
        {
          "name": "theme",
          "type": "string",
          "multiple": false,
          "required": false,
          "value": "theme",
          "allowed": [
            "light",
            "dark"
          ],
          "default": "light",
          "description": "The colors the view is drawn in."
        },
        {
          "name": "scale",
          "type": "string",
          "multiple": false,
          "required": false,
          "value": "n",
          "default": "2",
          "description": "Pixels to each unit of the drawing, more than 0 and at most 8."
        },
        {
          "name": "out",
          "type": "string",
          "multiple": false,
          "required": false,
          "value": "file",
          "description": "Where to write. Default: <model>.png, <model>-<domain>.png for a Domain's view, <model>-iam-idp-<path>.png or <model>-iam-platform-<path>.png for an IAM view, <model>-motivation-<path>.png for a motivation view, <model>-value-stream-<path>.png for a value-stream view, <model>-impact-map-<path>.png for an impact map, <model>-env-<path>.png for a deployment view, <model>-process-<path>.png for a process view, <model>-data-flow-<path>.png for a data-flow view, <model>-scenario-<path>.png for a scenario view, or <model>-context-map-<path>.png for a context map, in the current directory."
        },
        {
          "name": "license",
          "type": "string",
          "multiple": true,
          "required": false,
          "value": "file",
          "description": "Read a license from this file, as well as KANONIQ_LICENSE and the configuration directory."
        },
        {
          "name": "help",
          "short": "h",
          "type": "boolean",
          "multiple": false,
          "required": false,
          "description": "Show this help."
        }
      ],
      "environment": [
        {
          "name": "KANONIQ_LICENSE",
          "description": "A license's text, read as well as each --license file and the configuration directory."
        },
        {
          "name": "KANONIQ_TELEMETRY",
          "description": "off, 0 or false stops kq reporting the run; so does DO_NOT_TRACK=1."
        }
      ],
      "exitCodes": [
        {
          "code": 0,
          "meaning": "Done"
        },
        {
          "code": 1,
          "meaning": "Failed: the model has an error, a check found a change, or a file could not be read or written"
        },
        {
          "code": 2,
          "meaning": "Usage error: an unknown command or option, a missing or extra argument, a path that does not exist, or an output folder kq will not clear"
        },
        {
          "code": 3,
          "meaning": "A paid feature that no license found grants"
        }
      ],
      "examples": [
        {
          "command": "kq png models/my-model",
          "description": "Draw the whole model to my-model.png."
        },
        {
          "command": "kq png --scale 1 --domain shop/selling models/my-model",
          "description": "Draw the Selling Domain's layered view at half the default size."
        },
        {
          "command": "kq png --motivation shop --no-realizations models/my-model",
          "description": "Draw the Shop Ecosystem's motivation view without its Realized by band."
        },
        {
          "command": "kq png --value-stream shop/order models/my-model",
          "description": "Draw the Order value stream's view, its stages and what realizes each."
        },
        {
          "command": "kq png --process shop/fulfil models/my-model",
          "description": "Draw the Fulfil process in BPMN, its lanes and the parties it exchanges messages with."
        },
        {
          "command": "kq png --data-flow shop/order/pay models/my-model",
          "description": "Draw where the Pay stage's data sits, how its copies are kept and what moves it."
        },
        {
          "command": "kq png --scenario shop/checkout models/my-model",
          "description": "Draw the Checkout scenario as a sequence: which system asks or tells which, in what order."
        },
        {
          "command": "kq png --context-map shop models/my-model",
          "description": "Draw the Shop Ecosystem's context map: its bounded contexts, upstream above downstream, and the patterns between them."
        },
        {
          "command": "kq png --impact-map shop/growth --no-components models/my-model",
          "description": "Draw the Growth goal's impact map, stopping at what the organization does."
        },
        {
          "command": "kq png --env shop/PRD --channels models/my-model",
          "description": "Draw what runs in the Shop Ecosystem's PRD stage, with each Channel inside its broker."
        }
      ]
    },
    {
      "package": "@extenza-works/kanoniq-export-portal",
      "command": "portal:build",
      "name": "build",
      "group": "portal",
      "synopsis": "kq portal:build --out <dir> [options] <path>",
      "summary": "Build the portal of the repository a path belongs to",
      "description": "Build the portal for the repository a path belongs to: the navigation pages in its portal/, and the editor behind each view tile, on the model in its model/.",
      "feature": "portal",
      "positionals": [
        {
          "name": "path",
          "required": true,
          "repeatable": false,
          "description": "A file or folder of the repository to build the site of."
        }
      ],
      "options": [
        {
          "name": "out",
          "type": "string",
          "multiple": false,
          "required": true,
          "value": "dir",
          "description": "Where to write the site. Cleared first; refused when it is the repository, holds it, or holds files kq portal:build did not write."
        },
        {
          "name": "license",
          "type": "string",
          "multiple": true,
          "required": false,
          "value": "file",
          "description": "Read a license from this file, as well as KANONIQ_LICENSE and the configuration directory."
        },
        {
          "name": "help",
          "short": "h",
          "type": "boolean",
          "multiple": false,
          "required": false,
          "description": "Show this help."
        }
      ],
      "environment": [
        {
          "name": "KANONIQ_LICENSE",
          "description": "A license's text, read as well as each --license file and the configuration directory."
        },
        {
          "name": "KANONIQ_TELEMETRY",
          "description": "off, 0 or false stops kq reporting the run; so does DO_NOT_TRACK=1."
        }
      ],
      "exitCodes": [
        {
          "code": 0,
          "meaning": "Done"
        },
        {
          "code": 1,
          "meaning": "Failed: the model has an error, a check found a change, or a file could not be read or written"
        },
        {
          "code": 2,
          "meaning": "Usage error: an unknown command or option, a missing or extra argument, a path that does not exist, or an output folder kq will not clear"
        },
        {
          "code": 3,
          "meaning": "A paid feature that no license found grants"
        }
      ],
      "examples": [
        {
          "command": "kq portal:build models/my-model --out site",
          "description": "Build the site of the repository models/my-model belongs to into site/."
        }
      ]
    },
    {
      "package": "@extenza-works/kanoniq-export-threats",
      "command": "threats:init",
      "name": "init",
      "group": "threats",
      "synopsis": "kq threats:init [options] [<path>]",
      "summary": "Declare the STRIDE framework in the repository",
      "description": "Declare the STRIDE framework in the repository a path belongs to: add stride and its six requirement ids, spoofing, tampering, repudiation, information-disclosure, denial-of-service, elevation-of-privilege, to the frameworks in its kanoniq.repository.json, every one but repudiation marked checkable, so a policy may serve stride/<id> and the coverage lint reports the five no policy serves. Where the file already declares stride, in any form, nothing is written: the declaration is the repository's to edit.",
      "positionals": [
        {
          "name": "path",
          "required": false,
          "repeatable": false,
          "description": "A file or folder of the repository. Default: the current directory."
        }
      ],
      "options": [
        {
          "name": "check",
          "type": "boolean",
          "multiple": false,
          "required": false,
          "description": "Write nothing; exit 1 if stride would be added."
        },
        {
          "name": "help",
          "short": "h",
          "type": "boolean",
          "multiple": false,
          "required": false,
          "description": "Show this help."
        }
      ],
      "environment": [
        {
          "name": "KANONIQ_TELEMETRY",
          "description": "off, 0 or false stops kq reporting the run; so does DO_NOT_TRACK=1."
        }
      ],
      "exitCodes": [
        {
          "code": 0,
          "meaning": "Done"
        },
        {
          "code": 1,
          "meaning": "Failed: the model has an error, a check found a change, or a file could not be read or written"
        },
        {
          "code": 2,
          "meaning": "Usage error: an unknown command or option, a missing or extra argument, a path that does not exist, or an output folder kq will not clear"
        }
      ],
      "examples": [
        {
          "command": "kq threats:init",
          "description": "Declare stride in the repository the current directory belongs to."
        },
        {
          "command": "kq threats:init --check models/shop",
          "description": "Fail where the repository models/shop belongs to does not declare stride yet."
        }
      ]
    },
    {
      "package": "@extenza-works/kanoniq-export-threats",
      "command": "threats:list",
      "name": "list",
      "group": "threats",
      "synopsis": "kq threats:list --format <format> [options] [<path>]",
      "summary": "Write the threat list of a repository's model",
      "description": "Write the threat list of the model a path belongs to: per call, leg or sync that crosses a trust boundary, per stage pair, per STRIDE category, each threat with its catalog line, its stage pair and its state, open, exempted with its reason and review date, or not checked. A category no catalog line checks for a crossing, repudiation always, is listed as not checked, never as passing. The repository must declare stride, which kq threats:init writes. The run exits 0 whatever the threats: the list is a report, and kq validate is the check.",
      "feature": "threat-modeling",
      "positionals": [
        {
          "name": "path",
          "required": false,
          "repeatable": false,
          "description": "A file or folder of the repository. Default: the current directory."
        }
      ],
      "options": [
        {
          "name": "format",
          "type": "string",
          "multiple": false,
          "required": true,
          "value": "format",
          "description": "The list's format: html, csv, sarif."
        },
        {
          "name": "out",
          "type": "string",
          "multiple": false,
          "required": false,
          "value": "file",
          "description": "Where to write the list. Default: standard output."
        },
        {
          "name": "help",
          "short": "h",
          "type": "boolean",
          "multiple": false,
          "required": false,
          "description": "Show this help."
        }
      ],
      "environment": [
        {
          "name": "KANONIQ_TELEMETRY",
          "description": "off, 0 or false stops kq reporting the run; so does DO_NOT_TRACK=1."
        }
      ],
      "exitCodes": [
        {
          "code": 0,
          "meaning": "Done"
        },
        {
          "code": 1,
          "meaning": "Failed: the model has an error, a check found a change, or a file could not be read or written"
        },
        {
          "code": 2,
          "meaning": "Usage error: an unknown command or option, a missing or extra argument, a path that does not exist, or an output folder kq will not clear"
        },
        {
          "code": 3,
          "meaning": "A paid feature that no license found grants"
        }
      ],
      "examples": [
        {
          "command": "kq threats:list --format html --out threats.html",
          "description": "Write the threat list of the repository the current directory belongs to as one HTML page."
        },
        {
          "command": "kq threats:list models/shop --format sarif > threats.sarif",
          "description": "Write it as a SARIF log, each threat a result carrying its STRIDE requirement."
        }
      ]
    }
  ]
}
