{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://objectsgrid.com/.well-known/objects-catalog/ProductModel/v1/schema.json",
  "title": "ProductModel",
  "description": "Objects Grid ProductModel Object. Modeled in compliance with https://schema.org/ProductModel.",
  "type": "object",
  "properties": {
    "id": {
      "description": "The unique identifier for ProductModel",
      "type": [
        "string",
        "null"
      ],
      "minLength": 0,
      "maxLength": 50
    },
    "at_context": {
      "description": "Schema context",
      "anyOf": [
        {
          "type": "string",
          "enum": [
            "https://schema.org"
          ]
        },
        {
          "type": "null"
        }
      ]
    },
    "at_type": {
      "description": "The object type",
      "anyOf": [
        {
          "type": "string",
          "enum": [
            "ProductModel"
          ]
        },
        {
          "type": "null"
        }
      ]
    },
    "at_id": {
      "description": "This ProductModel's ObjectsGrid URL, https://apis.objectsgrid.com/<path>/<id>: its JSON-LD @id, which References point to. Set by the service.",
      "type": [
        "string",
        "null"
      ],
      "format": "uri",
      "readOnly": true
    },
    "identifier": {
      "description": "The unique identifier for ProductModel",
      "type": [
        "string",
        "null"
      ],
      "minLength": 0,
      "maxLength": 50
    },
    "image": {
      "description": "image URL",
      "type": [
        "string",
        "null"
      ],
      "minLength": 0,
      "format": "uri"
    },
    "name": {
      "description": "The Product Name",
      "type": "array",
      "items": {
        "$ref": "https://objectsgrid.com/.well-known/objects-catalog/LanguageTaggedString/v1/schema.json"
      },
      "minItems": 1
    },
    "description": {
      "description": "The Product Description",
      "type": "array",
      "items": {
        "$ref": "https://objectsgrid.com/.well-known/objects-catalog/LanguageTaggedString/v1/schema.json"
      }
    },
    "url": {
      "description": "This Product URL",
      "type": [
        "string",
        "null"
      ],
      "format": "uri",
      "minLength": 1
    },
    "additionalType": {
      "description": "The kind of product: ProductCollection for a bundle or kit, whose contents are in includesObject: its JSON-LD @type. None for a ProductModel.",
      "anyOf": [
        {
          "type": "string",
          "enum": [
            "ProductCollection"
          ]
        },
        {
          "type": "null"
        }
      ]
    },
    "includesObject": {
      "description": "ProductCollection: the bundle's contents, each a good and how many of it",
      "type": [
        "array",
        "null"
      ],
      "items": {
        "$ref": "https://objectsgrid.com/.well-known/objects-catalog/TypeAndQuantityNode/v1/schema.json"
      },
      "maxItems": 100
    },
    "predecessorOf": {
      "description": "A pointer from a previous, often discontinued variant of the product to its newer variant. Computed, read-only: the objects whose ProductModel.successorOf points to this object, listed from that type; never stored or written.",
      "x-objectsgrid-inverseOf": "ProductModel.successorOf",
      "readOnly": true
    },
    "successorOf": {
      "description": "A pointer from a newer variant of a product to its previous, often discontinued predecessor.",
      "x-objectsgrid-rangeIncludes": [
        "ProductModel"
      ],
      "anyOf": [
        {
          "$ref": "https://objectsgrid.com/.well-known/objects-catalog/Reference/v1/schema.json"
        },
        {
          "type": "null"
        }
      ]
    },
    "aggregateRating": {
      "description": "The aggregate rating of the Product",
      "anyOf": [
        {
          "$ref": "https://objectsgrid.com/.well-known/objects-catalog/AggregateRating/v1/schema.json"
        },
        {
          "type": "null"
        }
      ]
    },
    "asin": {
      "description": "The Amazon Standard Identification Number (ASIN) of the product",
      "type": [
        "string",
        "null"
      ]
    },
    "audience": {
      "description": "The audience for the product",
      "anyOf": [
        {
          "$ref": "https://objectsgrid.com/.well-known/objects-catalog/Audience/v1/schema.json"
        },
        {
          "type": "null"
        }
      ]
    },
    "award": {
      "description": "Awards won by or for this item",
      "type": [
        "string",
        "null"
      ]
    },
    "brand": {
      "description": "The brand of the product",
      "x-objectsgrid-rangeIncludes": [
        "Brand",
        "Organization"
      ],
      "anyOf": [
        {
          "$ref": "https://objectsgrid.com/.well-known/objects-catalog/Reference/v1/schema.json"
        },
        {
          "type": "null"
        }
      ]
    },
    "category": {
      "description": "The category of the product",
      "type": [
        "array",
        "null"
      ],
      "items": {
        "type": "string"
      }
    },
    "color": {
      "description": "The color of the product",
      "type": [
        "string",
        "null"
      ]
    },
    "colorSwatch": {
      "description": "Color swatch images for the product",
      "type": [
        "string",
        "null"
      ]
    },
    "countryOfAssembly": {
      "description": "The country where the product is assembled",
      "anyOf": [
        {
          "$ref": "https://objectsgrid.com/.well-known/objects-catalog/CountryCodeEnumeration/v1/schema.json"
        },
        {
          "type": "null"
        }
      ]
    },
    "countryOfLastProcessing": {
      "description": "The country where the product was last processed",
      "anyOf": [
        {
          "$ref": "https://objectsgrid.com/.well-known/objects-catalog/CountryCodeEnumeration/v1/schema.json"
        },
        {
          "type": "null"
        }
      ]
    },
    "countryOfOrigin": {
      "description": "The country where the product was manufactured",
      "anyOf": [
        {
          "$ref": "https://objectsgrid.com/.well-known/objects-catalog/CountryCodeEnumeration/v1/schema.json"
        },
        {
          "type": "null"
        }
      ]
    },
    "depth": {
      "description": "The depth of the product",
      "anyOf": [
        {
          "$ref": "https://objectsgrid.com/.well-known/objects-catalog/QuantitativeValue/v1/schema.json"
        },
        {
          "type": "null"
        }
      ]
    },
    "funding": {
      "description": "A pointer to a funding source for the item",
      "x-objectsgrid-rangeIncludes": [],
      "anyOf": [
        {
          "$ref": "https://objectsgrid.com/.well-known/objects-catalog/Reference/v1/schema.json"
        },
        {
          "type": "null"
        }
      ]
    },
    "gtin": {
      "description": "The Global Trade Item Number (GTIN) of the product",
      "type": [
        "string",
        "null"
      ]
    },
    "gtin12": {
      "description": "The GTIN-12 of the product",
      "type": [
        "string",
        "null"
      ]
    },
    "gtin13": {
      "description": "The GTIN-13 of the product",
      "type": [
        "string",
        "null"
      ]
    },
    "gtin14": {
      "description": "The GTIN-14 of the product",
      "type": [
        "string",
        "null"
      ]
    },
    "gtin8": {
      "description": "The GTIN-8 of the product",
      "type": [
        "string",
        "null"
      ]
    },
    "hasAdultConsideration": {
      "description": "Indicates whether this item is targeted at a mature audience",
      "type": [
        "array",
        "null"
      ],
      "items": {
        "$ref": "https://objectsgrid.com/.well-known/objects-catalog/AdultOrientedEnumeration/v1/schema.json"
      }
    },
    "hasCertification": {
      "description": "The certifications and/or standards for the product",
      "type": [
        "array",
        "null"
      ],
      "items": {
        "type": "string"
      }
    },
    "hasEnergyConsumptionDetails": {
      "description": "The energy consumption details for the product",
      "anyOf": [
        {
          "$ref": "https://objectsgrid.com/.well-known/objects-catalog/EnergyConsumptionDetails/v1/schema.json"
        },
        {
          "type": "null"
        }
      ]
    },
    "hasGS1DigitalLink": {
      "description": "A link to the GS1 Digital Link representation of the product identifier",
      "type": [
        "string",
        "null"
      ],
      "format": "uri"
    },
    "hasMeasurement": {
      "description": "A pointer to a product measurement",
      "anyOf": [
        {
          "$ref": "https://objectsgrid.com/.well-known/objects-catalog/QuantitativeValue/v1/schema.json"
        },
        {
          "type": "null"
        }
      ]
    },
    "hasMerchantReturnPolicy": {
      "description": "The return policy for it, when it differs from its Product's or seller's",
      "x-objectsgrid-rangeIncludes": [
        "MerchantReturnPolicy"
      ],
      "anyOf": [
        {
          "$ref": "https://objectsgrid.com/.well-known/objects-catalog/Reference/v1/schema.json"
        },
        {
          "type": "null"
        }
      ]
    },
    "height": {
      "description": "The height of the product",
      "anyOf": [
        {
          "$ref": "https://objectsgrid.com/.well-known/objects-catalog/QuantitativeValue/v1/schema.json"
        },
        {
          "type": "null"
        }
      ]
    },
    "inProductGroupWithID": {
      "description": "The Product Group ID for the product",
      "type": [
        "string",
        "null"
      ]
    },
    "isAccessoryOrSparePartFor": {
      "description": "A pointer to another product (or multiple products) for which this product is an accessory or spare part",
      "x-objectsgrid-rangeIncludes": [
        "Product",
        "ProductGroup",
        "ProductModel"
      ],
      "type": [
        "array",
        "null"
      ],
      "items": {
        "$ref": "https://objectsgrid.com/.well-known/objects-catalog/Reference/v1/schema.json"
      }
    },
    "isConsumableFor": {
      "description": "A pointer to another product (or multiple products) for which this product is a consumable",
      "x-objectsgrid-rangeIncludes": [
        "Product",
        "ProductGroup",
        "ProductModel"
      ],
      "type": [
        "array",
        "null"
      ],
      "items": {
        "$ref": "https://objectsgrid.com/.well-known/objects-catalog/Reference/v1/schema.json"
      }
    },
    "isFamilyFriendly": {
      "description": "Indicates whether this item is family friendly",
      "type": [
        "boolean",
        "null"
      ]
    },
    "isRelatedTo": {
      "description": "A pointer to another, somehow related product (or multiple products)",
      "x-objectsgrid-rangeIncludes": [
        "Product",
        "ProductGroup",
        "ProductModel",
        "Service"
      ],
      "type": [
        "array",
        "null"
      ],
      "items": {
        "$ref": "https://objectsgrid.com/.well-known/objects-catalog/Reference/v1/schema.json"
      }
    },
    "isSimilarTo": {
      "description": "A pointer to another, functionally similar product (or multiple products)",
      "x-objectsgrid-rangeIncludes": [
        "Product",
        "ProductGroup",
        "ProductModel",
        "Service"
      ],
      "type": [
        "array",
        "null"
      ],
      "items": {
        "$ref": "https://objectsgrid.com/.well-known/objects-catalog/Reference/v1/schema.json"
      }
    },
    "isVariantOf": {
      "description": "A pointer to a base product (or multiple products) for which this product is a variant (e.g. in color, size, material, etc.)",
      "x-objectsgrid-rangeIncludes": [
        "ProductGroup",
        "ProductModel"
      ],
      "anyOf": [
        {
          "$ref": "https://objectsgrid.com/.well-known/objects-catalog/Reference/v1/schema.json"
        },
        {
          "type": "null"
        }
      ]
    },
    "itemCondition": {
      "description": "The condition of the product",
      "anyOf": [
        {
          "$ref": "https://objectsgrid.com/.well-known/objects-catalog/OfferItemCondition/v1/schema.json"
        },
        {
          "type": "null"
        }
      ]
    },
    "keywords": {
      "description": "Keywords used to describe the product",
      "type": "array",
      "items": {
        "$ref": "https://objectsgrid.com/.well-known/objects-catalog/LanguageTaggedString/v1/schema.json"
      }
    },
    "logo": {
      "description": "An associated logo for the product",
      "type": [
        "string",
        "null"
      ],
      "format": "uri"
    },
    "manufacturer": {
      "description": "The manufacturer of the product",
      "x-objectsgrid-rangeIncludes": [
        "Organization"
      ],
      "anyOf": [
        {
          "$ref": "https://objectsgrid.com/.well-known/objects-catalog/Reference/v1/schema.json"
        },
        {
          "type": "null"
        }
      ]
    },
    "material": {
      "description": "The material of the product",
      "type": [
        "array",
        "null"
      ],
      "items": {
        "type": "string"
      }
    },
    "mobileUrl": {
      "description": "This Product Mobile URL",
      "type": [
        "string",
        "null"
      ],
      "format": "uri"
    },
    "model": {
      "description": "The model of the product",
      "type": [
        "string",
        "null"
      ]
    },
    "mpn": {
      "description": "The Manufacturer Part Number (MPN) of the product",
      "type": [
        "string",
        "null"
      ]
    },
    "negativeNotes": {
      "description": "Provides negative considerations regarding the product",
      "type": "array",
      "items": {
        "$ref": "https://objectsgrid.com/.well-known/objects-catalog/LanguageTaggedString/v1/schema.json"
      }
    },
    "nsn": {
      "description": "The NATO Stock Number (NSN) of the product",
      "type": [
        "string",
        "null"
      ]
    },
    "offers": {
      "description": "Links to Offers to provide this item. For example, offers to sell a product, rent the DVD of a movie, or give away tickets to an event. Computed, read-only: the objects whose Offer.itemOffered points to this object, listed from that type; never stored or written.",
      "x-objectsgrid-inverseOf": "Offer.itemOffered",
      "readOnly": true
    },
    "pattern": {
      "description": "A pattern that can be used to describe the product",
      "type": "array",
      "items": {
        "$ref": "https://objectsgrid.com/.well-known/objects-catalog/LanguageTaggedString/v1/schema.json"
      }
    },
    "positiveNotes": {
      "description": "Provides positive considerations regarding the product",
      "type": "array",
      "items": {
        "$ref": "https://objectsgrid.com/.well-known/objects-catalog/LanguageTaggedString/v1/schema.json"
      }
    },
    "productID": {
      "description": "The product identifier, such as ISBN. For example: 'isbn:123-456-789'.",
      "type": [
        "string",
        "null"
      ]
    },
    "productionDate": {
      "description": "The production date of the product",
      "type": [
        "string",
        "null"
      ],
      "format": "date-time"
    },
    "purchaseDate": {
      "description": "The purchase date of the product",
      "type": [
        "string",
        "null"
      ],
      "format": "date-time"
    },
    "releaseDate": {
      "description": "The release date of the product",
      "type": [
        "string",
        "null"
      ],
      "format": "date-time"
    },
    "review": {
      "description": "Review of the item. Computed, read-only: the objects whose Review.itemReviewed points to this object, listed from that type; never stored or written.",
      "x-objectsgrid-inverseOf": "Review.itemReviewed",
      "readOnly": true
    },
    "size": {
      "description": "The size of the product, e.g. a clothing size in a size system",
      "anyOf": [
        {
          "$ref": "https://objectsgrid.com/.well-known/objects-catalog/SizeSpecification/v1/schema.json"
        },
        {
          "type": "null"
        }
      ]
    },
    "sku": {
      "description": "The Stock Keeping Unit (SKU) of the product",
      "type": [
        "string",
        "null"
      ]
    },
    "slogan": {
      "description": "The slogan of the product",
      "type": "array",
      "items": {
        "$ref": "https://objectsgrid.com/.well-known/objects-catalog/LanguageTaggedString/v1/schema.json"
      }
    },
    "weight": {
      "description": "The weight of the product",
      "anyOf": [
        {
          "$ref": "https://objectsgrid.com/.well-known/objects-catalog/QuantitativeValue/v1/schema.json"
        },
        {
          "type": "null"
        }
      ]
    },
    "width": {
      "description": "The width of the product",
      "anyOf": [
        {
          "$ref": "https://objectsgrid.com/.well-known/objects-catalog/QuantitativeValue/v1/schema.json"
        },
        {
          "type": "null"
        }
      ]
    },
    "tags": {
      "description": "Tags an ABAC policy can decide on. A name may repeat; the same name and value appear once. Every stored object has them: created empty when not sent, kept by a replacement (PUT) that does not mention them, unchanged by a patch that does not mention them, cleared by null or [].",
      "type": "array",
      "default": [],
      "uniqueItems": true,
      "maxItems": 50,
      "items": {
        "$ref": "https://objectsgrid.com/.well-known/objects-catalog/Tag/v1/schema.json"
      }
    }
  },
  "required": [
    "name",
    "sku"
  ],
  "allOf": [
    {
      "if": {
        "required": [
          "additionalType"
        ],
        "properties": {
          "additionalType": {
            "const": "ProductCollection"
          }
        }
      },
      "else": {
        "not": {
          "anyOf": [
            {
              "required": [
                "includesObject"
              ]
            }
          ]
        }
      }
    }
  ]
}
