{
  "openapi": "3.0.0",
  "info": {
    "title": "Task API",
    "version": "2.0.0"
  },
  "servers": [
    {
      "url": "https://api.production.de.insiders.cloud/1/rest"
    }
  ],
  "paths": {
    "/tasks/analyse": {
      "post": {
        "operationId": "Analyse",
        "requestBody": {
          "x-name": "request",
          "content": {
            "application/json": {
              "schema": {
                "nullable": false,
                "$ref": "#/components/schemas/AnalyseRequest"
              }
            }
          },
          "required": true,
          "x-position": 1
        },
        "responses": {
          "400": {
            "description": ""
          },
          "403": {
            "description": ""
          },
          "500": {
            "description": ""
          },
          "503": {
            "description": ""
          },
          "200": {
            "description": "",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/AnalyseResponse"
                }
              }
            }
          }
        },
        "security": [
          {
            "token": []
          }
        ]
      }
    },
    "/tasks/data/{taskId}": {
      "get": {
        "operationId": "Get",
        "parameters": [
          {
            "name": "taskId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-position": 1
          }
        ],
        "responses": {
          "400": {
            "description": ""
          },
          "403": {
            "description": ""
          },
          "404": {
            "description": ""
          },
          "500": {
            "description": ""
          },
          "200": {
            "description": "",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/GetResponse"
                }
              }
            }
          }
        },
        "security": [
          {
            "token": []
          }
        ]
      }
    },
    "/tasks/create": {
      "post": {
        "operationId": "Create",
        "requestBody": {
          "x-name": "request",
          "content": {
            "application/json": {
              "schema": {
                "nullable": false,
                "$ref": "#/components/schemas/CreateRequest"
              }
            }
          },
          "required": true,
          "x-position": 1
        },
        "responses": {
          "400": {
            "description": ""
          },
          "403": {
            "description": ""
          },
          "500": {
            "description": ""
          },
          "200": {
            "description": "",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CreateResponse"
                }
              }
            }
          }
        },
        "security": [
          {
            "token": []
          }
        ]
      }
    },
    "/tasks/{taskId}": {
      "delete": {
        "operationId": "Delete",
        "parameters": [
          {
            "name": "taskId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-position": 1
          }
        ],
        "responses": {
          "400": {
            "description": ""
          },
          "403": {
            "description": ""
          },
          "404": {
            "description": ""
          },
          "500": {
            "description": ""
          },
          "200": {
            "description": ""
          }
        },
        "security": [
          {
            "token": []
          }
        ]
      }
    },
    "/tasks/info": {
      "get": {
        "operationId": "GetInfo",
        "parameters": [
          {
            "name": "subsystem",
            "in": "query",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "category",
            "in": "query",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "id",
            "in": "query",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "state",
            "in": "query",
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "400": {
            "description": ""
          },
          "403": {
            "description": ""
          },
          "500": {
            "description": ""
          },
          "200": {
            "description": "",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/GetInfoResponse"
                }
              }
            }
          }
        },
        "security": [
          {
            "token": []
          }
        ]
      }
    },
    "/tasks/learn/{taskId}": {
      "put": {
        "operationId": "Learn",
        "parameters": [
          {
            "name": "taskId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-position": 1
          }
        ],
        "requestBody": {
          "x-name": "body",
          "content": {
            "application/json": {
              "schema": {
                "nullable": false,
                "$ref": "#/components/schemas/LearnRequestBody"
              }
            }
          },
          "required": true,
          "x-position": 2
        },
        "responses": {
          "400": {
            "description": ""
          },
          "403": {
            "description": ""
          },
          "404": {
            "description": ""
          },
          "500": {
            "description": ""
          },
          "503": {
            "description": ""
          },
          "200": {
            "description": ""
          }
        },
        "security": [
          {
            "token": []
          }
        ]
      }
    },
    "/tasks/lock": {
      "post": {
        "operationId": "StartProcessing",
        "requestBody": {
          "x-name": "request",
          "content": {
            "application/json": {
              "schema": {
                "nullable": false,
                "$ref": "#/components/schemas/StartProcessingRequest"
              }
            }
          },
          "required": true,
          "x-position": 1
        },
        "responses": {
          "400": {
            "description": ""
          },
          "403": {
            "description": ""
          },
          "404": {
            "description": ""
          },
          "500": {
            "description": ""
          },
          "200": {
            "description": "",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/StartProcessingResponse"
                }
              }
            }
          }
        },
        "security": [
          {
            "token": []
          }
        ]
      }
    },
    "/tasks/lock/{taskId}": {
      "post": {
        "operationId": "FinishProcessing",
        "parameters": [
          {
            "name": "taskId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-position": 1
          }
        ],
        "requestBody": {
          "x-name": "body",
          "content": {
            "application/json": {
              "schema": {
                "nullable": true,
                "$ref": "#/components/schemas/FinishProcessingRequestBody"
              }
            }
          },
          "x-position": 2
        },
        "responses": {
          "400": {
            "description": ""
          },
          "403": {
            "description": ""
          },
          "404": {
            "description": ""
          },
          "500": {
            "description": ""
          },
          "200": {
            "description": ""
          }
        },
        "security": [
          {
            "token": []
          }
        ]
      }
    },
    "/tasks/file/{taskId}/{type}/{fileId}": {
      "get": {
        "operationId": "GetFile",
        "parameters": [
          {
            "name": "taskId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-position": 1
          },
          {
            "name": "type",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-position": 2
          },
          {
            "name": "fileId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-position": 3
          }
        ],
        "responses": {
          "400": {
            "description": ""
          },
          "403": {
            "description": ""
          },
          "404": {
            "description": ""
          },
          "500": {
            "description": ""
          },
          "200": {
            "description": "",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/GetFileResponse"
                }
              },
              "application/pdf": {
                "schema": {
                  "type": "string",
                  "format": "binary"
                }
              },
              "application/msword": {
                "schema": {
                  "type": "string",
                  "format": "binary"
                }
              },
              "application/vnd.ms-excel": {
                "schema": {
                  "type": "string",
                  "format": "binary"
                }
              },
              "application/vnd.ms-powerpoint": {
                "schema": {
                  "type": "string",
                  "format": "binary"
                }
              },
              "application/vnd.openxmlformats-officedocument.presentationml.presentation": {
                "schema": {
                  "type": "string",
                  "format": "binary"
                }
              },
              "application/vnd.openxmlformats-officedocument.presentationml.slideshow": {
                "schema": {
                  "type": "string",
                  "format": "binary"
                }
              },
              "application/vnd.openxmlformats-officedocument.spreadsheetml.sheet": {
                "schema": {
                  "type": "string",
                  "format": "binary"
                }
              },
              "application/vnd.openxmlformats-officedocument.wordprocessingml.document": {
                "schema": {
                  "type": "string",
                  "format": "binary"
                }
              },
              "application/octet-stream": {
                "schema": {
                  "type": "string",
                  "format": "binary"
                }
              },
              "application/xml": {
                "schema": {
                  "type": "string",
                  "format": "binary"
                }
              },
              "application/vnd.oasis.opendocument.presentation": {
                "schema": {
                  "type": "string",
                  "format": "binary"
                }
              },
              "application/vnd.oasis.opendocument.spreadsheet": {
                "schema": {
                  "type": "string",
                  "format": "binary"
                }
              },
              "application/vnd.oasis.opendocument.text": {
                "schema": {
                  "type": "string",
                  "format": "binary"
                }
              },
              "message/rfc822": {
                "schema": {
                  "type": "string",
                  "format": "binary"
                }
              },
              "image/tiff": {
                "schema": {
                  "type": "string",
                  "format": "binary"
                }
              },
              "image/png": {
                "schema": {
                  "type": "string",
                  "format": "binary"
                }
              },
              "image/jpeg": {
                "schema": {
                  "type": "string",
                  "format": "binary"
                }
              },
              "image/bmp": {
                "schema": {
                  "type": "string",
                  "format": "binary"
                }
              },
              "image/gif": {
                "schema": {
                  "type": "string",
                  "format": "binary"
                }
              },
              "text/html": {
                "schema": {
                  "type": "string",
                  "format": "binary"
                }
              },
              "text/plain": {
                "schema": {
                  "type": "string",
                  "format": "binary"
                }
              },
              "text/rtf": {
                "schema": {
                  "type": "string",
                  "format": "binary"
                }
              },
              "text/xml": {
                "schema": {
                  "type": "string",
                  "format": "binary"
                }
              }
            }
          }
        },
        "security": [
          {
            "token": []
          }
        ]
      }
    },
    "/tasks/file/{taskId}/{type}/{fileId}/{pageNumber}": {
      "get": {
        "operationId": "GetPage",
        "parameters": [
          {
            "name": "taskId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-position": 1
          },
          {
            "name": "type",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-position": 2
          },
          {
            "name": "fileId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-position": 3
          },
          {
            "name": "pageNumber",
            "in": "path",
            "required": true,
            "schema": {
              "type": "integer",
              "format": "int32"
            },
            "x-position": 4
          }
        ],
        "responses": {
          "400": {
            "description": ""
          },
          "403": {
            "description": ""
          },
          "404": {
            "description": ""
          },
          "500": {
            "description": ""
          },
          "200": {
            "description": "",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/GetFileResponse"
                }
              },
              "application/pdf": {
                "schema": {
                  "type": "string",
                  "format": "binary"
                }
              },
              "application/msword": {
                "schema": {
                  "type": "string",
                  "format": "binary"
                }
              },
              "application/vnd.ms-excel": {
                "schema": {
                  "type": "string",
                  "format": "binary"
                }
              },
              "application/vnd.ms-powerpoint": {
                "schema": {
                  "type": "string",
                  "format": "binary"
                }
              },
              "application/vnd.openxmlformats-officedocument.presentationml.presentation": {
                "schema": {
                  "type": "string",
                  "format": "binary"
                }
              },
              "application/vnd.openxmlformats-officedocument.presentationml.slideshow": {
                "schema": {
                  "type": "string",
                  "format": "binary"
                }
              },
              "application/vnd.openxmlformats-officedocument.spreadsheetml.sheet": {
                "schema": {
                  "type": "string",
                  "format": "binary"
                }
              },
              "application/vnd.openxmlformats-officedocument.wordprocessingml.document": {
                "schema": {
                  "type": "string",
                  "format": "binary"
                }
              },
              "application/octet-stream": {
                "schema": {
                  "type": "string",
                  "format": "binary"
                }
              },
              "application/xml": {
                "schema": {
                  "type": "string",
                  "format": "binary"
                }
              },
              "application/vnd.oasis.opendocument.presentation": {
                "schema": {
                  "type": "string",
                  "format": "binary"
                }
              },
              "application/vnd.oasis.opendocument.spreadsheet": {
                "schema": {
                  "type": "string",
                  "format": "binary"
                }
              },
              "application/vnd.oasis.opendocument.text": {
                "schema": {
                  "type": "string",
                  "format": "binary"
                }
              },
              "message/rfc822": {
                "schema": {
                  "type": "string",
                  "format": "binary"
                }
              },
              "image/tiff": {
                "schema": {
                  "type": "string",
                  "format": "binary"
                }
              },
              "image/png": {
                "schema": {
                  "type": "string",
                  "format": "binary"
                }
              },
              "image/jpeg": {
                "schema": {
                  "type": "string",
                  "format": "binary"
                }
              },
              "image/bmp": {
                "schema": {
                  "type": "string",
                  "format": "binary"
                }
              },
              "image/gif": {
                "schema": {
                  "type": "string",
                  "format": "binary"
                }
              },
              "text/html": {
                "schema": {
                  "type": "string",
                  "format": "binary"
                }
              },
              "text/plain": {
                "schema": {
                  "type": "string",
                  "format": "binary"
                }
              },
              "text/rtf": {
                "schema": {
                  "type": "string",
                  "format": "binary"
                }
              },
              "text/xml": {
                "schema": {
                  "type": "string",
                  "format": "binary"
                }
              }
            }
          }
        },
        "security": [
          {
            "token": []
          }
        ]
      }
    },
    "/tasks/reset": {
      "post": {
        "operationId": "Reset",
        "requestBody": {
          "x-name": "request",
          "content": {
            "application/json": {
              "schema": {
                "nullable": false,
                "$ref": "#/components/schemas/ResetRequest"
              }
            }
          },
          "required": true,
          "x-position": 1
        },
        "responses": {
          "400": {
            "description": ""
          },
          "403": {
            "description": ""
          },
          "500": {
            "description": ""
          },
          "200": {
            "description": "",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResetResponse"
                }
              }
            }
          }
        },
        "security": [
          {
            "token": []
          }
        ]
      }
    },
    "/tasks/version": {
      "get": {
        "operationId": "GetVersion",
        "responses": {
          "200": {
            "description": "",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/GetVersionResponse"
                }
              }
            }
          }
        },
        "security": [
          {
            "token": []
          }
        ]
      }
    }
  },
  "components": {
    "schemas": {
      "AnalyseRequest": {
        "type": "object",
        "additionalProperties": false,
        "required": [
          "task"
        ],
        "properties": {
          "task": {
            "$ref": "#/components/schemas/Task"
          },
          "timeout": {
            "type": "integer",
            "format": "int32",
            "nullable": true
          }
        }
      },
      "Task": {
        "type": "object",
        "additionalProperties": false,
        "required": [
          "subsystem"
        ],
        "properties": {
          "id": {
            "type": "string"
          },
          "subsystem": {
            "type": "string"
          },
          "category": {
            "type": "string"
          },
          "priority": {
            "type": "integer",
            "format": "int32",
            "nullable": true
          },
          "pdfConversionMode": {
            "nullable": true,
            "oneOf": [
              {
                "$ref": "#/components/schemas/PdfConversionMode"
              }
            ]
          },
          "loggingEnabled": {
            "type": "boolean",
            "nullable": true
          },
          "attributes": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/TaskAttribute"
            }
          },
          "flags": {
            "$ref": "#/components/schemas/TaskFlags"
          },
          "fields": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/FieldInitialization"
            }
          },
          "files": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/File"
            }
          },
          "processes": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/ProcessSeparation"
            }
          }
        }
      },
      "PdfConversionMode": {
        "type": "string",
        "description": "",
        "enum": [
          "Automatic",
          "Always"
        ]
      },
      "TaskAttribute": {
        "type": "object",
        "additionalProperties": false,
        "required": [
          "name",
          "value"
        ],
        "properties": {
          "name": {
            "type": "string"
          },
          "value": {
            "type": "string"
          }
        }
      },
      "TaskFlags": {
        "type": "object",
        "additionalProperties": false,
        "properties": {
          "exportVerifierDocuments": {
            "type": "boolean"
          },
          "exportSupervisorDocuments": {
            "type": "boolean"
          },
          "showAllDocumentsInVerifier": {
            "type": "boolean"
          },
          "hasDocumentSeparators": {
            "type": "boolean"
          },
          "hasProcessSeparators": {
            "type": "boolean"
          },
          "extractionDisabled": {
            "type": "boolean"
          }
        }
      },
      "FieldInitialization": {
        "type": "object",
        "additionalProperties": false,
        "required": [
          "name",
          "value"
        ],
        "properties": {
          "name": {
            "type": "string"
          },
          "value": {
            "type": "string"
          },
          "verified": {
            "type": "boolean"
          },
          "row": {
            "type": "integer",
            "format": "int32",
            "nullable": true
          }
        }
      },
      "File": {
        "type": "object",
        "additionalProperties": false,
        "required": [
          "fileData"
        ],
        "properties": {
          "id": {
            "type": "string"
          },
          "mimeType": {
            "type": "string"
          },
          "fileData": {
            "type": "string",
            "format": "byte"
          },
          "secondaryMimeType": {
            "type": "string"
          },
          "secondaryFileData": {
            "type": "string",
            "format": "byte"
          },
          "pages": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/Page"
            }
          },
          "flags": {
            "$ref": "#/components/schemas/Flags"
          }
        }
      },
      "Page": {
        "type": "object",
        "additionalProperties": false,
        "properties": {
          "flags": {
            "$ref": "#/components/schemas/Flags"
          },
          "fields": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/FieldInitialization"
            }
          }
        }
      },
      "Flags": {
        "type": "object",
        "additionalProperties": false,
        "properties": {
          "attachment": {
            "type": "boolean"
          },
          "backside": {
            "type": "boolean"
          },
          "mailbody": {
            "type": "boolean"
          }
        }
      },
      "ProcessSeparation": {
        "type": "object",
        "additionalProperties": false,
        "properties": {
          "id": {
            "type": "string"
          },
          "documents": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/DocumentSeparation"
            }
          },
          "pages": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/PageReference"
            }
          },
          "fields": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/FieldInitialization"
            }
          }
        }
      },
      "DocumentSeparation": {
        "type": "object",
        "additionalProperties": false,
        "required": [
          "pages"
        ],
        "properties": {
          "id": {
            "type": "string"
          },
          "pages": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/PageReference"
            }
          },
          "fields": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/FieldInitialization"
            }
          }
        }
      },
      "PageReference": {
        "type": "object",
        "additionalProperties": false,
        "required": [
          "fileId"
        ],
        "properties": {
          "fileId": {
            "type": "string"
          },
          "pageNumber": {
            "type": "integer",
            "format": "int32",
            "nullable": true
          }
        }
      },
      "AnalyseResponse": {
        "type": "object",
        "additionalProperties": false,
        "required": [
          "data"
        ],
        "properties": {
          "data": {
            "$ref": "#/components/schemas/ResponseData"
          }
        }
      },
      "ResponseData": {
        "type": "object",
        "additionalProperties": false,
        "required": [
          "id",
          "subsystem",
          "category",
          "processes"
        ],
        "properties": {
          "id": {
            "type": "string"
          },
          "subsystem": {
            "type": "string"
          },
          "category": {
            "type": "string"
          },
          "priority": {
            "type": "integer",
            "format": "int32"
          },
          "processes": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/Process"
            }
          },
          "attributes": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/TaskAttribute"
            }
          }
        }
      },
      "Process": {
        "type": "object",
        "additionalProperties": false,
        "properties": {
          "id": {
            "type": "string"
          },
          "documents": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/Document"
            }
          }
        }
      },
      "Document": {
        "type": "object",
        "additionalProperties": false,
        "properties": {
          "id": {
            "type": "string"
          },
          "pages": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/DocumentPage"
            }
          },
          "fields": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/Field"
            }
          },
          "tables": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/Table"
            }
          },
          "docClass": {
            "type": "string"
          },
          "docType": {
            "type": "string"
          },
          "userComment": {
            "type": "string"
          },
          "createdBy": {
            "type": "string"
          },
          "state": {
            "nullable": true,
            "oneOf": [
              {
                "$ref": "#/components/schemas/DocumentState"
              }
            ]
          },
          "documentWasDivided": {
            "type": "boolean"
          }
        }
      },
      "DocumentPage": {
        "type": "object",
        "additionalProperties": false,
        "properties": {
          "image": {
            "$ref": "#/components/schemas/Image"
          },
          "rotation": {
            "type": "number",
            "format": "float"
          },
          "attachment": {
            "type": "boolean"
          },
          "backside": {
            "type": "boolean"
          },
          "empty": {
            "type": "boolean"
          },
          "mailbody": {
            "type": "boolean"
          },
          "placeholder": {
            "type": "boolean"
          },
          "fragment": {
            "type": "boolean"
          },
          "fileTypes": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/FileType"
            }
          }
        }
      },
      "Image": {
        "type": "object",
        "additionalProperties": false,
        "properties": {
          "fileId": {
            "type": "string"
          },
          "pageNumber": {
            "type": "integer",
            "format": "int32"
          }
        }
      },
      "FileType": {
        "type": "string",
        "description": "",
        "enum": [
          "Primary",
          "Secondary",
          "Original",
          "Other"
        ]
      },
      "Field": {
        "type": "object",
        "additionalProperties": false,
        "properties": {
          "name": {
            "type": "string"
          },
          "value": {},
          "type": {
            "$ref": "#/components/schemas/FieldType"
          },
          "geo": {
            "$ref": "#/components/schemas/Geometry"
          },
          "verified": {
            "type": "boolean"
          },
          "visible": {
            "type": "boolean"
          },
          "alteredBy": {
            "type": "array",
            "items": {
              "type": "string"
            }
          },
          "verifierAction": {
            "nullable": true,
            "oneOf": [
              {
                "$ref": "#/components/schemas/FieldVerifierAction"
              }
            ]
          },
          "checkState": {
            "nullable": true,
            "oneOf": [
              {
                "$ref": "#/components/schemas/FieldCheckState"
              }
            ]
          }
        }
      },
      "FieldType": {
        "type": "string",
        "description": "",
        "enum": [
          "Bool",
          "Date",
          "String",
          "Number"
        ]
      },
      "Geometry": {
        "type": "object",
        "additionalProperties": false,
        "properties": {
          "top": {
            "type": "integer",
            "format": "int32"
          },
          "left": {
            "type": "integer",
            "format": "int32"
          },
          "width": {
            "type": "integer",
            "format": "int32"
          },
          "height": {
            "type": "integer",
            "format": "int32"
          },
          "pageIndex": {
            "type": "integer",
            "format": "int32"
          }
        }
      },
      "FieldVerifierAction": {
        "type": "string",
        "description": "",
        "enum": [
          "NoAction",
          "Imported",
          "Confirmed",
          "Changed",
          "DBLookup",
          "AutoFill",
          "OCR"
        ]
      },
      "FieldCheckState": {
        "type": "string",
        "description": "",
        "enum": [
          "OK",
          "Overridden",
          "MandatoryOverridden",
          "Disabled"
        ]
      },
      "Table": {
        "type": "object",
        "additionalProperties": false,
        "properties": {
          "name": {
            "type": "string"
          },
          "rows": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/Row"
            }
          },
          "columns": {
            "type": "array",
            "items": {
              "type": "string"
            }
          }
        }
      },
      "Row": {
        "type": "object",
        "additionalProperties": false,
        "properties": {
          "pageIndex": {
            "type": "integer",
            "format": "int32"
          },
          "cells": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/Field"
            }
          }
        }
      },
      "DocumentState": {
        "type": "string",
        "description": "",
        "enum": [
          "Analyser",
          "Supervisor",
          "Verifier",
          "Exporter",
          "Rescan",
          "PdfConversionError"
        ]
      },
      "GetResponse": {
        "type": "object",
        "additionalProperties": false,
        "required": [
          "data"
        ],
        "properties": {
          "data": {
            "$ref": "#/components/schemas/ResponseData"
          }
        }
      },
      "CreateRequest": {
        "type": "object",
        "additionalProperties": false,
        "required": [
          "task"
        ],
        "properties": {
          "task": {
            "$ref": "#/components/schemas/Task"
          },
          "callback": {
            "type": "string"
          }
        }
      },
      "CreateResponse": {
        "type": "object",
        "additionalProperties": false,
        "properties": {
          "taskId": {
            "type": "string"
          }
        }
      },
      "GetInfoResponse": {
        "type": "object",
        "additionalProperties": false,
        "properties": {
          "taskInfo": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/TaskInfo"
            }
          }
        }
      },
      "TaskInfo": {
        "type": "object",
        "additionalProperties": false,
        "properties": {
          "access": {
            "type": "string",
            "format": "date-time"
          },
          "category": {
            "type": "string"
          },
          "component": {
            "type": "string"
          },
          "id": {
            "type": "string"
          },
          "importTime": {
            "type": "string",
            "format": "date-time"
          },
          "priority": {
            "type": "integer",
            "format": "int32"
          },
          "state": {
            "type": "string"
          },
          "subsystem": {
            "type": "string"
          }
        }
      },
      "LearnRequestBody": {
        "type": "object",
        "additionalProperties": false,
        "required": [
          "learnData"
        ],
        "properties": {
          "learnData": {
            "$ref": "#/components/schemas/LearnData"
          },
          "timeout": {
            "type": "integer",
            "format": "int32",
            "nullable": true
          }
        }
      },
      "LearnData": {
        "type": "object",
        "additionalProperties": false,
        "required": [
          "subsystem",
          "category",
          "processes"
        ],
        "properties": {
          "subsystem": {
            "type": "string"
          },
          "category": {
            "type": "string"
          },
          "processes": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/Process"
            }
          }
        }
      },
      "StartProcessingRequest": {
        "type": "object",
        "additionalProperties": false,
        "required": [
          "filter",
          "system"
        ],
        "properties": {
          "filter": {
            "$ref": "#/components/schemas/TaskFilter"
          },
          "system": {
            "type": "string"
          }
        }
      },
      "TaskFilter": {
        "type": "object",
        "additionalProperties": false,
        "properties": {
          "id": {
            "type": "string"
          },
          "state": {
            "type": "string"
          },
          "subsystem": {
            "type": "string"
          }
        }
      },
      "StartProcessingResponse": {
        "type": "object",
        "additionalProperties": false,
        "properties": {
          "data": {
            "$ref": "#/components/schemas/ResponseData"
          }
        }
      },
      "FinishProcessingRequestBody": {
        "type": "object",
        "additionalProperties": false,
        "properties": {
          "error": {
            "type": "boolean",
            "nullable": true
          },
          "taskModification": {
            "$ref": "#/components/schemas/TaskModification"
          }
        }
      },
      "TaskModification": {
        "type": "object",
        "additionalProperties": false,
        "properties": {
          "error": {
            "type": "boolean",
            "nullable": true
          },
          "state": {
            "type": "string"
          },
          "priority": {
            "type": "integer",
            "format": "int32",
            "nullable": true
          },
          "processes": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/ProcessModification"
            }
          }
        }
      },
      "ProcessModification": {
        "type": "object",
        "additionalProperties": false,
        "required": [
          "id",
          "documents"
        ],
        "properties": {
          "id": {
            "type": "string"
          },
          "documents": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/DocumentModification"
            }
          }
        }
      },
      "DocumentModification": {
        "type": "object",
        "additionalProperties": false,
        "required": [
          "id"
        ],
        "properties": {
          "id": {
            "type": "string"
          },
          "userComment": {
            "type": "string"
          },
          "systemComment": {
            "type": "string"
          },
          "state": {
            "nullable": true,
            "oneOf": [
              {
                "$ref": "#/components/schemas/DocumentState"
              }
            ]
          },
          "fields": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/FieldModification"
            }
          }
        }
      },
      "FieldModification": {
        "type": "object",
        "additionalProperties": false,
        "required": [
          "name",
          "type"
        ],
        "properties": {
          "name": {
            "type": "string"
          },
          "type": {
            "$ref": "#/components/schemas/FieldType"
          },
          "value": {},
          "verified": {
            "type": "boolean",
            "nullable": true
          },
          "visible": {
            "type": "boolean",
            "nullable": true
          }
        }
      },
      "GetFileResponse": {
        "type": "object",
        "additionalProperties": false,
        "properties": {
          "mimeType": {
            "type": "string"
          },
          "data": {
            "type": "string",
            "format": "byte"
          }
        }
      },
      "ResetRequest": {
        "type": "object",
        "additionalProperties": false,
        "required": [
          "subsystem",
          "verificationState"
        ],
        "properties": {
          "subsystem": {
            "type": "string"
          },
          "taskId": {
            "type": "string"
          },
          "verificationState": {
            "$ref": "#/components/schemas/TaskVerificationState"
          }
        }
      },
      "TaskVerificationState": {
        "type": "string",
        "description": "",
        "enum": [
          "NotVerified",
          "All"
        ]
      },
      "ResetResponse": {
        "type": "object",
        "additionalProperties": false,
        "required": [
          "numTasks"
        ],
        "properties": {
          "numTasks": {
            "type": "integer",
            "format": "int32"
          }
        }
      },
      "GetVersionResponse": {
        "type": "object",
        "additionalProperties": false,
        "properties": {
          "Major": {
            "type": "string"
          },
          "Minor": {
            "type": "string"
          },
          "Patch": {
            "type": "string"
          },
          "Commit": {
            "type": "string"
          },
          "Version": {
            "type": "string"
          }
        }
      }
    },
    "securitySchemes": {
      "token": {
        "type": "http",
        "scheme": "bearer",
        "bearerFormat": "JWT"
      }
    }
  }
}