{
  "$schema": "http://json-schema.org/draft-07/schema#",
  "$id": "https://json.schemastore.org/gematik-tiger.json",
  "$defs": {
    "CfgExternalJarOptions-nullable": {
      "type": ["object", "null"],
      "properties": {
        "activateLogs": {
          "type": "boolean"
        },
        "activateWorkflowLogs": {
          "type": "boolean"
        },
        "arguments": {
          "type": ["array", "null"],
          "items": {
            "type": "string"
          }
        },
        "options": {
          "type": ["array", "null"],
          "items": {
            "type": "string"
          }
        },
        "workingDir": {
          "type": ["string", "null"]
        }
      }
    },
    "CfgHelmChartOptions-nullable": {
      "type": ["object", "null"],
      "properties": {
        "context": {
          "type": ["string", "null"]
        },
        "debug": {
          "type": "boolean"
        },
        "exposedPorts": {
          "type": ["array", "null"],
          "items": {
            "type": "string"
          }
        },
        "healthcheckPods": {
          "type": ["array", "null"],
          "items": {
            "type": "string"
          }
        },
        "logPods": {
          "type": ["array", "null"],
          "items": {
            "type": "string"
          }
        },
        "nameSpace": {
          "type": ["string", "null"]
        },
        "podName": {
          "type": ["string", "null"]
        },
        "values": {
          "type": ["array", "null"],
          "items": {
            "type": "string"
          }
        },
        "workingDir": {
          "type": ["string", "null"]
        }
      }
    },
    "CfgServer": {
      "type": "object",
      "properties": {
        "active": {
          "type": "boolean"
        },
        "dependsUpon": {
          "type": ["string", "null"]
        },
        "environment": {
          "type": ["array", "null"],
          "items": {
            "type": "string"
          }
        },
        "exports": {
          "type": ["array", "null"],
          "items": {
            "type": "string"
          }
        },
        "externalJarOptions": {
          "$ref": "#/$defs/CfgExternalJarOptions-nullable"
        },
        "healthcheckReturnCode": {
          "type": ["integer", "null"]
        },
        "healthcheckUrl": {
          "type": ["string", "null"]
        },
        "helmChartOptions": {
          "$ref": "#/$defs/CfgHelmChartOptions-nullable"
        },
        "hostname": {
          "type": ["string", "null"]
        },
        "logFile": {
          "type": ["string", "null"]
        },
        "source": {
          "type": ["array", "null"],
          "items": {
            "type": "string"
          }
        },
        "startupPollIntervalMs": {
          "type": ["integer", "null"]
        },
        "startupTimeoutSec": {
          "type": ["integer", "null"]
        },
        "tigerProxyConfiguration": {
          "$ref": "#/$defs/TigerProxyConfiguration-nullable"
        },
        "type": {
          "type": ["string", "null"]
        },
        "uiRank": {
          "type": "integer"
        },
        "urlMappings": {
          "type": ["array", "null"],
          "items": {
            "type": "string"
          }
        },
        "version": {
          "type": ["string", "null"]
        }
      }
    },
    "DirectReverseProxyInfo-nullable": {
      "type": ["object", "null"],
      "properties": {
        "hostname": {
          "type": ["string", "null"]
        },
        "ignoreConnectionErrors": {
          "type": "boolean"
        },
        "port": {
          "type": ["integer", "null"]
        }
      }
    },
    "ForwardProxyInfo-nullable": {
      "type": ["object", "null"],
      "properties": {
        "hostname": {
          "type": ["string", "null"]
        },
        "noProxyHosts": {
          "type": ["array", "null"],
          "items": {
            "type": "string"
          }
        },
        "password": {
          "type": ["string", "null"]
        },
        "port": {
          "type": ["integer", "null"]
        },
        "type": {
          "$ref": "#/$defs/TigerProxyType-nullable"
        },
        "username": {
          "type": ["string", "null"]
        }
      }
    },
    "Map(String,CfgServer)-nullable": {
      "type": ["object", "null"],
      "additionalProperties": {
        "$ref": "#/$defs/CfgServer"
      }
    },
    "PrivateKey-nullable": {
      "type": ["object", "null"]
    },
    "RbelModificationDescription": {
      "type": "object",
      "properties": {
        "condition": {
          "type": ["string", "null"]
        },
        "deleteAfterNExecutions": {
          "type": ["integer", "null"]
        },
        "name": {
          "type": ["string", "null"]
        },
        "regexFilter": {
          "type": ["string", "null"]
        },
        "replaceWith": {
          "type": ["string", "null"]
        },
        "targetElement": {
          "type": ["string", "null"]
        }
      }
    },
    "StoreType-nullable": {
      "anyOf": [
        {
          "type": "null"
        },
        {
          "type": "string",
          "enum": ["PKCS12", "JKS", "BKS", "PKCS8", "PKCS1"]
        }
      ]
    },
    "TigerConfigurationPkiIdentity": {
      "type": "object",
      "properties": {
        "certificate": {
          "$ref": "#/$defs/X509Certificate-nullable"
        },
        "certificateChain": {
          "type": ["array", "null"],
          "items": {
            "$ref": "#/$defs/X509Certificate"
          }
        },
        "fileLoadingInformation": {
          "$ref": "#/$defs/TigerPkiIdentityInformation-nullable"
        },
        "keyId": {
          "type": ["string", "null"]
        },
        "privateKey": {
          "$ref": "#/$defs/PrivateKey-nullable"
        }
      }
    },
    "TigerConfigurationPkiIdentity-nullable": {
      "anyOf": [
        {
          "type": "null"
        },
        {
          "$ref": "#/$defs/TigerConfigurationPkiIdentity"
        }
      ]
    },
    "TigerConfigurationRoute": {
      "type": "object",
      "properties": {
        "authentication": {
          "$ref": "#/$defs/TigerRouteAuthenticationConfiguration-nullable"
        },
        "criterions": {
          "type": ["array", "null"],
          "items": {
            "type": "string"
          }
        },
        "disableRbelLogging": {
          "type": "boolean"
        },
        "from": {
          "type": ["string", "null"]
        },
        "hosts": {
          "type": ["array", "null"],
          "items": {
            "type": "string"
          }
        },
        "to": {
          "type": ["array", "null"],
          "items": {
            "type": "string"
          }
        }
      }
    },
    "TigerFileSaveInfo-nullable": {
      "type": ["object", "null"],
      "properties": {
        "clearFileOnBoot": {
          "type": "boolean"
        },
        "filename": {
          "type": ["string", "null"]
        },
        "readFilter": {
          "type": ["string", "null"]
        },
        "sourceFile": {
          "type": ["string", "null"]
        },
        "writeToFile": {
          "type": "boolean"
        }
      }
    },
    "TigerPkiIdentityInformation-nullable": {
      "type": ["object", "null"],
      "properties": {
        "filenames": {
          "type": ["array", "null"],
          "items": {
            "type": "string"
          }
        },
        "password": {
          "type": ["string", "null"]
        },
        "storeType": {
          "$ref": "#/$defs/StoreType-nullable"
        }
      }
    },
    "TigerProxyConfiguration-nullable": {
      "type": ["object", "null"],
      "properties": {
        "activateForwardAllLogging": {
          "type": "boolean"
        },
        "activateRbelParsing": {
          "type": "boolean"
        },
        "activateRbelParsingFor": {
          "type": ["array", "null"],
          "items": {
            "type": "string"
          }
        },
        "activateTlsTermination": {
          "type": "boolean"
        },
        "activateTrafficLogging": {
          "type": "boolean"
        },
        "adminPort": {
          "type": "integer"
        },
        "connectionTimeoutInSeconds": {
          "type": "integer"
        },
        "directReverseProxy": {
          "$ref": "#/$defs/DirectReverseProxyInfo-nullable"
        },
        "downloadInitialTrafficFromEndpoints": {
          "type": "boolean"
        },
        "failOnOfflineTrafficEndpoints": {
          "type": "boolean"
        },
        "fileSaveInfo": {
          "$ref": "#/$defs/TigerFileSaveInfo-nullable"
        },
        "forwardToProxy": {
          "$ref": "#/$defs/ForwardProxyInfo-nullable"
        },
        "keyFolders": {
          "type": ["array", "null"],
          "items": {
            "type": "string"
          }
        },
        "localResources": {
          "type": "boolean"
        },
        "maximumPartialMessageAgeInSeconds": {
          "type": "integer"
        },
        "maximumTrafficDownloadPageSize": {
          "type": "integer"
        },
        "modifications": {
          "type": ["array", "null"],
          "items": {
            "$ref": "#/$defs/RbelModificationDescription"
          }
        },
        "name": {
          "type": ["string", "null"]
        },
        "notes": {
          "type": ["array", "null"],
          "items": {
            "$ref": "#/$defs/TigerProxyNoteCommand"
          }
        },
        "parsingShouldBlockCommunication": {
          "type": "boolean"
        },
        "password": {
          "type": ["string", "null"]
        },
        "perMessageBufferSizeInMb": {
          "type": "integer"
        },
        "proxiedServer": {
          "type": ["string", "null"]
        },
        "proxiedServerProtocol": {
          "type": ["string", "null"]
        },
        "proxyLogLevel": {
          "type": ["string", "null"]
        },
        "proxyPort": {
          "type": ["integer", "null"]
        },
        "proxyRoutes": {
          "type": ["array", "null"],
          "items": {
            "$ref": "#/$defs/TigerConfigurationRoute"
          }
        },
        "rbelBufferSizeInMb": {
          "type": "integer"
        },
        "rewriteHostHeader": {
          "type": "boolean"
        },
        "rewriteLocationHeader": {
          "type": "boolean"
        },
        "skipDisplayWhenMessageLargerThanKb": {
          "type": "integer"
        },
        "skipParsingWhenMessageLargerThanKb": {
          "type": "integer"
        },
        "skipTrafficEndpointsSubscription": {
          "type": "boolean"
        },
        "stompClientBufferSizeInMb": {
          "type": "integer"
        },
        "tls": {
          "$ref": "#/$defs/TigerTlsConfiguration-nullable"
        },
        "trafficDownloadPageSize": {
          "type": "integer"
        },
        "trafficEndpointConfiguration": {
          "$ref": "#/$defs/TrafficEndpointConfiguration-nullable"
        },
        "trafficEndpointFilterString": {
          "type": ["string", "null"]
        },
        "trafficEndpoints": {
          "type": ["array", "null"],
          "items": {
            "type": "string"
          }
        },
        "username": {
          "type": ["string", "null"]
        }
      }
    },
    "TigerProxyNoteCommand": {
      "type": "object",
      "properties": {
        "jexlCriterion": {
          "type": ["string", "null"]
        },
        "message": {
          "type": ["string", "null"]
        }
      }
    },
    "TigerProxyType-nullable": {
      "anyOf": [
        {
          "type": "null"
        },
        {
          "type": "string",
          "enum": ["http", "https"]
        }
      ]
    },
    "TigerRouteAuthenticationConfiguration-nullable": {
      "type": ["object", "null"],
      "properties": {
        "bearerToken": {
          "type": ["string", "null"]
        },
        "password": {
          "type": ["string", "null"]
        },
        "username": {
          "type": ["string", "null"]
        }
      }
    },
    "TigerTlsConfiguration-nullable": {
      "type": ["object", "null"],
      "properties": {
        "allowGenericFallbackIdentity": {
          "type": "boolean"
        },
        "alternativeNames": {
          "type": ["array", "null"],
          "items": {
            "type": "string"
          }
        },
        "clientSslSuites": {
          "type": ["array", "null"],
          "items": {
            "type": "string"
          }
        },
        "clientSupportedGroups": {
          "type": ["array", "null"],
          "items": {
            "type": "string"
          }
        },
        "domainName": {
          "type": ["string", "null"]
        },
        "forwardMutualTlsIdentity": {
          "$ref": "#/$defs/TigerConfigurationPkiIdentity-nullable"
        },
        "masterSecretsFile": {
          "type": ["string", "null"]
        },
        "ocspSignerIdentity": {
          "$ref": "#/$defs/TigerConfigurationPkiIdentity-nullable"
        },
        "serverIdentities": {
          "type": ["array", "null"],
          "items": {
            "$ref": "#/$defs/TigerConfigurationPkiIdentity"
          }
        },
        "serverIdentity": {
          "$ref": "#/$defs/TigerConfigurationPkiIdentity-nullable"
        },
        "serverRootCa": {
          "$ref": "#/$defs/TigerConfigurationPkiIdentity-nullable"
        },
        "serverSslSuites": {
          "type": ["array", "null"],
          "items": {
            "type": "string"
          }
        },
        "serverTlsProtocols": {
          "type": ["array", "null"],
          "items": {
            "type": "string"
          }
        }
      }
    },
    "TrafficEndpointConfiguration-nullable": {
      "type": ["object", "null"],
      "properties": {
        "name": {
          "type": ["string", "null"]
        },
        "stompTopic": {
          "type": ["string", "null"]
        },
        "wsEndpoint": {
          "type": ["string", "null"]
        }
      }
    },
    "X509Certificate": {
      "type": "object",
      "properties": {
        "type": {
          "type": ["string", "null"]
        }
      }
    },
    "X509Certificate-nullable": {
      "anyOf": [
        {
          "type": "null"
        },
        {
          "$ref": "#/$defs/X509Certificate"
        }
      ]
    }
  },
  "title": "Tiger environment configuration",
  "description": "A configuration file for the test environment of the gematik Tiger test platform",

  "type": "object",
  "properties": {
    "localProxyActive": {
      "type": "boolean"
    },
    "servers": {
      "$ref": "#/$defs/Map(String,CfgServer)-nullable",
      "type": "object",
      "additionalProperties": {
        "$ref": "#/$defs/CfgServer"
      }
    },
    "tigerProxy": {
      "$ref": "#/$defs/TigerProxyConfiguration-nullable"
    }
  }
}
