{
    "$schema": "http://json-schema.org/draft-07/schema#",
    "type": "object",
    "properties": {
        "gift_card_code": {
            "type": "string",
            "input_type": "text",
            "hidden": false,
            "title": "Gift card code",
            "tab": "",
            "misc": {
                "tooltip": "Unique code for this gift card. A random unused code is generated by default.",
                "sub_type": "gift_card_code"
            },
            "required": true,
            "dependency": [],
            "default_value": "",
            "editable": true
        },
        "gift_card_buyer_name": {
            "type": "string",
            "input_type": "text",
            "hidden": false,
            "title": "Buyer name",
            "tab": "",
            "misc": {
                "tooltip": "Enter the name of the person ordering the gift card."
            },
            "required": true,
            "dependency": [],
            "default_value": "",
            "editable": true
        },
        "gift_card_buyer_email": {
            "type": "string",
            "input_type": "text",
            "hidden": false,
            "title": "Buyer email",
            "tab": "",
            "misc": {
                "tooltip": "Enter the email of the person ordering the gift card.",
                "sub_type": "email"
            },
            "required": true,
            "dependency": [],
            "default_value": "",
            "editable": true
        },
        "gift_card_recipient_name": {
            "type": "string",
            "input_type": "text",
            "hidden": false,
            "title": "Recipient name",
            "tab": "",
            "misc": {
                "tooltip": "Enter the name of the gift card recipient."
            },
            "required": true,
            "dependency": [],
            "default_value": "",
            "editable": true
        },
        "gift_card_recipient_email": {
            "type": "string",
            "input_type": "text",
            "hidden": false,
            "title": "Recipient email",
            "tab": "",
            "misc": {
                "tooltip": "Enter the email of the gift card recipient.",
                "sub_type": "email"
            },
            "required": true,
            "dependency": [],
            "default_value": "",
            "editable": true
        },
        "gift_card_message": {
            "type": "string",
            "input_type": "textarea",
            "hidden": true,
            "title": "Message",
            "tab": "",
            "misc": {
                "tooltip": "Optional personal message included in the recipient email."
            },
            "required": false,
            "dependency": [],
            "default_value": "",
            "editable": true
        },
        "gift_card_amount": {
            "type": "string",
            "input_type": "price",
            "hidden": false,
            "title": "Amount",
            "tab": "",
            "misc": {
                "tooltip": "Enter the gift card amount.",
                "sub_type": "positive_float"
            },
            "required": true,
            "dependency": [],
            "default_value": "",
            "editable": true
        },
        "gift_card_design": {
            "type": "string",
            "input_type": "gift_card_design",
            "hidden": false,
            "title": "Design",
            "tab": "",
            "misc": {
                "tooltip": "Visual card design emailed to the recipient as a PDF.",
                "options": {
                    "botanical_green": "Botanical Green",
                    "spa_wellness": "Spa Wellness",
                    "gold_ribbon": "Gold Ribbon",
                    "black_gold": "Black Gold"
                }
            },
            "required": false,
            "dependency": [],
            "default_value": "botanical_green",
            "editable": true
        },
        "gift_card_expiration_date": {
            "type": "string",
            "input_type": "date",
            "hidden": false,
            "title": "Expiration date",
            "tab": "",
            "misc": {
                "tooltip": "Select the date when the gift card expires.",
                "date_format": "F j, Y",
                "time_zone": "Europe/London"
            },
            "required": false,
            "dependency": [],
            "default_value": "",
            "editable": true
        },
        "gift_card_send_on": {
            "type": "string",
            "input_type": "date",
            "hidden": false,
            "title": "Send card on",
            "tab": "",
            "misc": {
                "tooltip": "Select the date when the gift card should be sent. Must be earlier than the expiration date.",
                "date_format": "F j, Y",
                "time_zone": "Europe/London"
            },
            "required": true,
            "dependency": [],
            "default_value": "",
            "editable": true
        },
        "gift_card_applicable_for_all_services": {
            "type": "string",
            "input_type": "checkbox",
            "hidden": true,
            "title": "Applicable for all services",
            "tab": "",
            "misc": {
                "yes": "Yes",
                "tooltip": "Apply this gift card to all services. Uncheck to choose specific services."
            },
            "required": false,
            "dependency": [],
            "default_value": "yes",
            "editable": true
        },
        "gift_card_services": {
            "type": "string",
            "input_type": "select",
            "hidden": true,
            "title": "Services",
            "tab": "",
            "misc": {
                "tooltip": "Choose the service(-s) for which the gift card will be applicable.",
                "multiple": true,
                "options": "services"
            },
            "required": false,
            "dependency": [
                [
                    "applicable_for_all_services",
                    "!=",
                    "yes"
                ]
            ],
            "default_value": null,
            "editable": true
        }
    }
}