{
	"$schema": "https://json-schema.org/draft/2020-12/schema",
	"$id": "https://schema.twindev.org/w3c-odrl/OdrlConstraint",
	"title": "OdrlConstraint",
	"description": "Interface for ODRL Constraints.\nhttps://www.w3.org/TR/odrl-model/#constraint",
	"type": "object",
	"properties": {
		"uid": {
			"type": "string",
			"description": "Optional unique identifier for the constraint."
		},
		"leftOperand": {
			"anyOf": [
				{
					"type": "string"
				},
				{
					"$ref": "https://schema.twindev.org/w3c-odrl/OdrlLeftOperandType"
				}
			],
			"description": "The left operand of the constraint."
		},
		"operator": {
			"$ref": "https://schema.twindev.org/w3c-odrl/OdrlOperatorType",
			"description": "The operator of the constraint."
		},
		"rightOperand": {
			"anyOf": [
				{
					"type": "string"
				},
				{
					"type": "object",
					"properties": {
						"@value": {
							"type": "string"
						},
						"@type": {
							"type": "string"
						}
					},
					"required": ["@value"]
				},
				{
					"type": "object",
					"properties": {
						"@id": {
							"type": "string"
						}
					},
					"required": ["@id"]
				},
				{
					"type": "array",
					"items": {
						"anyOf": [
							{
								"type": "string"
							},
							{
								"type": "object",
								"properties": {
									"@value": {
										"type": "string"
									},
									"@type": {
										"type": "string"
									}
								},
								"required": ["@value"]
							},
							{
								"type": "object",
								"properties": {
									"@id": {
										"type": "string"
									}
								},
								"required": ["@id"]
							}
						]
					}
				}
			],
			"description": "The right operand of the constraint.\nvalue with optional"
		},
		"rightOperandReference": {
			"anyOf": [
				{
					"type": "string"
				},
				{
					"type": "array",
					"items": {
						"type": "string"
					}
				}
			],
			"description": "Reference to the right operand.\nCan be used to reference external resources or policies using an IRI.\nMutually exclusive with rightOperand."
		},
		"dataType": {
			"type": "string",
			"description": "The data type of the right operand."
		},
		"unit": {
			"type": "string",
			"description": "The unit for the right operand value."
		},
		"status": {
			"$ref": "https://schema.twindev.org/w3c-odrl/OdrlStatusType",
			"description": "The status value for comparison."
		}
	},
	"required": ["leftOperand", "operator"]
}
