{
    "additionalProperties": false,
    "definitions": {
        "backendType": {
            "additionalProperties": false,
            "properties": {
                "serviceName": {
                    "minLength": 1,
                    "type": "string"
                },
                "servicePort": {
                    "$ref": "#/definitions/portType"
                }
            },
            "required": [
                "serviceName",
                "servicePort"
            ],
            "type": "object"
        },
        "frontendIAppType": {
            "additionalProperties": false,
            "properties": {
                "iapp": {
                    "minLength": 1,
                    "type": "string"
                },
                "iappOptions": {
                    "additionalProperties": false,
                    "patternProperties": {
                        "^[a-zA-Z0-9_-]+$": {
                            "minLength": 1,
                            "type": "string"
                        }
                    },
                    "type": "object"
                },
                "iappTableName": {
                    "minLength": 1,
                    "type": "string"
                },
                "iappVariables": {
                    "additionalProperties": false,
                    "patternProperties": {
                        "^[a-zA-Z0-9_-]+$": {
                            "minLength": 1,
                            "type": "string"
                        }
                    },
                    "type": "object"
                },
                "partition": {
                    "minLength": 1,
                    "type": "string"
                }
            },
            "required": [
                "partition",
                "iapp",
                "iappOptions",
                "iappTableName",
                "iappVariables"
            ],
            "type": "object"
        },
        "frontendVSType": {
            "additionalProperties": false,
            "properties": {
                "balance": {
                    "enum": [
                        "dynamic-ratio-member",
                        "dynamic-ratio-node",
                        "fastest-app-response",
                        "fastest-node",
                        "least-connections-member",
                        "least-connections-node",
                        "least-sessions",
                        "observed-member",
                        "observed-node",
                        "predictive-member",
                        "predictive-node",
                        "ratio-least-connections-member",
                        "ratio-least-connections-node",
                        "ratio-member",
                        "ratio-node",
                        "round-robin",
                        "ratio-session",
                        "weighted-least-connections-member",
                        "weighted-least-connections-node"
                    ],
                    "type": "string"
                },
                "mode": {
                    "enum": [
                        "http",
                        "tcp"
                    ],
                    "type": "string"
                },
                "partition": {
                    "minLength": 1,
                    "type": "string"
                },
                "sslProfile": {
                    "$ref": "#/definitions/sslProfileType"
                },
                "virtualAddress": {
                    "$ref": "#/definitions/virtualAddressType"
                }
            },
            "required": [
                "partition",
                "virtualAddress"
            ],
            "type": "object"
        },
        "portType": {
            "maximum": 65535,
            "minimum": 1,
            "type": "integer"
        },
        "sslProfileType": {
            "additionalProperties": false,
            "properties": {
                "f5ProfileName": {
                    "minLength": 1,
                    "type": "string"
                }
            },
            "required": [
                "f5ProfileName"
            ],
            "type": "object"
        },
        "virtualAddressType": {
            "additionalProperties": false,
            "properties": {
                "bindAddr": {
                    "anyOf": [
                        {
                            "format": "ipv4"
                        },
                        {
                            "format": "ipv6"
                        }
                    ]
                },
                "port": {
                    "$ref": "#/definitions/portType"
                }
            },
            "required": [
                "bindAddr",
                "port"
            ],
            "type": "object"
        }
    },
    "properties": {
        "virtualServer": {
            "additionalProperties": false,
            "properties": {
                "backend": {
                    "$ref": "#/definitions/backendType"
                },
                "frontend": {
                    "oneOf": [
                        {
                            "$ref": "#/definitions/frontendIAppType"
                        },
                        {
                            "$ref": "#/definitions/frontendVSType"
                        }
                    ]
                }
            },
            "required": [
                "backend",
                "frontend"
            ],
            "type": "object"
        }
    },
    "required": [
        "virtualServer"
    ],
    "type": "object"
}