{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "title": "Customer report",
  "type": "object",
  "required": [
    "CustomerName",
    "Total",
    "Approved",
    "Lines"
  ],
  "properties": {
    "CustomerName": {
      "type": "string"
    },
    "ReportDate": {
      "type": "string"
    },
    "Total": {
      "type": "number"
    },
    "Approved": {
      "type": "boolean"
    },
    "Lines": {
      "type": "array",
      "x-ise-collection-members": [
        "Length"
      ],
      "items": {
        "type": "object",
        "required": [
          "Product",
          "Quantity",
          "Price"
        ],
        "properties": {
          "Product": {
            "type": "string"
          },
          "Quantity": {
            "type": "integer"
          },
          "Price": {
            "type": "number"
          },
          "Tags": {
            "type": "array",
            "items": {
              "type": "string"
            }
          },
          "Metrics": {
            "type": "array",
            "items": {
              "type": "object",
              "required": [
                "Name",
                "Value"
              ],
              "properties": {
                "Name": {
                  "type": "string"
                },
                "Value": {
                  "type": "number"
                }
              }
            }
          }
        }
      }
    }
  }
}