From a4590bd4ceeadb9decf03200c1f24c3a3d113aa5 Mon Sep 17 00:00:00 2001 From: mark Date: Fri, 19 Jan 2024 13:12:51 +0000 Subject: [PATCH] Adding remaining CommsID and VIN --- 103280/TS_103_280.schema.json | 792 +++++++++++++++++----------------- 103280/TS_103_280.xsd | 5 + 103976/examples/example.json | 24 ++ 103976/ts_103976.schema.json | 146 +++++++ utils/json_validator.py | 1 + 5 files changed, 574 insertions(+), 394 deletions(-) create mode 100644 103976/examples/example.json create mode 100644 103976/ts_103976.schema.json diff --git a/103280/TS_103_280.schema.json b/103280/TS_103_280.schema.json index 1d1e0c0..77a8169 100644 --- a/103280/TS_103_280.schema.json +++ b/103280/TS_103_280.schema.json @@ -1,394 +1,398 @@ -{ - "$id": "ts_103280_2017_07", - "$defs": { - "ShortString": { - "type": "string", - "maxLength": 255 - }, - "LongString": { - "type": "string", - "maxLength": 65535 - }, - "LIID": { - "type": "string", - "pattern": "^([!-~]{1,25})|([0-9a-f]{26,50})$" - }, - "UTCDateTime": { - "type": "string", - "pattern": "^[0-9]{4}-[0-9]{2}-[0-9]{2}T[0-9]{2}:[0-9]{2}:[0-9]{2}Z$" - }, - "UTCMicrosecondDateTime": { - "type": "string", - "pattern": "^[0-9]{4}-[0-9]{2}-[0-9]{2}T[0-9]{2}:[0-9]{2}:[0-9]{2}\\.[0-9]{6}Z$" - }, - "QualifiedDateTime": { - "type": "string", - "pattern": "^[0-9]{4}-[0-9]{2}-[0-9]{2}T[0-9]{2}:[0-9]{2}:[0-9]{2}(Z|[+-][0-9]{2}:[0-9]{2})$" - }, - "QualifiedMicrosecondDateTime": { - "type": "string", - "pattern": "^[0-9]{4}-[0-9]{2}-[0-9]{2}T[0-9]{2}:[0-9]{2}:[0-9]{2}\\.[0-9]{6}(Z|[+-][0-9]{2}:[0-9]{2})$" - }, - "InternationalE164": { - "type": "string", - "pattern": "^[0-9]{1,15}$" - }, - "IMSI": { - "type": "string", - "pattern": "^[0-9]{6,15}$" - }, - "IMEI": { - "type": "string", - "pattern": "^[0-9]{14}$" - }, - "IMEICheckDigit": { - "type": "string", - "pattern": "^[0-9]{15}$" - }, - "IMEISV": { - "type": "string", - "pattern": "^[0-9]{16}$" - }, - "IPv4Address": { - "type": "string", - "pattern": "^((25[0-5]|2[0-4][0-9]|[01]?[0-9]?[0-9])\\.){3}(25[0-5]|2[0-4][0-9]|[01]?[0-9]?[0-9])$" - }, - "IPv4CIDR": { - "type": "string", - "pattern": "^((25[0-5]|2[0-4][0-9]|[01]?[0-9]?[0-9])\\.){3}(25[0-5]|2[0-4][0-9]|[01]?[0-9]?[0-9])/([1-2]?[0-9]|3[0-2])$" - }, - "IPv6Address": { - "type": "string", - "pattern": "^([0-9a-f]{4}:){7}([0-9a-f]{4})$" - }, - "IPv6CIDR": { - "type": "string", - "pattern": "^([0-9a-f]{4}:){7}([0-9a-f]{4})/(([1-9][0-9]?)|(1[0-1][0-9])|(12[0-8]))$" - }, - "TCPPort": { - "type": "integer", - "exclusiveMinimum": 1, - "maximum": 65535 - }, - "UDPPort": { - "type": "integer", - "minimum": 0, - "maximum": 65535 - }, - "MACAddress": { - "type": "string", - "pattern": "^([a-f0-9]{2}:){5}[a-f0-9]{2}$" - }, - "EmailAddress": { - "allOf": [ - { - "$ref": "#/$defs/ShortString" - }, - { - "type": "string", - "pattern": "^[a-zA-Z0-9\\.!#$%&'\\*\\+\\\\/=\\?\\^_`\\{\\|\\}~\\-]+@[a-zA-Z0-9]([a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(\\.[a-zA-Z0-9]([a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)*$" - } - ] - }, - "UUID": { - "type": "string", - "pattern": "^[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{12}$" - }, - "ISOCountryCode": { - "type": "string", - "pattern": "^[A-Z]{2}$" - }, - "SIPURI": { - "type": "string", - "pattern": "^sips?:[a-zA-Z0-9!#$&-;=?-\\[\\]_~%]+$" - }, - "TELURI": { - "type": "string", - "pattern": "^tel:[a-zA-Z0-9!#$&-;=?-\\[\\]_~%]+$" - }, - "WGS84LatitudeDecimal": { - "type": "string", - "pattern": "^[NS][0-9]{2}\\.[0-9]{6}$" - }, - "WGS84LongitudeDecimal": { - "type": "string", - "pattern": "^[EW][0-9]{3}\\.[0-9]{6}$" - }, - "WGS84LatitudeAngular": { - "type": "string", - "pattern": "^[NS][0-9]{6}\\.[0-9]{2}$" - }, - "WGS84LongitudeAngular": { - "type": "string", - "pattern": "^[EW][0-9]{7}\\.[0-9]{2}$" - }, - "SUPIIMSI": { - "$ref": "#/$defs/IMSI" - }, - "SUPINAI": { - "$ref": "#/$defs/NAI" - }, - "SUCI": { - "type": "string", - "pattern": "^([a-fA-F0-9]{2})*$" - }, - "PEIIMEI": { - "$ref": "#/$defs/IMEI" - }, - "PEIIMEICheckDigit": { - "$ref": "#/$defs/IMEICheckDigit" - }, - "PEIIMEISV": { - "$ref": "#/$defs/IMEISV" - }, - "GPSIMSISDN": { - "type": "string", - "pattern": "^[0-9]{1,15}$" - }, - "GPSINAI": { - "$ref": "#/$defs/NAI" - }, - "NAI": { - "type": "string" - }, - "LDID": { - "type": "string", - "pattern": "^([A-Z]{2}-.+-.+)$" - }, - "InternationalizedEmailAddress": { - "allOf": [ - { - "$ref": "#/$defs/ShortString" - }, - { - "type": "string", - "pattern": "^.+@.+$" - } - ] - }, - "EUI64": { - "type": "string", - "pattern": "^([a-f0-9]{2}:){7}[a-f0-9]{2}$" - }, - "CGI": { - "type": "string", - "pattern": "^[0-9]{3}-[0-9]{2,3}-[a-f0-9]{4}-[a-f0-9]{4}$" - }, - "ECGI": { - "type": "string", - "pattern": "^[0-9]{3}-[0-9]{2,3}-[a-f0-9]{7}$" - }, - "NCGI": { - "type": "string", - "pattern": "^[0-9]{3}-[0-9]{2,3}-[a-f0-9]{9}$" - }, - "ICCID": { - "type": "string", - "pattern": "^[0-9]{19,20}$" - }, - "IPProtocol": { - "type": "integer", - "minimum": 0, - "maximum": 255 - }, - "VLANID": { - "type": "integer", - "minimum": 0, - "maximum": 4095 - }, - "IPAddress": { - "oneOf": [ - { - "type": "object", - "properties": { - "etsi280:IPv4Address": { - "$ref": "#/$defs/IPv4Address" - } - }, - "required": [ - "etsi280:IPv4Address" - ] - }, - { - "type": "object", - "properties": { - "etsi280:IPv6Address": { - "$ref": "#/$defs/IPv6Address" - } - }, - "required": [ - "etsi280:IPv6Address" - ] - } - ] - }, - "IPCIDR": { - "oneOf": [ - { - "type": "object", - "properties": { - "etsi280:IPv4CIDR": { - "$ref": "#/$defs/IPv4CIDR" - } - }, - "required": [ - "etsi280:IPv4CIDR" - ] - }, - { - "type": "object", - "properties": { - "etsi280:IPv6CIDR": { - "$ref": "#/$defs/IPv6CIDR" - } - }, - "required": [ - "etsi280:IPv6CIDR" - ] - } - ] - }, - "TCPPortRange": { - "type": "object", - "properties": { - "etsi280:start": { - "$ref": "#/$defs/TCPPort" - }, - "etsi280:end": { - "$ref": "#/$defs/TCPPort" - } - }, - "required": [ - "etsi280:start", - "etsi280:end" - ] - }, - "UDPPortRange": { - "type": "object", - "properties": { - "etsi280:start": { - "$ref": "#/$defs/UDPPort" - }, - "etsi280:end": { - "$ref": "#/$defs/UDPPort" - } - }, - "required": [ - "etsi280:start", - "etsi280:end" - ] - }, - "Port": { - "oneOf": [ - { - "type": "object", - "properties": { - "etsi280:TCPPort": { - "$ref": "#/$defs/TCPPort" - } - }, - "required": [ - "etsi280:TCPPort" - ] - }, - { - "type": "object", - "properties": { - "etsi280:UDPPort": { - "$ref": "#/$defs/UDPPort" - } - }, - "required": [ - "etsi280:UDPPort" - ] - } - ] - }, - "PortRange": { - "oneOf": [ - { - "type": "object", - "properties": { - "etsi280:TCPPortRange": { - "$ref": "#/$defs/TCPPortRange" - } - }, - "required": [ - "etsi280:TCPPortRange" - ] - }, - { - "type": "object", - "properties": { - "etsi280:UDPPortRange": { - "$ref": "#/$defs/UDPPortRange" - } - }, - "required": [ - "etsi280:UDPPortRange" - ] - } - ] - }, - "IPAddressPort": { - "type": "object", - "properties": { - "etsi280:address": { - "$ref": "#/$defs/IPAddress" - }, - "etsi280:port": { - "$ref": "#/$defs/Port" - } - }, - "required": [ - "etsi280:address", - "etsi280:port" - ] - }, - "IPAddressPortRange": { - "type": "object", - "properties": { - "etsi280:address": { - "$ref": "#/$defs/IPAddress" - }, - "etsi280:portRange": { - "$ref": "#/$defs/PortRange" - } - }, - "required": [ - "etsi280:address", - "etsi280:portRange" - ] - }, - "WGS84CoordinateDecimal": { - "type": "object", - "properties": { - "etsi280:latitude": { - "$ref": "#/$defs/WGS84LatitudeDecimal" - }, - "etsi280:longitude": { - "$ref": "#/$defs/WGS84LongitudeDecimal" - } - }, - "required": [ - "etsi280:latitude", - "etsi280:longitude" - ] - }, - "WGS84CoordinateAngular": { - "type": "object", - "properties": { - "etsi280:latitude": { - "$ref": "#/$defs/WGS84LatitudeAngular" - }, - "etsi280:longitude": { - "$ref": "#/$defs/WGS84LongitudeAngular" - } - }, - "required": [ - "etsi280:latitude", - "etsi280:longitude" - ] - } - } -} +{ + "$id": "ts_103280_2017_07", + "$defs": { + "ShortString": { + "type": "string", + "maxLength": 255 + }, + "LongString": { + "type": "string", + "maxLength": 65535 + }, + "LIID": { + "type": "string", + "pattern": "^([!-~]{1,25})|([0-9a-f]{26,50})$" + }, + "UTCDateTime": { + "type": "string", + "pattern": "^[0-9]{4}-[0-9]{2}-[0-9]{2}T[0-9]{2}:[0-9]{2}:[0-9]{2}Z$" + }, + "UTCMicrosecondDateTime": { + "type": "string", + "pattern": "^[0-9]{4}-[0-9]{2}-[0-9]{2}T[0-9]{2}:[0-9]{2}:[0-9]{2}\\.[0-9]{6}Z$" + }, + "QualifiedDateTime": { + "type": "string", + "pattern": "^[0-9]{4}-[0-9]{2}-[0-9]{2}T[0-9]{2}:[0-9]{2}:[0-9]{2}(Z|[+-][0-9]{2}:[0-9]{2})$" + }, + "QualifiedMicrosecondDateTime": { + "type": "string", + "pattern": "^[0-9]{4}-[0-9]{2}-[0-9]{2}T[0-9]{2}:[0-9]{2}:[0-9]{2}\\.[0-9]{6}(Z|[+-][0-9]{2}:[0-9]{2})$" + }, + "InternationalE164": { + "type": "string", + "pattern": "^[0-9]{1,15}$" + }, + "IMSI": { + "type": "string", + "pattern": "^[0-9]{6,15}$" + }, + "IMEI": { + "type": "string", + "pattern": "^[0-9]{14}$" + }, + "IMEICheckDigit": { + "type": "string", + "pattern": "^[0-9]{15}$" + }, + "IMEISV": { + "type": "string", + "pattern": "^[0-9]{16}$" + }, + "IPv4Address": { + "type": "string", + "pattern": "^((25[0-5]|2[0-4][0-9]|[01]?[0-9]?[0-9])\\.){3}(25[0-5]|2[0-4][0-9]|[01]?[0-9]?[0-9])$" + }, + "IPv4CIDR": { + "type": "string", + "pattern": "^((25[0-5]|2[0-4][0-9]|[01]?[0-9]?[0-9])\\.){3}(25[0-5]|2[0-4][0-9]|[01]?[0-9]?[0-9])/([1-2]?[0-9]|3[0-2])$" + }, + "IPv6Address": { + "type": "string", + "pattern": "^([0-9a-f]{4}:){7}([0-9a-f]{4})$" + }, + "IPv6CIDR": { + "type": "string", + "pattern": "^([0-9a-f]{4}:){7}([0-9a-f]{4})/(([1-9][0-9]?)|(1[0-1][0-9])|(12[0-8]))$" + }, + "TCPPort": { + "type": "integer", + "exclusiveMinimum": 1, + "maximum": 65535 + }, + "UDPPort": { + "type": "integer", + "minimum": 0, + "maximum": 65535 + }, + "MACAddress": { + "type": "string", + "pattern": "^([a-f0-9]{2}:){5}[a-f0-9]{2}$" + }, + "EmailAddress": { + "allOf": [ + { + "$ref": "#/$defs/ShortString" + }, + { + "type": "string", + "pattern": "^[a-zA-Z0-9\\.!#$%&'\\*\\+\\\\/=\\?\\^_`\\{\\|\\}~\\-]+@[a-zA-Z0-9]([a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(\\.[a-zA-Z0-9]([a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)*$" + } + ] + }, + "UUID": { + "type": "string", + "pattern": "^[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{12}$" + }, + "ISOCountryCode": { + "type": "string", + "pattern": "^[A-Z]{2}$" + }, + "SIPURI": { + "type": "string", + "pattern": "^sips?:[a-zA-Z0-9!#$&-;=?-\\[\\]_~%]+$" + }, + "TELURI": { + "type": "string", + "pattern": "^tel:[a-zA-Z0-9!#$&-;=?-\\[\\]_~%]+$" + }, + "WGS84LatitudeDecimal": { + "type": "string", + "pattern": "^[NS][0-9]{2}\\.[0-9]{6}$" + }, + "WGS84LongitudeDecimal": { + "type": "string", + "pattern": "^[EW][0-9]{3}\\.[0-9]{6}$" + }, + "WGS84LatitudeAngular": { + "type": "string", + "pattern": "^[NS][0-9]{6}\\.[0-9]{2}$" + }, + "WGS84LongitudeAngular": { + "type": "string", + "pattern": "^[EW][0-9]{7}\\.[0-9]{2}$" + }, + "SUPIIMSI": { + "$ref": "#/$defs/IMSI" + }, + "SUPINAI": { + "$ref": "#/$defs/NAI" + }, + "SUCI": { + "type": "string", + "pattern": "^([a-fA-F0-9]{2})*$" + }, + "PEIIMEI": { + "$ref": "#/$defs/IMEI" + }, + "PEIIMEICheckDigit": { + "$ref": "#/$defs/IMEICheckDigit" + }, + "PEIIMEISV": { + "$ref": "#/$defs/IMEISV" + }, + "GPSIMSISDN": { + "type": "string", + "pattern": "^[0-9]{1,15}$" + }, + "GPSINAI": { + "$ref": "#/$defs/NAI" + }, + "NAI": { + "type": "string" + }, + "LDID": { + "type": "string", + "pattern": "^([A-Z]{2}-.+-.+)$" + }, + "InternationalizedEmailAddress": { + "allOf": [ + { + "$ref": "#/$defs/ShortString" + }, + { + "type": "string", + "pattern": "^.+@.+$" + } + ] + }, + "EUI64": { + "type": "string", + "pattern": "^([a-f0-9]{2}:){7}[a-f0-9]{2}$" + }, + "CGI": { + "type": "string", + "pattern": "^[0-9]{3}-[0-9]{2,3}-[a-f0-9]{4}-[a-f0-9]{4}$" + }, + "ECGI": { + "type": "string", + "pattern": "^[0-9]{3}-[0-9]{2,3}-[a-f0-9]{7}$" + }, + "NCGI": { + "type": "string", + "pattern": "^[0-9]{3}-[0-9]{2,3}-[a-f0-9]{9}$" + }, + "ICCID": { + "type": "string", + "pattern": "^[0-9]{19,20}$" + }, + "IPProtocol": { + "type": "integer", + "minimum": 0, + "maximum": 255 + }, + "VLANID": { + "type": "integer", + "minimum": 0, + "maximum": 4095 + }, + "VIN": { + "type": "string", + "pattern": "^[A-HJ-NPR-Z0-9]{17}$" + }, + "IPAddress": { + "oneOf": [ + { + "type": "object", + "properties": { + "etsi280:IPv4Address": { + "$ref": "#/$defs/IPv4Address" + } + }, + "required": [ + "etsi280:IPv4Address" + ] + }, + { + "type": "object", + "properties": { + "etsi280:IPv6Address": { + "$ref": "#/$defs/IPv6Address" + } + }, + "required": [ + "etsi280:IPv6Address" + ] + } + ] + }, + "IPCIDR": { + "oneOf": [ + { + "type": "object", + "properties": { + "etsi280:IPv4CIDR": { + "$ref": "#/$defs/IPv4CIDR" + } + }, + "required": [ + "etsi280:IPv4CIDR" + ] + }, + { + "type": "object", + "properties": { + "etsi280:IPv6CIDR": { + "$ref": "#/$defs/IPv6CIDR" + } + }, + "required": [ + "etsi280:IPv6CIDR" + ] + } + ] + }, + "TCPPortRange": { + "type": "object", + "properties": { + "etsi280:start": { + "$ref": "#/$defs/TCPPort" + }, + "etsi280:end": { + "$ref": "#/$defs/TCPPort" + } + }, + "required": [ + "etsi280:start", + "etsi280:end" + ] + }, + "UDPPortRange": { + "type": "object", + "properties": { + "etsi280:start": { + "$ref": "#/$defs/UDPPort" + }, + "etsi280:end": { + "$ref": "#/$defs/UDPPort" + } + }, + "required": [ + "etsi280:start", + "etsi280:end" + ] + }, + "Port": { + "oneOf": [ + { + "type": "object", + "properties": { + "etsi280:TCPPort": { + "$ref": "#/$defs/TCPPort" + } + }, + "required": [ + "etsi280:TCPPort" + ] + }, + { + "type": "object", + "properties": { + "etsi280:UDPPort": { + "$ref": "#/$defs/UDPPort" + } + }, + "required": [ + "etsi280:UDPPort" + ] + } + ] + }, + "PortRange": { + "oneOf": [ + { + "type": "object", + "properties": { + "etsi280:TCPPortRange": { + "$ref": "#/$defs/TCPPortRange" + } + }, + "required": [ + "etsi280:TCPPortRange" + ] + }, + { + "type": "object", + "properties": { + "etsi280:UDPPortRange": { + "$ref": "#/$defs/UDPPortRange" + } + }, + "required": [ + "etsi280:UDPPortRange" + ] + } + ] + }, + "IPAddressPort": { + "type": "object", + "properties": { + "etsi280:address": { + "$ref": "#/$defs/IPAddress" + }, + "etsi280:port": { + "$ref": "#/$defs/Port" + } + }, + "required": [ + "etsi280:address", + "etsi280:port" + ] + }, + "IPAddressPortRange": { + "type": "object", + "properties": { + "etsi280:address": { + "$ref": "#/$defs/IPAddress" + }, + "etsi280:portRange": { + "$ref": "#/$defs/PortRange" + } + }, + "required": [ + "etsi280:address", + "etsi280:portRange" + ] + }, + "WGS84CoordinateDecimal": { + "type": "object", + "properties": { + "etsi280:latitude": { + "$ref": "#/$defs/WGS84LatitudeDecimal" + }, + "etsi280:longitude": { + "$ref": "#/$defs/WGS84LongitudeDecimal" + } + }, + "required": [ + "etsi280:latitude", + "etsi280:longitude" + ] + }, + "WGS84CoordinateAngular": { + "type": "object", + "properties": { + "etsi280:latitude": { + "$ref": "#/$defs/WGS84LatitudeAngular" + }, + "etsi280:longitude": { + "$ref": "#/$defs/WGS84LongitudeAngular" + } + }, + "required": [ + "etsi280:latitude", + "etsi280:longitude" + ] + } + } +} \ No newline at end of file diff --git a/103280/TS_103_280.xsd b/103280/TS_103_280.xsd index 1eb1228..a34bab2 100644 --- a/103280/TS_103_280.xsd +++ b/103280/TS_103_280.xsd @@ -278,4 +278,9 @@ + + + + + diff --git a/103976/examples/example.json b/103976/examples/example.json new file mode 100644 index 0000000..f8090ee --- /dev/null +++ b/103976/examples/example.json @@ -0,0 +1,24 @@ +{ + "VINtoLocationRecords" : [ + { + "Location" : { + "WGS84CoordinateDecimal" : { + "etsi280:latitude" : "N54.123456", + "etsi280:longitude" : "W001.123456" + } + }, + "TimeOfLocation" : { + "PointInTime" : "2022-01-16T15:57:00Z" + }, + "CommunicationsIdentifier" : { + "IMSI" : "0123456" + }, + "AssociationTime" : { + "PeriodInTime" : { + "StartTime" : "2022-01-16T15:57:00Z", + "EndTime" : "2022-01-16T15:57:00Z" + } + } + } + ] +} \ No newline at end of file diff --git a/103976/ts_103976.schema.json b/103976/ts_103976.schema.json new file mode 100644 index 0000000..008c083 --- /dev/null +++ b/103976/ts_103976.schema.json @@ -0,0 +1,146 @@ +{ + "$id": "ts_103976_core", + "$defs": { + "AssociationPeriod" : { + "type" : "object", + "properties" : { + "StartTime" : { "$ref": "ts_103280_2017_07#/$defs/QualifiedDateTime" }, + "EndTime" : { "$ref": "ts_103280_2017_07#/$defs/QualifiedDateTime" } + }, + "required" : ["StartTime"] + }, + "AssociationTime" : { + "oneOf" : [ + { + "type" : "object", + "properties" : { + "PointInTime" : { "$ref": "ts_103280_2017_07#/$defs/QualifiedDateTime" } + }, + "required" : ["PointInTime"] + }, + { + "type" : "object", + "properties" : { + "PeriodInTime" : { "$ref": "#/$defs/AssociationPeriod" } + }, + "required" : ["PeriodInTime"] + } + ] + }, + "CommsID" : { + "oneOf" : [ + { + "type" : "object", + "properties" : { "IMEI" : { "$ref" : "ts_103280_2017_07#/$defs/IMEI"} }, + "required" : ["IMEI"] + }, + { + "type" : "object", + "properties" : { "IMSI" : { "$ref" : "ts_103280_2017_07#/$defs/IMSI"} }, + "required" : ["IMSI"] + }, + { + "type" : "object", + "properties" : { "IMSI" : { "$ref" : "ts_103280_2017_07#/$defs/ICCID"} }, + "required" : ["ICCID"] + }, + { + "type" : "object", + "properties" : { "IMSI" : { "$ref" : "ts_103280_2017_07#/$defs/PEIIMEI"} }, + "required" : ["PEIIMEI"] + }, + { + "type" : "object", + "properties" : { "IMSI" : { "$ref" : "ts_103280_2017_07#/$defs/SUPIIMSI"} }, + "required" : ["SUPIIMSI"] + }, + { + "type" : "object", + "properties" : { "IMSI" : { "$ref" : "ts_103280_2017_07#/$defs/SUPINAI"} }, + "required" : ["SUPINAI"] + }, + { + "type" : "object", + "properties" : { "IMSI" : { "$ref" : "ts_103280_2017_07#/$defs/InternationalE164"} }, + "required" : ["MSISDN"] + }, + { + "type" : "object", + "properties" : { "IMSI" : { "$ref" : "ts_103280_2017_07#/$defs/GPSIMSISDN"} }, + "required" : ["GPSIMSISDN"] + }, + { + "type" : "object", + "properties" : { "IMSI" : { "$ref" : "ts_103280_2017_07#/$defs/GPSINAI"} }, + "required" : ["GPSINAI"] + }, + { + "type" : "object", + "properties" : { "IMSI" : { "$ref" : "ts_103280_2017_07#/$defs/MACAddress"} }, + "required" : ["MACAddress"] + }, + { + "type" : "object", + "properties" : { "IMSI" : { "$ref" : "ts_103280_2017_07#/$defs/EUI64"} }, + "required" : ["EUI164"] + } + ] + }, + "Location" : { + "oneOf" : [ + { + "type" : "object", + "properties" : { + "WGS84CoordinateDecimal" : { "$ref" : "ts_103280_2017_07#/$defs/WGS84CoordinateDecimal"} + } + } + ] + }, + "SourceOfLocation" : { + "enum" : ["GNSS"] + }, + "VINtoCommsIDRecord" : { + "type" : "object", + "properties" : { + "CommsID" : { "$ref" : "#/$defs/CommsID" }, + "AssociationTime" : { "$ref" : "#/$defs/AssociationTime"} + }, + "required" : ["CommsID"] + }, + "CommsIDToVINRecord" : { + "type" : "object", + "properties" : { + "VIN" : { "$ref" : "ts_103280_2017_07#/$defs/VIN" } + }, + "required" : ["VIN"] + }, + "VINtoLocationRecord" : { + "type" : "object", + "properties" : { + "Location" : { "$ref" : "#/$defs/Location" }, + "TimeOfLocation" : { "$ref" : "#/$defs/AssociationTime" }, + "SourceOfLocation" : { "$ref" : "#/$defs/SourceOfLocation" }, + "LocationRecordReason" : { "$ref" : "ts_103280_2017_07#/$defs/LongString" } + }, + "required" : ["Location", "TimeOfLocation"] + }, + "ResultRecords" : { + "type" : "object", + "properties" : { + "VINtoCommsIDRecords" : { + "type" : "array", + "items" : { "$ref" : "#/$defs/VINtoCommsIDRecord"} + }, + "CommsIDToVINRecords" : { + "type" : "array", + "items" : { "$ref" : "#/$defs/CommsIDToVINRecord"} + }, + "VINtoLocationRecords" : { + "type" : "array", + "items" : { "$ref" : "#/$defs/VINtoLocationRecord"} + } + } + } + }, + "$ref": "#/$defs/ResultRecords" +} \ No newline at end of file diff --git a/utils/json_validator.py b/utils/json_validator.py index fb46193..e9ff0c0 100644 --- a/utils/json_validator.py +++ b/utils/json_validator.py @@ -151,6 +151,7 @@ if __name__ == "__main__": logging.info(f"{len(errors)} errors detected") if len(errors) > 0: + logging.info(errors) exit(-1) else: exit(0) -- GitLab