{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://raw.githubusercontent.com/api-evangelist/acronis/main/json-schema/acronis-setting-schema.json",
  "title": "setting",
  "x-generated": "2026-10-27",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/acronis-applications-api-openapi.yml#/components/schemas/setting",
  "type": "object",
  "required": [
    "name",
    "effective"
  ],
  "properties": {
    "name": {
      "description": "Name of the setting, for internal use by the platform and applications. Serves as the setting's ID.",
      "type": "string"
    },
    "application_id": {
      "$ref": "#/$defs/uuid"
    },
    "own": {
      "description": "Data which was set for this tenant.",
      "type": [
        "object",
        "null"
      ],
      "required": [
        "value",
        "lock",
        "exclusive"
      ],
      "properties": {
        "value": {
          "description": "Value of the setting. This field can have a null value.",
          "oneOf": [
            {
              "type": "string"
            },
            {
              "type": "boolean"
            },
            {
              "type": "number"
            },
            {
              "type": "object"
            }
          ]
        },
        "lock": {
          "description": "Flag that controls whether the value can be overridden at another tenant's level.",
          "default": false,
          "type": "boolean"
        },
        "exclusive": {
          "description": "If true, the value set for this tenant does not affect inheritance; this tenant's children will inherit the value from their grandparent tenant.",
          "default": false,
          "type": "boolean"
        }
      }
    },
    "effective": {
      "description": "Inherited data. This field can have a null value.",
      "type": [
        "object",
        "null"
      ],
      "properties": {
        "owner": {
          "type": "object",
          "required": [
            "type",
            "id"
          ],
          "properties": {
            "type": {
              "description": "Type of object where this value is defined.",
              "enum": [
                "tenant",
                "user"
              ],
              "type": "string"
            },
            "id": {
              "$ref": "#/$defs/uuid"
            }
          }
        },
        "value": {
          "description": "Value of the setting. This field can have a null value.",
          "oneOf": [
            {
              "type": "string"
            },
            {
              "type": "boolean"
            },
            {
              "type": "number"
            },
            {
              "type": "object"
            }
          ]
        },
        "lock": {
          "description": "Flag that controls whether the value can be overridden at another tenant's level.",
          "type": "boolean"
        }
      }
    }
  },
  "$defs": {
    "uuid": {
      "type": "string",
      "pattern": "[0-9a-f]{8}-([0-9a-f]{4}-){3}[0-9a-f]{12}",
      "minLength": 36,
      "maxLength": 36
    }
  }
}