{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/opoint/json-schema/opoint-analytics-report-schema.json",
  "title": "AnalyticsReport",
  "x-generated": "2026-11-10",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/opoint-analytics-api-openapi.yml#/components/schemas/AnalyticsReport",
  "type": "object",
  "properties": {
    "id": {
      "type": "integer",
      "readOnly": true
    },
    "name": {
      "type": "string",
      "maxLength": 255
    },
    "description": {
      "type": [
        "string",
        "null"
      ],
      "maxLength": 255
    },
    "active": {
      "type": "boolean",
      "default": true
    },
    "createDate": {
      "type": [
        "string",
        "null"
      ],
      "format": "date-time",
      "default": "2026-10-08T00:59:56.598502+02:00"
    },
    "id_user": {
      "type": "integer",
      "maximum": 4294967295,
      "minimum": 0,
      "format": "int64"
    },
    "categoryId": {
      "type": "integer",
      "maximum": 4294967295,
      "minimum": 0,
      "format": "int64"
    },
    "scoringScale": {
      "allOf": [
        {
          "$ref": "#/$defs/ScoringScaleEnum"
        }
      ],
      "minimum": 0,
      "maximum": 4294967295
    },
    "scoredFields": {
      "type": [
        "integer",
        "null"
      ],
      "maximum": 65535,
      "minimum": 0
    },
    "nPrinting": {
      "type": "boolean"
    },
    "topicDisplayName": {
      "type": "string",
      "default": "Topic",
      "maxLength": 255
    },
    "topicDisplayType": {
      "allOf": [
        {
          "$ref": "#/$defs/DisplayTypeEnum"
        }
      ],
      "default": 1,
      "minimum": 0,
      "maximum": 4294967295
    },
    "topicMinSelectedValues": {
      "type": "integer",
      "maximum": 254,
      "minimum": 0,
      "default": 1
    },
    "topicMaxSelectedValues": {
      "type": "integer",
      "maximum": 254,
      "minimum": 1,
      "default": 1
    },
    "topics": {
      "type": "array",
      "items": {
        "$ref": "#/$defs/Topic"
      },
      "readOnly": true
    }
  },
  "required": [
    "categoryId",
    "id",
    "id_user",
    "nPrinting",
    "name",
    "scoringScale",
    "topics"
  ],
  "$defs": {
    "DisplayTypeEnum": {
      "enum": [
        1,
        2,
        3,
        4
      ],
      "type": "integer",
      "description": "* `1` - ComboBox\n* `2` - AutoSuggestComboBox\n* `3` - ListBox\n* `4` - AutoSuggestListBox"
    },
    "ScoringScaleEnum": {
      "enum": [
        3,
        5
      ],
      "type": "integer",
      "description": "* `3` - ThreeLevel\n* `5` - FiveLevel"
    },
    "Topic": {
      "type": "object",
      "properties": {
        "id": {
          "type": "integer",
          "readOnly": true
        },
        "name": {
          "type": "string",
          "maxLength": 255
        },
        "startDate": {
          "type": "string",
          "format": "date-time",
          "default": "2026-10-08T00:59:56.598307+02:00"
        },
        "autoApprove": {
          "type": "boolean"
        },
        "articlesCanBeApproved": {
          "type": "boolean"
        },
        "isActive": {
          "type": "boolean",
          "default": true
        },
        "parentTopicId": {
          "type": [
            "integer",
            "null"
          ],
          "maximum": 4294967295,
          "minimum": 0,
          "format": "int64"
        },
        "displayOrder": {
          "type": "integer",
          "maximum": 2147483647,
          "minimum": -2147483648
        },
        "defaultTopicId": {
          "type": [
            "integer",
            "null"
          ],
          "maximum": 4294967295,
          "minimum": 0,
          "format": "int64"
        },
        "deleted": {
          "type": [
            "string",
            "null"
          ],
          "format": "date-time"
        },
        "reportId": {
          "type": "integer"
        }
      },
      "required": [
        "articlesCanBeApproved",
        "autoApprove",
        "displayOrder",
        "id",
        "name"
      ]
    }
  }
}