{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://objectsgrid.com/.well-known/objects-catalog/SizeSpecification/v1/schema.json",
  "title": "SizeSpecification",
  "description": "Objects Grid SizeSpecification. A product's size: its name in a size system, and optionally the group, ages and measurements it is for. Modeled in compliance with https://schema.org/SizeSpecification.",
  "type": "object",
  "properties": {
    "at_type": {
      "description": "The object type",
      "type": [
        "string",
        "null"
      ],
      "enum": [
        "SizeSpecification"
      ]
    },
    "name": {
      "description": "The size as written on the label, e.g. 'M', '42', '10 1/2'",
      "type": "string",
      "minLength": 1,
      "maxLength": 50
    },
    "sizeGroup": {
      "description": "The groups the size is for, e.g. WearableSizeGroupPetite",
      "type": [
        "array",
        "null"
      ],
      "items": {
        "$ref": "https://objectsgrid.com/.well-known/objects-catalog/SizeGroupEnumeration/v1/schema.json"
      }
    },
    "sizeSystem": {
      "description": "The size system, e.g. WearableSizeSystemEurope",
      "anyOf": [
        {
          "$ref": "https://objectsgrid.com/.well-known/objects-catalog/SizeSystemEnumeration/v1/schema.json"
        },
        {
          "type": "null"
        }
      ]
    },
    "suggestedAge": {
      "description": "The ages the size is for, e.g. minValue 3 maxValue 4, unitCode ANN",
      "anyOf": [
        {
          "$ref": "https://objectsgrid.com/.well-known/objects-catalog/QuantitativeValue/v1/schema.json"
        },
        {
          "type": "null"
        }
      ]
    },
    "suggestedGender": {
      "description": "The gender the size is for: 'female', 'male' or 'unisex'",
      "type": [
        "string",
        "null"
      ]
    },
    "hasMeasurement": {
      "description": "Measurements of the size, e.g. a chest of 96 cm",
      "type": [
        "array",
        "null"
      ],
      "items": {
        "$ref": "https://objectsgrid.com/.well-known/objects-catalog/QuantitativeValue/v1/schema.json"
      }
    }
  },
  "required": [
    "name"
  ],
  "unevaluatedProperties": false
}
