Saxonberg Server API
    Preparing search index...

    Parsed command definition.

    Index

    Properties

    Top-level positionals for flat verbs. Empty array for zero-arg verbs and subcommanded verbs.

    async: boolean

    Default async-dispatch mode for this verb (default false). When true, CommandGiverMixin._executeOne detaches the controller body from the giver's own input chain at accept-time. Overridden per-invocation by the reserved --async / --sync flags.

    controller: string | undefined

    Verb-level controller template name. May be undefined when the verb declares subcommands and every subcommand carries its own controller: (Option E — analyze, measure).

    description: string
    examples: ExampleDefinition[]

    Worked invocations shown under an Examples heading (optional).

    fallthrough: boolean

    Opt-in flag permitting top-level args: AND subcommands: to coexist. When true, the matcher tries the subcommand map first; an unknown first token does NOT error — it falls through to Phase 3a, binding the token + remaining tokens against this.args. Schema-enforced: the flag REQUIRES both fields.

    filePath: string
    help: string | undefined

    Multi-line authored help prose for the verb (optional).

    payload: Record<string, OptionDefinition>

    Structured-form-only fields. Populated exclusively through CommandApi.assembleFromStructured — the text-input path doesn't surface these to the matcher at all. See command-spec.md § payload for the full shape.

    subcommands: Record<string, SubcommandDefinition>
    validators: string[]

    Verb-level validator path specs from the YAML. Resolved into _resolvedValidators by CommandApi.preloadAll; the dispatch pipeline reads only the resolved form.

    verbOptions: Record<string, OptionDefinition>
    verbs: string[]

    Methods

    • Resolve the controller template name for a given subcommand. Per-subcommand controller: wins; otherwise falls back to the verb-level controller. Returns undefined when neither is set (load-time validation prevents this for declared subcommands).

      Parameters

      • name: string

      Returns string | undefined

    • Set of all field names this verb may produce, across positional args, verb-scoped options, every subcommand's options, and every subcommand's positional args. Used by assembleFromStructured to validate incoming fields keys.

      Returns Set<string>

    • Resolve an option by long-name OR short-flag char within a scope ('verb' or a subcommand name). Returns the canonical name and its definition, or undefined when the scope doesn't declare it.

      Parameters

      • scope: string
      • nameOrShort: string

      Returns { def: OptionDefinition; name: string } | undefined