{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "description": "A condition determining whether or not a profession or trait should be enabled",
  "oneOf": [
    {
      "description": "A boolean, for always true or always false",
      "type": [
        "null",
        "boolean"
      ]
    },
    {
      "additionalProperties": false,
      "description": "A list of conditions, at least one of which must pass",
      "properties": {
        "any": {
          "description": "A list of conditions",
          "minItems": 1,
          "type": "array",
          "uniqueItems": true,
          "values": {
            "$ref": "../schema/condition.json"
          }
        }
      },
      "required": [
        "any"
      ],
      "type": "object"
    },
    {
      "additionalProperties": false,
      "description": "A list of conditions, all of which must pass",
      "properties": {
        "all": {
          "description": "A list of conditions",
          "minItems": 1,
          "type": "array",
          "uniqueItems": true,
          "values": {
            "$ref": "../schema/condition.json"
          }
        }
      },
      "required": [
        "all"
      ],
      "type": "object"
    },
    {
      "additionalProperties": false,
      "description": "A mod which must be present for the condition to pass",
      "properties": {
        "mod_is_present": {
          "type": "string"
        }
      },
      "required": [
        "mod_is_present"
      ],
      "type": "object"
    },
    {
      "additionalProperties": false,
      "description": "A mod which must be absent for the condition to pass",
      "properties": {
        "mod_is_absent": {
          "type": "string"
        }
      },
      "required": [
        "mod_is_absent"
      ],
      "type": "object"
    }
  ],
  "title": "Condition"
}