{
    "title": "reports from REPORT_HISTORY",
    "$schema": "http://json-schema.org/draft-04/schema#",
    "javaType": "com.sos.joc.model.reporting.ReportItems",
    "type": "object",
    "properties": {
        "deliveryDate": {
            "description": "Value is UTC timestamp in ISO 8601 YYYY-MM-DDThh:mm:ss.sZ or empty",
            "type": "string",
            "format": "date-time"
        },
        "reports": {
            "type": "array",
            "items": {
                "javaType": "com.sos.joc.model.reporting.ReportItem",
                "type": "object",
                "required": [
                    "id",
                    "runId",
                    "templateName",
                    "frequency",
                    "hits",
                    "dateFrom",
                    "dateTo",
                    "data"
                ],
                "properties": {
                    "id": {
                        "type": "number",
                        "format": "utc-millisec",
                        "minimum": 0
                    },
                    "runId": {
                        "type": "number",
                        "format": "utc-millisec",
                        "minimum": 0
                    },
                    "path": {
                        "type": "string",
                        "pattern": "^[^<>]*$",
                        "maxLength": 255
                    },
                    "title": {
                        "type": "string",
                        "pattern": "^[^<>]*$",
                        "maxLength": 255
                    },
                    "controllerId": {
                        "type": "string",
                        "pattern": "^[^/\\<>?:\"|*]*$",
                        "maxLength": 100
                    },
                    "templateName": {
                        "javaType": "com.sos.inventory.model.report.TemplateId",
                        "type": "string",
                        "enum": [
                            "WORKFLOWS_FREQUENTLY_FAILED",
                            "JOBS_FREQUENTLY_FAILED",
                            "AGENTS_PARALLEL_JOB_EXECUTIONS",
                            "JOBS_HIGH_LOW_EXECUTION_PERIODS",
                            "JOBS_EXECUTIONS_FREQUENCY",
                            "ORDERS_EXECUTIONS_FREQUENCY",
                            "WORKFLOWS_LONGEST_EXECUTION_TIMES",
                            "JOBS_LONGEST_EXECUTION_TIMES",
                            "PERIODS_MOST_ORDER_EXECUTIONS",
                            "PERIODS_MOST_JOB_EXECUTIONS",
                            "JOBS_SUCCESSFUL_EXECUTIONS",
                            "WORKFLOWS_SUCCESSFUL_EXECUTIONS"
                        ]
                    },
                    "frequency": {
                        "javaType": "com.sos.inventory.model.report.Frequency",
                        "type": "string",
                        "enum": [
                            "WEEKLY",
                            "TWO_WEEKS",
                            "MONTHLY",
                            "THREE_MONTHS",
                            "SIX_MONTHS",
                            "YEARLY",
                            "THREE_YEARS"
                        ]
                    },
                    "sort": {
                        "javaType": "com.sos.inventory.model.report.ReportOrder",
                        "type": "string",
                        "enum": [
                            "HIGHEST",
                            "LOWEST"
                        ],
                        "default": "HIGHEST"
                    },
                    "periodLength": {
                        "type": "integer",
                        "minimum": 0
                    },
                    "periodStep": {
                        "type": "integer",
                        "minimum": 0
                    },
                    "hits": {
                        "type": "integer",
                        "minimum": 1,
                        "maximum": 100
                    },
                    "dateFrom": {
                        "description": "ISO date YYYY-MM-DD",
                        "type": "string",
                        "format": "date"
                    },
                    "dateTo": {
                        "description": "ISO date YYYY-MM-DD",
                        "type": "string",
                        "format": "date"
                    },
                    "created": {
                        "description": "Value is UTC timestamp in ISO 8601 YYYY-MM-DDThh:mm:ss.sZ or empty",
                        "type": "string",
                        "format": "date-time"
                    },
                    "modified": {
                        "description": "Value is UTC timestamp in ISO 8601 YYYY-MM-DDThh:mm:ss.sZ or empty",
                        "type": "string",
                        "format": "date-time"
                    },
                    "data": {
                        "type": "array",
                        "items": {
                            "javaType": "com.sos.joc.model.reporting.ReportData",
                            "type": "object",
                            "additionalProperties": true
                        }
                    }
                },
                "additionalProperties": false
            }
        }
    },
    "additionalProperties": false
}