{
    "$schema": "http://json-schema.org/draft-07/schema#",
    "type": "object",
    "properties": {
        "coupon_name": {
            "type": "string",
            "input_type": "text",
            "hidden": false,
            "title": "Coupon",
            "tab": "",
            "misc": {
                "tooltip": "Enter a coupon code."
            },
            "required": true,
            "dependency": [],
            "default_value": "",
            "editable": true
        },
        "coupon_date_range": {
            "type": "string",
            "input_type": "date_range",
            "hidden": false,
            "title": "Available on",
            "tab": "",
            "misc": {
                "tooltip": "Define the time period during which the coupon will be valid.",
                "time_zone": "Europe/Warsaw"
            },
            "required": false,
            "dependency": [],
            "default_value": "",
            "editable": true
        },
        "coupon_services": {
            "type": "string",
            "input_type": "select",
            "hidden": true,
            "title": "Services",
            "tab": "",
            "misc": {
                "tooltip": "Choose the service(-s) for which the coupon will be applicable.",
                "multiple": true,
                "options": "services"
            },
            "required": false,
            "dependency": [],
            "default_value": null,
            "editable": true
        },
        "coupon_maximum": {
            "type": "string",
            "input_type": "text",
            "hidden": false,
            "title": "Usage limit",
            "tab": "",
            "misc": {
                "tooltip": "Specify the Usage limit for the coupon - the maximum number of times it can be applied. Leaving it blank means unlimited use.",
                "sub_type": "none_negative_integer"
            },
            "required": false,
            "dependency": [],
            "default_value": "",
            "editable": true
        },
        "coupon_used": {
            "type": "string",
            "input_type": "text",
            "hidden": false,
            "title": "Used",
            "tab": "",
            "misc": {
                "sub_type": "positive_integer"
            },
            "required": false,
            "dependency": [],
            "default_value": "",
            "editable": false
        },
        "coupon_amount_fixed": {
            "type": "string",
            "input_type": "text",
            "hidden": false,
            "title": "Discount (fixed)",
            "tab": "",
            "misc": {
                "tooltip": "Speficy the fixed amount that will be applied as the discount.",
                "sub_type": "none_negative_float"
            },
            "required": true,
            "dependency": [],
            "default_value": "0",
            "editable": true
        },
        "coupon_amount_percentage": {
            "type": "string",
            "input_type": "text",
            "hidden": false,
            "title": "Discount (percentage)",
            "tab": "",
            "misc": {
                "tooltip": "Speficy the percentage that will be applied as the discount.",
                "sub_type": "none_negative_float"
            },
            "required": true,
            "dependency": [],
            "default_value": "100",
            "editable": true
        }
    }
}