{
  "$schema": "http://json-schema.org/draft-07/schema#",
  "$id": "https://litlfred.github.io/folio-assistant/fhir-harness/schema/skills/fhir-questionnaire-wireframe/input.schema.json",
  "title": "FHIR Questionnaire Wireframe Input",
  "description": "Which built Questionnaire to render and review, against which L2 wireframe, and where the drawings and the requests for feedback go.",
  "type": "object",
  "required": [
    "questionnaire"
  ],
  "properties": {
    "questionnaire": {
      "type": "string",
      "description": "Repository-relative path of ONE built Questionnaire JSON (`fsh-generated/resources/Questionnaire-<id>.json`), never FSH. Several Questionnaires are several runs, so each carries its own fidelity findings and review."
    },
    "mode": {
      "type": "string",
      "enum": [
        "render",
        "fidelity-check",
        "wireframe-from-questionnaire"
      ],
      "default": "render",
      "description": "`render`: wireframe and form view for review. `fidelity-check`: only the field-for-field check against `wireframe`. `wireframe-from-questionnaire`: draw an L2 wireframe from a Questionnaire that has none."
    },
    "wireframe": {
      "type": "string",
      "description": "Repository-relative path of the L2 wireframe HTML the Questionnaire was derived from (the chosen `wireframe-design-review` candidate), when one exists."
    },
    "renderer": {
      "type": "string",
      "enum": [
        "lhc-forms"
      ],
      "default": "lhc-forms",
      "description": "The form-view renderer. Only the vendored NLM LHC-Forms (owner, 2026-10-14)."
    },
    "assetDir": {
      "type": "string",
      "description": "Repository-relative directory for the wireframes, captures and checks."
    },
    "suggest": {
      "type": "boolean",
      "default": true,
      "description": "Offer ✍ suggest, in its Questionnaire mode, on the form view."
    },
    "issueForm": {
      "type": "string",
      "default": "questionnaire-change.yml",
      "description": "The issue form change requests are opened with."
    },
    "channels": {
      "type": "array",
      "description": "Where the request for review goes: chosen by judgement, and more than one may be right (staging-review, the deep-link rule, point 5).",
      "items": {
        "type": "object",
        "required": [
          "kind"
        ],
        "properties": {
          "kind": {
            "type": "string",
            "enum": [
              "conversation",
              "issue",
              "pull-request"
            ]
          },
          "url": {
            "type": "string",
            "format": "uri"
          }
        }
      }
    },
    "branch": {
      "type": "string",
      "description": "The feature branch the renderings are committed on, so feature-staging publishes them."
    }
  }
}
