{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://catalog.lintel.tools/schemas/schemastore/windows-package-manager-locale-manifest/latest.json",
  "description": "A representation of a multiple-file manifest representing app metadata in other locale in the OWC. v1.0.0",
  "x-lintel": {
    "source": "https://www.schemastore.org/winget-pkgs-locale-1.0.0.json",
    "sourceSha256": "27821fc574e44a7cfd0c28d98a6d5a032e1435e718e363dca9bb861064bf5f89",
    "fileMatch": [
      "**/manifests/?/*/*/*/*.*.locale.en-US.yaml",
      "**/manifests/?/*/*/*/*.*.locale.fr-FR.yaml",
      "**/manifests/?/*/*/*/*.*.locale.it-IT.yaml",
      "**/manifests/?/*/*/*/*.*.locale.ja-JP.yaml",
      "**/manifests/?/*/*/*/*.*.locale.ko-KR.yaml",
      "**/manifests/?/*/*/*/*.*.locale.pt-BR.yaml",
      "**/manifests/?/*/*/*/*.*.locale.ru-RU.yaml",
      "**/manifests/?/*/*/*/*.*.locale.zh-CN.yaml",
      "**/manifests/?/*/*/*/*.*.locale.zh-TW.yaml"
    ],
    "parsers": [
      "yaml"
    ]
  },
  "type": "object",
  "properties": {
    "PackageIdentifier": {
      "type": "string",
      "pattern": "^[^\\.\\s\\\\/:\\*\\?\"<>\\|\\x01-\\x1f]{1,32}(\\.[^\\.\\s\\\\/:\\*\\?\"<>\\|\\x01-\\x1f]{1,32}){1,3}$",
      "maxLength": 128,
      "description": "The package unique identifier"
    },
    "PackageVersion": {
      "type": "string",
      "pattern": "^[^\\\\/:\\*\\?\"<>\\|\\x01-\\x1f]+$",
      "maxLength": 128,
      "description": "The package version"
    },
    "PackageLocale": {
      "type": "string",
      "pattern": "^([a-zA-Z]{2}|[iI]-[a-zA-Z]+|[xX]-[a-zA-Z]{1,8})(-[a-zA-Z]{1,8})*$",
      "maxLength": 20,
      "description": "The package meta-data locale"
    },
    "Publisher": {
      "type": [
        "string",
        "null"
      ],
      "minLength": 2,
      "maxLength": 256,
      "description": "The publisher name"
    },
    "PublisherUrl": {
      "$ref": "#/$defs/Url",
      "description": "The publisher home page"
    },
    "PublisherSupportUrl": {
      "$ref": "#/$defs/Url",
      "description": "The publisher support page"
    },
    "PrivacyUrl": {
      "$ref": "#/$defs/Url",
      "description": "The publisher privacy page or the package privacy page"
    },
    "Author": {
      "type": [
        "string",
        "null"
      ],
      "minLength": 2,
      "maxLength": 256,
      "description": "The package author"
    },
    "PackageName": {
      "type": [
        "string",
        "null"
      ],
      "minLength": 2,
      "maxLength": 256,
      "description": "The package name"
    },
    "PackageUrl": {
      "$ref": "#/$defs/Url",
      "description": "The package home page"
    },
    "License": {
      "type": [
        "string",
        "null"
      ],
      "minLength": 3,
      "maxLength": 512,
      "description": "The package license"
    },
    "LicenseUrl": {
      "$ref": "#/$defs/Url",
      "description": "The license page"
    },
    "Copyright": {
      "type": [
        "string",
        "null"
      ],
      "minLength": 3,
      "maxLength": 512,
      "description": "The package copyright"
    },
    "CopyrightUrl": {
      "$ref": "#/$defs/Url",
      "description": "The package copyright page"
    },
    "ShortDescription": {
      "type": [
        "string",
        "null"
      ],
      "minLength": 3,
      "maxLength": 256,
      "description": "The short package description"
    },
    "Description": {
      "type": [
        "string",
        "null"
      ],
      "minLength": 3,
      "maxLength": 10000,
      "description": "The full package description"
    },
    "Moniker": {
      "$ref": "#/$defs/Tag",
      "description": "The most common package term"
    },
    "Tags": {
      "type": [
        "array",
        "null"
      ],
      "items": {
        "$ref": "#/$defs/Tag"
      },
      "maxItems": 16,
      "uniqueItems": true,
      "description": "List of additional package search terms"
    },
    "ManifestType": {
      "type": "string",
      "default": "locale",
      "const": "locale",
      "description": "The manifest type"
    },
    "ManifestVersion": {
      "type": "string",
      "default": "1.0.0",
      "pattern": "^(0|[1-9][0-9]{0,3}|[1-5][0-9]{4}|6[0-4][0-9]{3}|65[0-4][0-9]{2}|655[0-2][0-9]|6553[0-5])(\\.(0|[1-9][0-9]{0,3}|[1-5][0-9]{4}|6[0-4][0-9]{3}|65[0-4][0-9]{2}|655[0-2][0-9]|6553[0-5])){2}$",
      "description": "The manifest syntax version"
    }
  },
  "required": [
    "PackageIdentifier",
    "PackageVersion",
    "PackageLocale",
    "ManifestType",
    "ManifestVersion"
  ],
  "$defs": {
    "Url": {
      "type": [
        "string",
        "null"
      ],
      "pattern": "^([Hh][Tt][Tt][Pp][Ss]?)://.+$",
      "maxLength": 2000,
      "description": "Optional Url type"
    },
    "Tag": {
      "type": [
        "string",
        "null"
      ],
      "minLength": 1,
      "maxLength": 40,
      "description": "Package moniker or tag"
    }
  }
}
