{
	"$id": "https://www.atsc-schemas.org/atsc3.0/a344/20250226/org.atsc.notify-langPref.json",
	"$schema": "https://json-schema.org/draft/2019-09/schema#",
	"title": "Notify Message",
	"description": "langPref",
	"type": "object",
	"properties": {
		"jsonrpc": {
			"type": "string",
			"enum": [ "2.0" ]
		},
		"method": {
			"type": "string",
			"enum": [ "org.atsc.notify" ]
		},
		"params": {
			"type": "object",
			"properties": {
				"msgType": {
					"type": "string",
					"enum": [ "langPref" ]
				},
				"preferredAudioLang": {
					"oneOf": [
						{
							"$comment": "languages should be constrained to ^[a-z]{2}[a-z]?(-(([A-Z][A-Z])?|([a-z]{2}[a-z]?)))?$  ",
							"type": "string",
							"format": "bcp47-codes"
						},
						{ "type": "null" }
					]
				},
				"preferredUILang": {
					"oneOf": [
						{
							"$comment": "languages should be constrained to ^[a-z]{2}[a-z]?(-(([A-Z][A-Z])?|([a-z]{2}[a-z]?)))?$  ",
							"type": "string",
							"format": "bcp47-codes"
						},
						{ "type": "null" }
					]
				},
				"preferredCaptionSubtitleLang": {
					"oneOf": [
						{
							"$comment": "languages should be constrained to ^[a-z]{2}[a-z]?(-(([A-Z][A-Z])?|([a-z]{2}[a-z]?)))?$  ",
							"type": "string",
							"format": "bcp47-codes"
						},
						{ "type": "null" } ]
				}
			},
			"anyOf": [
				{
					"required": [ "msgType", "preferredAudioLang" ]
				},
				{
					"required": [ "msgType", "preferredUILang" ]
				},
				{
					"required": [ "msgType", "preferredCaptionSubtitleLang" ]
				}
			]
		}
	},
	"required": [ "jsonrpc", "method", "params" ]
}
