{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://catalog.lintel.tools/schemas/github/github-discussion/latest.json",
  "x-lintel": {
    "source": "https://www.schemastore.org/github-discussion.json",
    "sourceSha256": "14cf1562338184fa10109cfb4c7855e7070ea6339e5bc3bc83bdb6e1088aca4f",
    "fileMatch": [
      "**/.github/DISCUSSION_TEMPLATE/*.yml",
      "**/.github/DISCUSSION_TEMPLATE/*.yaml"
    ],
    "parsers": [
      "yaml"
    ]
  },
  "type": "object",
  "properties": {
    "title": {
      "description": "A default title that will be pre-populated in the discussion submission form.",
      "type": "string"
    },
    "labels": {
      "description": "Labels that will automatically be added to discussions created with this template.",
      "oneOf": [
        {
          "type": "string"
        },
        {
          "type": "array",
          "items": {
            "type": "string"
          }
        }
      ]
    },
    "body": {
      "description": "Definition of the input types in the discussion form",
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "type": {
            "type": "string",
            "enum": [
              "markdown",
              "textarea",
              "input",
              "dropdown",
              "checkboxes"
            ]
          },
          "attributes": {
            "type": "object",
            "properties": {
              "label": {
                "type": "string"
              },
              "description": {
                "type": "string"
              },
              "placeholder": {
                "type": "string"
              }
            }
          },
          "validations": {
            "type": "object",
            "properties": {
              "required": {
                "type": "boolean"
              }
            }
          }
        }
      }
    }
  },
  "required": [
    "body"
  ],
  "additionalProperties": false,
  "$comment": "https://docs.github.com/en/discussions/managing-discussions-for-your-community/syntax-for-discussion-category-forms"
}
