{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://apigenie.pl/schemas/apigenie-format-report.json",
  "title": "apigenie format --json",
  "description": "The files `apigenie format --json` formatted or, with --check, checked, in the order given. With --output, the one input file, its outcome compared with the input. Adding members keeps formatVersion; removing a member or changing its meaning or type increments it.",
  "type": "object",
  "required": ["formatVersion", "check", "files"],
  "properties": {
    "formatVersion": {
      "description": "The version of this format.",
      "const": 1
    },
    "check": {
      "description": "Whether the run was --check, which writes nothing.",
      "type": "boolean"
    },
    "files": {
      "type": "array",
      "items": {
        "type": "object",
        "required": ["path", "outcome"],
        "properties": {
          "path": {
            "description": "The file as given on the command line.",
            "type": "string"
          },
          "outcome": {
            "description": "changed: the formatted file differs from it (with --check: would be written); unchanged: it was already formatted; failed: it can't be formatted (syntax errors, not a supported document), reported in the messages on the standard error.",
            "enum": ["changed", "unchanged", "failed"]
          }
        }
      }
    }
  }
}
