@dvsa/cvs-type-definitions 1.0.11

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (33) hide show
  1. package/README.md +53 -0
  2. package/json-schemas/.DS_Store +0 -0
  3. package/json-schemas/activity/index.json +62 -0
  4. package/json-schemas/defect-category-reference-data/index.json +440 -0
  5. package/json-schemas/defect-details/index.json +265 -0
  6. package/json-schemas/defect-location/index.json +49 -0
  7. package/json-schemas/reason-item/index.json +17 -0
  8. package/json-schemas/tech-record/index.json +639 -0
  9. package/json-schemas/test/index.json +1843 -0
  10. package/json-schemas/test-result/index.json +636 -0
  11. package/json-schemas/test-station/index.json +67 -0
  12. package/json-schemas/test-type/index.json +479 -0
  13. package/json-schemas/vehicle/index.json +1804 -0
  14. package/json-schemas/vehicle-tech-record/index.json +683 -0
  15. package/json-schemas/visit/index.json +1895 -0
  16. package/lib/schemas.d.ts +1 -0
  17. package/lib/schemas.js +18 -0
  18. package/lib/src/schema-validation/schema-validator.d.ts +3 -0
  19. package/lib/src/schema-validation/schema-validator.js +22 -0
  20. package/package.json +35 -0
  21. package/types/activity/index.d.ts +23 -0
  22. package/types/defect-category-reference-data/index.d.ts +52 -0
  23. package/types/defect-details/index.d.ts +53 -0
  24. package/types/defect-location/index.d.ts +16 -0
  25. package/types/reason-item/index.d.ts +11 -0
  26. package/types/tech-record/index.d.ts +202 -0
  27. package/types/test/index.d.ts +353 -0
  28. package/types/test-result/index.d.ts +136 -0
  29. package/types/test-station/index.d.ts +23 -0
  30. package/types/test-type/index.d.ts +98 -0
  31. package/types/vehicle/index.d.ts +345 -0
  32. package/types/vehicle-tech-record/index.d.ts +212 -0
  33. package/types/visit/index.d.ts +366 -0
@@ -0,0 +1,1843 @@
1
+ {
2
+ "title": "Commercial Vehicle Test Schema",
3
+ "type": "object",
4
+ "additionalProperties": false,
5
+ "definitions": {},
6
+ "properties": {
7
+ "testResultId": {
8
+ "type": "string"
9
+ },
10
+ "startTime": {
11
+ "type": "string"
12
+ },
13
+ "endTime": {
14
+ "type": "string"
15
+ },
16
+ "status": {
17
+ "enum": [
18
+ "submitted",
19
+ "cancelled",
20
+ null
21
+ ],
22
+ "type": "string"
23
+ },
24
+ "reasonForCancellation": {
25
+ "type": "string"
26
+ },
27
+ "vehicles": {
28
+ "type": "array",
29
+ "items": {
30
+ "title": "Vehicle Schema",
31
+ "type": "object",
32
+ "properties": {
33
+ "systemNumber": {
34
+ "type": "string"
35
+ },
36
+ "vrm": {
37
+ "type": "string"
38
+ },
39
+ "vin": {
40
+ "type": "string"
41
+ },
42
+ "techRecord": {
43
+ "title": "Tech Record Schema",
44
+ "type": "object",
45
+ "properties": {
46
+ "bodyType": {
47
+ "properties": {
48
+ "code": {
49
+ "type": "string"
50
+ },
51
+ "description": {
52
+ "type": "string"
53
+ }
54
+ },
55
+ "additionalProperties": false,
56
+ "required": [
57
+ "code",
58
+ "description"
59
+ ]
60
+ },
61
+ "manufactureYear": {
62
+ "type": "integer"
63
+ },
64
+ "regnDate": {
65
+ "type": "string"
66
+ },
67
+ "ntaNumber": {
68
+ "type": "string"
69
+ },
70
+ "conversionRefNo": {
71
+ "type": "string"
72
+ },
73
+ "speedLimiterMrk": {
74
+ "type": "boolean"
75
+ },
76
+ "tachoExemptMrk": {
77
+ "type": "boolean"
78
+ },
79
+ "reasonForCreation": {
80
+ "type": "string"
81
+ },
82
+ "statusCode": {
83
+ "type": "string"
84
+ },
85
+ "grossKerbWeight": {
86
+ "type": "integer"
87
+ },
88
+ "grossLadenWeight": {
89
+ "type": "integer"
90
+ },
91
+ "noOfAxles": {
92
+ "type": "integer"
93
+ },
94
+ "brakeCode": {
95
+ "type": "string"
96
+ },
97
+ "vehicleType": {
98
+ "type": "string"
99
+ },
100
+ "euVehicleCategory": {
101
+ "type": "string"
102
+ },
103
+ "axles": {
104
+ "type": "array",
105
+ "items": {
106
+ "title": "Axle Schema",
107
+ "type": "object",
108
+ "properties": {
109
+ "parkingBrakeMrk": {
110
+ "type": "boolean"
111
+ },
112
+ "axleNumber": {
113
+ "type": "integer"
114
+ },
115
+ "weights": {
116
+ "title": "Weights Schema",
117
+ "type": "object",
118
+ "properties": {
119
+ "kerbWeight": {
120
+ "type": "integer"
121
+ },
122
+ "ladenWeight": {
123
+ "type": "integer"
124
+ },
125
+ "gbWeight": {
126
+ "type": "integer"
127
+ },
128
+ "designWeight": {
129
+ "type": "integer"
130
+ }
131
+ },
132
+ "additionalProperties": false,
133
+ "required": [
134
+ "gbWeight",
135
+ "designWeight"
136
+ ]
137
+ },
138
+ "tyres": {
139
+ "title": "Tyres Schema",
140
+ "type": "object",
141
+ "properties": {
142
+ "tyreSize": {
143
+ "type": "string"
144
+ },
145
+ "plyRating": {
146
+ "type": "string"
147
+ },
148
+ "fitmentCode": {
149
+ "type": "string"
150
+ },
151
+ "dataTrPsvAxles": {
152
+ "type": "integer"
153
+ },
154
+ "tyreCode": {
155
+ "type": "number"
156
+ },
157
+ "dataTrAxles": {
158
+ "type": "number"
159
+ },
160
+ "speedCategorySymbol": {
161
+ "description": "PSV only",
162
+ "type": "string"
163
+ }
164
+ },
165
+ "additionalProperties": false,
166
+ "required": [
167
+ "tyreSize",
168
+ "plyRating",
169
+ "fitmentCode",
170
+ "tyreCode"
171
+ ]
172
+ },
173
+ "brakes": {
174
+ "title": "Axle Brake Properties Schema",
175
+ "type": "object",
176
+ "properties": {
177
+ "brakeActuator": {
178
+ "type": "integer"
179
+ },
180
+ "leverLength": {
181
+ "type": "integer"
182
+ },
183
+ "springBrakeParking": {
184
+ "type": "boolean"
185
+ }
186
+ },
187
+ "required": [
188
+ "brakeActuator",
189
+ "leverLength",
190
+ "springBrakeParking"
191
+ ],
192
+ "additionalProperties": false
193
+ }
194
+ },
195
+ "required": [
196
+ "axleNumber",
197
+ "tyres"
198
+ ],
199
+ "additionalProperties": false
200
+ },
201
+ "additionalProperties": false
202
+ },
203
+ "vehicleClass": {
204
+ "title": "Vehicle Class Schema",
205
+ "type": "object",
206
+ "properties": {
207
+ "code": {
208
+ "type": "string"
209
+ },
210
+ "description": {
211
+ "type": "string"
212
+ }
213
+ },
214
+ "additionalProperties": false,
215
+ "required": [
216
+ "code",
217
+ "description"
218
+ ]
219
+ },
220
+ "vehicleSubclass": {
221
+ "type": "array",
222
+ "items": {
223
+ "type": "string"
224
+ }
225
+ },
226
+ "vehicleConfiguration": {
227
+ "type": "string"
228
+ },
229
+ "recordCompleteness": {
230
+ "type": "string"
231
+ },
232
+ "chassisMake": {
233
+ "type": "string"
234
+ },
235
+ "chassisModel": {
236
+ "type": "string"
237
+ },
238
+ "bodyMake": {
239
+ "type": "string"
240
+ },
241
+ "bodyModel": {
242
+ "type": "string"
243
+ },
244
+ "vehicleSize": {
245
+ "type": "string"
246
+ },
247
+ "coifDate": {
248
+ "type": "string"
249
+ },
250
+ "unladenWeight": {
251
+ "type": "integer"
252
+ },
253
+ "grossGbWeight": {
254
+ "type": "integer"
255
+ },
256
+ "grossDesignWeight": {
257
+ "type": "integer"
258
+ },
259
+ "grossUnladenWeight": {
260
+ "type": "integer"
261
+ },
262
+ "seatsLowerDeck": {
263
+ "type": "integer"
264
+ },
265
+ "seatsUpperDeck": {
266
+ "type": "integer"
267
+ },
268
+ "standingCapacity": {
269
+ "type": "integer"
270
+ },
271
+ "speedRestriction": {
272
+ "type": "integer"
273
+ },
274
+ "dispensations": {
275
+ "type": "string"
276
+ },
277
+ "remarks": {
278
+ "type": "string"
279
+ },
280
+ "brakes": {
281
+ "title": "Brake",
282
+ "type": "object",
283
+ "properties": {
284
+ "brakeCode": {
285
+ "type": "string"
286
+ },
287
+ "dataTrBrakeOne": {
288
+ "type": "string"
289
+ },
290
+ "dataTrBrakeTwo": {
291
+ "type": "string"
292
+ },
293
+ "dataTrBrakeThree": {
294
+ "type": "string"
295
+ },
296
+ "retarderBrakeOne": {
297
+ "type": "string"
298
+ },
299
+ "retarderBrakeTwo": {
300
+ "type": "string"
301
+ },
302
+ "brakeCodeOriginal": {
303
+ "type": "string"
304
+ },
305
+ "brakeForceWheelsNotLocked": {
306
+ "title": "Brake Force Wheel",
307
+ "type": "object",
308
+ "properties": {
309
+ "serviceBrakeForce": {
310
+ "type": "integer"
311
+ },
312
+ "secondaryBrakeForce": {
313
+ "type": "integer"
314
+ },
315
+ "parkingBrakeForce": {
316
+ "type": "integer"
317
+ }
318
+ },
319
+ "required": [
320
+ "serviceBrakeForce",
321
+ "secondaryBrakeForce",
322
+ "parkingBrakeForce"
323
+ ],
324
+ "additionalProperties": false
325
+ },
326
+ "brakeForceWheelsUpToHalfLocked": {
327
+ "title": "Brake Force Wheel",
328
+ "type": "object",
329
+ "properties": {
330
+ "serviceBrakeForce": {
331
+ "type": "integer"
332
+ },
333
+ "secondaryBrakeForce": {
334
+ "type": "integer"
335
+ },
336
+ "parkingBrakeForce": {
337
+ "type": "integer"
338
+ }
339
+ },
340
+ "required": [
341
+ "serviceBrakeForce",
342
+ "secondaryBrakeForce",
343
+ "parkingBrakeForce"
344
+ ],
345
+ "additionalProperties": false
346
+ },
347
+ "dtpNumber": {
348
+ "type": "string"
349
+ },
350
+ "loadSensingValve": {
351
+ "type": "boolean"
352
+ },
353
+ "antilockBrakingSystem": {
354
+ "type": "boolean"
355
+ }
356
+ },
357
+ "additionalProperties": false
358
+ },
359
+ "make": {
360
+ "type": "string"
361
+ },
362
+ "model": {
363
+ "type": "string"
364
+ },
365
+ "functionCode": {
366
+ "type": "string"
367
+ },
368
+ "typeUseCode": {
369
+ "type": "string"
370
+ },
371
+ "roadFriendly": {
372
+ "type": "boolean"
373
+ },
374
+ "drawbarCouplingFitted": {
375
+ "type": "boolean"
376
+ },
377
+ "dimensions": {
378
+ "title": "Dimensions Schema",
379
+ "type": "object",
380
+ "properties": {
381
+ "length": {
382
+ "type": "integer"
383
+ },
384
+ "width": {
385
+ "type": "integer"
386
+ },
387
+ "axleSpacing": {
388
+ "type": "array",
389
+ "items": {
390
+ "properties": {
391
+ "axles": {
392
+ "type": "string"
393
+ },
394
+ "value": {
395
+ "type": "integer"
396
+ }
397
+ },
398
+ "required": [
399
+ "axles",
400
+ "value"
401
+ ],
402
+ "additionalProperties": false
403
+ },
404
+ "minItems": 1,
405
+ "maxItems": 1
406
+ }
407
+ },
408
+ "required": [
409
+ "length",
410
+ "width",
411
+ "axleSpacing"
412
+ ],
413
+ "additionalProperties": false
414
+ },
415
+ "notes": {
416
+ "type": "string"
417
+ },
418
+ "adrDetails": {
419
+ "title": "ADR Details Schema",
420
+ "type": "object",
421
+ "properties": {
422
+ "vehicleDetails": {
423
+ "type": "object",
424
+ "properties": {
425
+ "type": {
426
+ "type": "string"
427
+ },
428
+ "approvalDate": {
429
+ "type": "string"
430
+ }
431
+ },
432
+ "additionalProperties": false
433
+ },
434
+ "listStatementApplicable": {
435
+ "type": "boolean"
436
+ },
437
+ "batteryListNumber": {
438
+ "type": "string"
439
+ },
440
+ "permittedDangerousGoods": {
441
+ "type": "array",
442
+ "items": {
443
+ "type": "string"
444
+ }
445
+ },
446
+ "additionalExaminerNotes": {
447
+ "type": "string"
448
+ },
449
+ "applicantDetails": {
450
+ "title": "Applicant Details Schema",
451
+ "type": "object",
452
+ "properties": {
453
+ "name": {
454
+ "type": "string"
455
+ },
456
+ "street": {
457
+ "type": "string"
458
+ },
459
+ "town": {
460
+ "type": "string"
461
+ },
462
+ "city": {
463
+ "type": "string"
464
+ },
465
+ "postcode": {
466
+ "type": "string"
467
+ }
468
+ },
469
+ "additionalProperties": false
470
+ },
471
+ "memosApply": {
472
+ "type": "array",
473
+ "items": {
474
+ "type": "string"
475
+ }
476
+ },
477
+ "additionalNotes": {
478
+ "type": "object",
479
+ "properties": {
480
+ "number": {
481
+ "type": "array",
482
+ "items": {
483
+ "type": "string"
484
+ }
485
+ },
486
+ "guidanceNotes": {
487
+ "type": "array",
488
+ "items": {
489
+ "type": "string"
490
+ }
491
+ }
492
+ },
493
+ "additionalProperties": false
494
+ },
495
+ "adrTypeApprovalNo": {
496
+ "type": "string"
497
+ },
498
+ "compatibilityGroupJ": {
499
+ "type": "boolean"
500
+ },
501
+ "tank": {
502
+ "title": "Tank Schema",
503
+ "type": "object",
504
+ "properties": {
505
+ "tankDetails": {
506
+ "title": "Tank Details Schema",
507
+ "type": "object",
508
+ "properties": {
509
+ "tankManufacturer": {
510
+ "type": "string"
511
+ },
512
+ "tc2Details": {
513
+ "title": "TC2 Details Schema",
514
+ "type": "object",
515
+ "properties": {
516
+ "tc2Type": {
517
+ "type": "string"
518
+ },
519
+ "tc2IntermediateApprovalNo": {
520
+ "type": "string"
521
+ },
522
+ "tc2IntermediateExpiryDate": {
523
+ "type": "string"
524
+ }
525
+ },
526
+ "additionalProperties": false
527
+ },
528
+ "tc3Details": {
529
+ "type": "array",
530
+ "items": {
531
+ "title": "TC3 Details Schema",
532
+ "type": "object",
533
+ "properties": {
534
+ "tc3Type": {
535
+ "type": "string"
536
+ },
537
+ "tc3IntermediateApprovalNo": {
538
+ "type": "string"
539
+ },
540
+ "tc3IntermediateExpiryDate": {
541
+ "type": "string"
542
+ }
543
+ },
544
+ "additionalProperties": false
545
+ }
546
+ },
547
+ "yearOfManufacture": {
548
+ "type": "string"
549
+ },
550
+ "tankCode": {
551
+ "type": "string"
552
+ },
553
+ "specialProvisions": {
554
+ "type": "string"
555
+ },
556
+ "tankManufacturerSerialNo": {
557
+ "type": "string"
558
+ },
559
+ "tankTypeAppNo": {
560
+ "type": "string"
561
+ }
562
+ },
563
+ "additionalProperties": false
564
+ },
565
+ "tankStatement": {
566
+ "title": "Tank Statement Schema",
567
+ "type": "object",
568
+ "properties": {
569
+ "substancesPermitted": {
570
+ "type": "string"
571
+ },
572
+ "statement": {
573
+ "type": "string"
574
+ },
575
+ "productList": {
576
+ "type": "string"
577
+ },
578
+ "productListRefNo": {
579
+ "type": "string"
580
+ },
581
+ "productListUnNo": {
582
+ "type": "array",
583
+ "items": {
584
+ "type": "string"
585
+ }
586
+ }
587
+ },
588
+ "additionalProperties": false
589
+ }
590
+ },
591
+ "additionalProperties": false
592
+ }
593
+ },
594
+ "additionalProperties": false
595
+ },
596
+ "trainGbWeight": {
597
+ "type": "integer"
598
+ },
599
+ "trainDesignWeight": {
600
+ "type": "integer"
601
+ },
602
+ "maxTrainGbWeight": {
603
+ "type": "integer"
604
+ },
605
+ "maxTrainDesignWeight": {
606
+ "type": "integer"
607
+ },
608
+ "euroStandard": {
609
+ "type": "integer"
610
+ },
611
+ "frontAxleTo5thWheelMin": {
612
+ "type": "integer"
613
+ },
614
+ "frontAxleTo5thWheelMax": {
615
+ "type": "integer"
616
+ },
617
+ "frontAxleTo5thWheelCouplingMin": {
618
+ "type": "integer"
619
+ },
620
+ "frontAxleTo5thWheelCouplingMax": {
621
+ "type": "integer"
622
+ },
623
+ "firstUseDate": {
624
+ "type": "string"
625
+ },
626
+ "maxLoadOnCoupling": {
627
+ "type": "integer"
628
+ },
629
+ "suspensionType": {
630
+ "type": "string"
631
+ },
632
+ "couplingType": {
633
+ "type": "string"
634
+ },
635
+ "frontAxleToRearAxle": {
636
+ "type": "integer"
637
+ },
638
+ "rearAxleToRearTrl": {
639
+ "type": "integer"
640
+ },
641
+ "couplingCenterToRearAxleMin": {
642
+ "type": "integer"
643
+ },
644
+ "couplingCenterToRearAxleMax": {
645
+ "type": "integer"
646
+ },
647
+ "couplingCenterToRearTrlMin": {
648
+ "type": "integer"
649
+ },
650
+ "couplingCenterToRearTrlMax": {
651
+ "type": "integer"
652
+ },
653
+ "numberOfWheelsDriven": {
654
+ "type": "integer"
655
+ }
656
+ },
657
+ "additionalProperties": false,
658
+ "required": [
659
+ "bodyType",
660
+ "regnDate",
661
+ "manufactureYear",
662
+ "ntaNumber",
663
+ "conversionRefNo",
664
+ "speedLimiterMrk",
665
+ "tachoExemptMrk",
666
+ "reasonForCreation",
667
+ "statusCode",
668
+ "grossKerbWeight",
669
+ "grossLadenWeight",
670
+ "noOfAxles",
671
+ "brakeCode",
672
+ "vehicleType",
673
+ "euVehicleCategory",
674
+ "axles",
675
+ "vehicleClass",
676
+ "vehicleSubclass",
677
+ "vehicleConfiguration",
678
+ "notes"
679
+ ]
680
+ },
681
+ "testResultsHistory": {
682
+ "type": "array",
683
+ "items": {
684
+ "title": "Test Result Schema",
685
+ "type": "object",
686
+ "properties": {
687
+ "testResultId": {
688
+ "type": "string"
689
+ },
690
+ "testStationName": {
691
+ "type": "string"
692
+ },
693
+ "testStationPNumber": {
694
+ "type": "string"
695
+ },
696
+ "testStationType": {
697
+ "type": "string"
698
+ },
699
+ "testerName": {
700
+ "type": "string"
701
+ },
702
+ "testerStaffId": {
703
+ "type": "string"
704
+ },
705
+ "testerEmailAddress": {
706
+ "type": "string"
707
+ },
708
+ "testStartTimestamp": {
709
+ "type": "string"
710
+ },
711
+ "testEndTimestamp": {
712
+ "type": "string"
713
+ },
714
+ "testStatus": {
715
+ "type": "string"
716
+ },
717
+ "reasonForCancellation": {
718
+ "type": [
719
+ "string",
720
+ "null"
721
+ ]
722
+ },
723
+ "systemNumber": {
724
+ "type": "string"
725
+ },
726
+ "vrm": {
727
+ "type": "string"
728
+ },
729
+ "trailerId": {
730
+ "type": "string"
731
+ },
732
+ "vin": {
733
+ "type": "string"
734
+ },
735
+ "vehicleClass": {
736
+ "title": "Vehicle Class Schema",
737
+ "type": "object",
738
+ "properties": {
739
+ "code": {
740
+ "type": "string"
741
+ },
742
+ "description": {
743
+ "type": "string"
744
+ }
745
+ },
746
+ "additionalProperties": false,
747
+ "required": [
748
+ "code",
749
+ "description"
750
+ ]
751
+ },
752
+ "vehicleSubclass": {
753
+ "type": "array",
754
+ "items": {
755
+ "type": "string"
756
+ }
757
+ },
758
+ "vehicleType": {
759
+ "type": "string"
760
+ },
761
+ "vehicleConfiguration": {
762
+ "type": "string"
763
+ },
764
+ "odometerReading": {
765
+ "type": [
766
+ "number",
767
+ "null"
768
+ ]
769
+ },
770
+ "odometerReadingUnits": {
771
+ "type": [
772
+ "string",
773
+ "null"
774
+ ]
775
+ },
776
+ "preparerId": {
777
+ "type": "string"
778
+ },
779
+ "preparerName": {
780
+ "type": "string"
781
+ },
782
+ "euVehicleCategory": {
783
+ "type": "string"
784
+ },
785
+ "countryOfRegistration": {
786
+ "type": [
787
+ "string",
788
+ "null"
789
+ ]
790
+ },
791
+ "noOfAxles": {
792
+ "type": "integer"
793
+ },
794
+ "numberOfWheelsDriven": {
795
+ "type": "integer"
796
+ },
797
+ "vehicleSize": {
798
+ "type": "string"
799
+ },
800
+ "numberOfSeats": {
801
+ "type": "integer"
802
+ },
803
+ "regnDate": {
804
+ "type": "string"
805
+ },
806
+ "firstUseDate": {
807
+ "type": "string"
808
+ },
809
+ "testTypes": {
810
+ "type": "array",
811
+ "items": {
812
+ "title": "Test Type Schema",
813
+ "type": "object",
814
+ "properties": {
815
+ "testTypeName": {
816
+ "type": "string"
817
+ },
818
+ "name": {
819
+ "type": "string"
820
+ },
821
+ "testTypeId": {
822
+ "type": "string"
823
+ },
824
+ "certificateNumber": {
825
+ "type": [
826
+ "string",
827
+ "null"
828
+ ]
829
+ },
830
+ "secondaryCertificateNumber": {
831
+ "type": [
832
+ "string",
833
+ "null"
834
+ ]
835
+ },
836
+ "testTypeStartTimestamp": {
837
+ "type": [
838
+ "string",
839
+ "null"
840
+ ]
841
+ },
842
+ "testTypeEndTimestamp": {
843
+ "type": [
844
+ "string",
845
+ "null"
846
+ ]
847
+ },
848
+ "testResult": {
849
+ "type": [
850
+ "string",
851
+ "null"
852
+ ]
853
+ },
854
+ "prohibitionIssued": {
855
+ "type": [
856
+ "boolean",
857
+ "null"
858
+ ]
859
+ },
860
+ "reasonForAbandoning": {
861
+ "type": [
862
+ "string",
863
+ "null"
864
+ ]
865
+ },
866
+ "additionalNotesRecorded": {
867
+ "type": [
868
+ "string",
869
+ "null"
870
+ ]
871
+ },
872
+ "additionalCommentsForAbandon": {
873
+ "type": [
874
+ "string",
875
+ "null"
876
+ ]
877
+ },
878
+ "numberOfSeatbeltsFitted": {
879
+ "type": [
880
+ "integer",
881
+ "null"
882
+ ]
883
+ },
884
+ "lastSeatbeltInstallationCheckDate": {
885
+ "type": [
886
+ "string",
887
+ "null"
888
+ ]
889
+ },
890
+ "seatbeltInstallationCheckDate": {
891
+ "type": [
892
+ "boolean",
893
+ "null"
894
+ ]
895
+ },
896
+ "testExpiryDate": {
897
+ "type": "string"
898
+ },
899
+ "modType": {
900
+ "anyOf": [
901
+ {
902
+ "title": "Mod Type Schema",
903
+ "type": "object",
904
+ "properties": {
905
+ "code": {
906
+ "type": "string"
907
+ },
908
+ "description": {
909
+ "type": "string"
910
+ }
911
+ },
912
+ "required": [
913
+ "code",
914
+ "description"
915
+ ],
916
+ "additionalProperties": false
917
+ },
918
+ {
919
+ "type": "string"
920
+ },
921
+ {
922
+ "type": "null"
923
+ }
924
+ ]
925
+ },
926
+ "emissionStandard": {
927
+ "type": "string"
928
+ },
929
+ "fuelType": {
930
+ "type": "string"
931
+ },
932
+ "modificationTypeUsed": {
933
+ "type": "string"
934
+ },
935
+ "smokeTestKLimitApplied": {
936
+ "type": "string"
937
+ },
938
+ "particulateTrapFitted": {
939
+ "type": "string"
940
+ },
941
+ "particulateTrapSerialNumber": {
942
+ "type": "string"
943
+ },
944
+ "defects": {
945
+ "type": [
946
+ "array"
947
+ ],
948
+ "items": {
949
+ "title": "Defect Details Schema",
950
+ "type": "object",
951
+ "properties": {
952
+ "imNumber": {
953
+ "type": "integer"
954
+ },
955
+ "imDescription": {
956
+ "type": "string"
957
+ },
958
+ "additionalInformation": {
959
+ "properties": {
960
+ "location": {
961
+ "title": "Defect Location Schema",
962
+ "type": "object",
963
+ "properties": {
964
+ "vertical": {
965
+ "type": [
966
+ "string",
967
+ "null"
968
+ ]
969
+ },
970
+ "horizontal": {
971
+ "type": [
972
+ "string",
973
+ "null"
974
+ ]
975
+ },
976
+ "lateral": {
977
+ "type": [
978
+ "string",
979
+ "null"
980
+ ]
981
+ },
982
+ "longitudinal": {
983
+ "type": [
984
+ "string",
985
+ "null"
986
+ ]
987
+ },
988
+ "rowNumber": {
989
+ "type": [
990
+ "integer",
991
+ "null"
992
+ ]
993
+ },
994
+ "seatNumber": {
995
+ "type": [
996
+ "integer",
997
+ "null"
998
+ ]
999
+ },
1000
+ "axleNumber": {
1001
+ "type": [
1002
+ "integer",
1003
+ "null"
1004
+ ]
1005
+ }
1006
+ },
1007
+ "additionalProperties": false
1008
+ },
1009
+ "notes": {
1010
+ "type": "string"
1011
+ }
1012
+ },
1013
+ "additionalProperties": false,
1014
+ "required": [
1015
+ "location",
1016
+ "notes"
1017
+ ]
1018
+ },
1019
+ "itemNumber": {
1020
+ "type": "integer"
1021
+ },
1022
+ "itemDescription": {
1023
+ "type": "string"
1024
+ },
1025
+ "deficiencyRef": {
1026
+ "type": "string"
1027
+ },
1028
+ "deficiencyId": {
1029
+ "type": [
1030
+ "string",
1031
+ "null"
1032
+ ]
1033
+ },
1034
+ "deficiencySubId": {
1035
+ "type": [
1036
+ "string",
1037
+ "null"
1038
+ ]
1039
+ },
1040
+ "deficiencyCategory": {
1041
+ "type": "string"
1042
+ },
1043
+ "deficiencyText": {
1044
+ "type": [
1045
+ "string",
1046
+ "null"
1047
+ ]
1048
+ },
1049
+ "stdForProhibition": {
1050
+ "type": [
1051
+ "boolean",
1052
+ "null"
1053
+ ]
1054
+ },
1055
+ "prs": {
1056
+ "type": [
1057
+ "boolean",
1058
+ "null"
1059
+ ]
1060
+ },
1061
+ "prohibitionIssued": {
1062
+ "type": [
1063
+ "boolean",
1064
+ "null"
1065
+ ]
1066
+ },
1067
+ "metadata": {
1068
+ "title": "Defect Metadata Schema",
1069
+ "type": "object",
1070
+ "properties": {
1071
+ "category": {
1072
+ "properties": {
1073
+ "additionalInfo": {
1074
+ "title": "Defect Additional Details Metadata Schema",
1075
+ "type": "object",
1076
+ "properties": {
1077
+ "location": {
1078
+ "title": "Defect Location Metadata Schema",
1079
+ "type": "object",
1080
+ "properties": {
1081
+ "vertical": {
1082
+ "anyOf": [
1083
+ {
1084
+ "type": "array",
1085
+ "items": {
1086
+ "type": "string"
1087
+ }
1088
+ },
1089
+ {
1090
+ "type": "null"
1091
+ }
1092
+ ]
1093
+ },
1094
+ "horizontal": {
1095
+ "anyOf": [
1096
+ {
1097
+ "type": "array",
1098
+ "items": {
1099
+ "type": "string"
1100
+ }
1101
+ },
1102
+ {
1103
+ "type": "null"
1104
+ }
1105
+ ]
1106
+ },
1107
+ "lateral": {
1108
+ "anyOf": [
1109
+ {
1110
+ "type": "array",
1111
+ "items": {
1112
+ "type": "string"
1113
+ }
1114
+ },
1115
+ {
1116
+ "type": "null"
1117
+ }
1118
+ ]
1119
+ },
1120
+ "longitudinal": {
1121
+ "anyOf": [
1122
+ {
1123
+ "type": "array",
1124
+ "items": {
1125
+ "type": "string"
1126
+ }
1127
+ },
1128
+ {
1129
+ "type": "null"
1130
+ }
1131
+ ]
1132
+ },
1133
+ "rowNumber": {
1134
+ "anyOf": [
1135
+ {
1136
+ "type": "array",
1137
+ "items": {
1138
+ "type": "number"
1139
+ }
1140
+ },
1141
+ {
1142
+ "type": "null"
1143
+ }
1144
+ ]
1145
+ },
1146
+ "seatNumber": {
1147
+ "anyOf": [
1148
+ {
1149
+ "type": "array",
1150
+ "items": {
1151
+ "type": "integer"
1152
+ }
1153
+ },
1154
+ {
1155
+ "type": "null"
1156
+ }
1157
+ ]
1158
+ },
1159
+ "axleNumber": {
1160
+ "anyOf": [
1161
+ {
1162
+ "type": "array",
1163
+ "items": {
1164
+ "type": "number"
1165
+ }
1166
+ },
1167
+ {
1168
+ "type": "null"
1169
+ }
1170
+ ]
1171
+ }
1172
+ },
1173
+ "additionalProperties": false
1174
+ },
1175
+ "notes": {
1176
+ "type": "boolean"
1177
+ }
1178
+ },
1179
+ "additionalProperties": false,
1180
+ "required": [
1181
+ "location",
1182
+ "notes"
1183
+ ]
1184
+ }
1185
+ },
1186
+ "additionalProperties": false
1187
+ }
1188
+ },
1189
+ "additionalProperties": false,
1190
+ "required": [
1191
+ "category"
1192
+ ]
1193
+ }
1194
+ },
1195
+ "additionalProperties": false,
1196
+ "required": [
1197
+ "imNumber",
1198
+ "imDescription",
1199
+ "additionalInformation",
1200
+ "itemNumber",
1201
+ "itemDescription",
1202
+ "deficiencyRef",
1203
+ "deficiencyId",
1204
+ "deficiencySubId",
1205
+ "deficiencyCategory",
1206
+ "deficiencyText",
1207
+ "stdForProhibition",
1208
+ "prs",
1209
+ "prohibitionIssued",
1210
+ "metadata"
1211
+ ]
1212
+ }
1213
+ },
1214
+ "customDefects": {
1215
+ "type": [
1216
+ "array"
1217
+ ],
1218
+ "items": {
1219
+ "title": "Specialist Custom Defects Schema",
1220
+ "type": "object",
1221
+ "properties": {
1222
+ "referenceNumber": {
1223
+ "type": "string"
1224
+ },
1225
+ "defectName": {
1226
+ "type": "string"
1227
+ },
1228
+ "defectNotes": {
1229
+ "type": "string"
1230
+ },
1231
+ "hasAllMandatoryFields": {
1232
+ "type": "boolean",
1233
+ "description": "FE only"
1234
+ }
1235
+ },
1236
+ "additionalProperties": false,
1237
+ "required": [
1238
+ "referenceNumber",
1239
+ "defectName",
1240
+ "defectNotes"
1241
+ ]
1242
+ }
1243
+ },
1244
+ "completionStatus": {
1245
+ "type": "string"
1246
+ },
1247
+ "testTypeCategoryName": {
1248
+ "type": "string"
1249
+ },
1250
+ "reasons": {
1251
+ "type": "array",
1252
+ "items": {
1253
+ "type": "string"
1254
+ }
1255
+ },
1256
+ "testNumber": {
1257
+ "type": "string"
1258
+ },
1259
+ "linkedIds": {
1260
+ "anyOf": [
1261
+ {
1262
+ "type": "array",
1263
+ "items": {
1264
+ "type": "string"
1265
+ }
1266
+ },
1267
+ {
1268
+ "type": "null"
1269
+ }
1270
+ ]
1271
+ }
1272
+ },
1273
+ "required": [
1274
+ "testTypeName",
1275
+ "name",
1276
+ "testTypeId",
1277
+ "certificateNumber",
1278
+ "secondaryCertificateNumber",
1279
+ "testTypeStartTimestamp",
1280
+ "testTypeEndTimestamp",
1281
+ "testResult",
1282
+ "prohibitionIssued",
1283
+ "reasonForAbandoning",
1284
+ "additionalNotesRecorded",
1285
+ "additionalCommentsForAbandon",
1286
+ "defects"
1287
+ ],
1288
+ "additionalProperties": false
1289
+ }
1290
+ }
1291
+ },
1292
+ "additionalProperties": false,
1293
+ "required": [
1294
+ "testResultId",
1295
+ "testStationName",
1296
+ "testStationPNumber",
1297
+ "testStationType",
1298
+ "testerName",
1299
+ "testerStaffId",
1300
+ "testerEmailAddress",
1301
+ "testStartTimestamp",
1302
+ "testEndTimestamp",
1303
+ "testStatus",
1304
+ "reasonForCancellation",
1305
+ "systemNumber",
1306
+ "vin",
1307
+ "vehicleClass",
1308
+ "vehicleType",
1309
+ "vehicleConfiguration",
1310
+ "preparerId",
1311
+ "preparerName",
1312
+ "euVehicleCategory",
1313
+ "countryOfRegistration",
1314
+ "noOfAxles",
1315
+ "numberOfWheelsDriven",
1316
+ "testTypes"
1317
+ ]
1318
+ }
1319
+ },
1320
+ "countryOfRegistration": {
1321
+ "type": "string"
1322
+ },
1323
+ "euVehicleCategory": {
1324
+ "type": "string"
1325
+ },
1326
+ "odometerReading": {
1327
+ "type": "string"
1328
+ },
1329
+ "odometerMetric": {
1330
+ "type": "string"
1331
+ },
1332
+ "preparerId": {
1333
+ "type": "string"
1334
+ },
1335
+ "preparerName": {
1336
+ "type": "string"
1337
+ },
1338
+ "testTypes": {
1339
+ "type": "array",
1340
+ "items": {
1341
+ "title": "Test Type Schema",
1342
+ "type": "object",
1343
+ "properties": {
1344
+ "testTypeName": {
1345
+ "type": "string"
1346
+ },
1347
+ "name": {
1348
+ "type": "string"
1349
+ },
1350
+ "testTypeId": {
1351
+ "type": "string"
1352
+ },
1353
+ "certificateNumber": {
1354
+ "type": [
1355
+ "string",
1356
+ "null"
1357
+ ]
1358
+ },
1359
+ "secondaryCertificateNumber": {
1360
+ "type": [
1361
+ "string",
1362
+ "null"
1363
+ ]
1364
+ },
1365
+ "testTypeStartTimestamp": {
1366
+ "type": [
1367
+ "string",
1368
+ "null"
1369
+ ]
1370
+ },
1371
+ "testTypeEndTimestamp": {
1372
+ "type": [
1373
+ "string",
1374
+ "null"
1375
+ ]
1376
+ },
1377
+ "testResult": {
1378
+ "type": [
1379
+ "string",
1380
+ "null"
1381
+ ]
1382
+ },
1383
+ "prohibitionIssued": {
1384
+ "type": [
1385
+ "boolean",
1386
+ "null"
1387
+ ]
1388
+ },
1389
+ "reasonForAbandoning": {
1390
+ "type": [
1391
+ "string",
1392
+ "null"
1393
+ ]
1394
+ },
1395
+ "additionalNotesRecorded": {
1396
+ "type": [
1397
+ "string",
1398
+ "null"
1399
+ ]
1400
+ },
1401
+ "additionalCommentsForAbandon": {
1402
+ "type": [
1403
+ "string",
1404
+ "null"
1405
+ ]
1406
+ },
1407
+ "numberOfSeatbeltsFitted": {
1408
+ "type": [
1409
+ "integer",
1410
+ "null"
1411
+ ]
1412
+ },
1413
+ "lastSeatbeltInstallationCheckDate": {
1414
+ "type": [
1415
+ "string",
1416
+ "null"
1417
+ ]
1418
+ },
1419
+ "seatbeltInstallationCheckDate": {
1420
+ "type": [
1421
+ "boolean",
1422
+ "null"
1423
+ ]
1424
+ },
1425
+ "testExpiryDate": {
1426
+ "type": "string"
1427
+ },
1428
+ "modType": {
1429
+ "anyOf": [
1430
+ {
1431
+ "title": "Mod Type Schema",
1432
+ "type": "object",
1433
+ "properties": {
1434
+ "code": {
1435
+ "type": "string"
1436
+ },
1437
+ "description": {
1438
+ "type": "string"
1439
+ }
1440
+ },
1441
+ "required": [
1442
+ "code",
1443
+ "description"
1444
+ ],
1445
+ "additionalProperties": false
1446
+ },
1447
+ {
1448
+ "type": "string"
1449
+ },
1450
+ {
1451
+ "type": "null"
1452
+ }
1453
+ ]
1454
+ },
1455
+ "emissionStandard": {
1456
+ "type": "string"
1457
+ },
1458
+ "fuelType": {
1459
+ "type": "string"
1460
+ },
1461
+ "modificationTypeUsed": {
1462
+ "type": "string"
1463
+ },
1464
+ "smokeTestKLimitApplied": {
1465
+ "type": "string"
1466
+ },
1467
+ "particulateTrapFitted": {
1468
+ "type": "string"
1469
+ },
1470
+ "particulateTrapSerialNumber": {
1471
+ "type": "string"
1472
+ },
1473
+ "defects": {
1474
+ "type": [
1475
+ "array"
1476
+ ],
1477
+ "items": {
1478
+ "title": "Defect Details Schema",
1479
+ "type": "object",
1480
+ "properties": {
1481
+ "imNumber": {
1482
+ "type": "integer"
1483
+ },
1484
+ "imDescription": {
1485
+ "type": "string"
1486
+ },
1487
+ "additionalInformation": {
1488
+ "properties": {
1489
+ "location": {
1490
+ "title": "Defect Location Schema",
1491
+ "type": "object",
1492
+ "properties": {
1493
+ "vertical": {
1494
+ "type": [
1495
+ "string",
1496
+ "null"
1497
+ ]
1498
+ },
1499
+ "horizontal": {
1500
+ "type": [
1501
+ "string",
1502
+ "null"
1503
+ ]
1504
+ },
1505
+ "lateral": {
1506
+ "type": [
1507
+ "string",
1508
+ "null"
1509
+ ]
1510
+ },
1511
+ "longitudinal": {
1512
+ "type": [
1513
+ "string",
1514
+ "null"
1515
+ ]
1516
+ },
1517
+ "rowNumber": {
1518
+ "type": [
1519
+ "integer",
1520
+ "null"
1521
+ ]
1522
+ },
1523
+ "seatNumber": {
1524
+ "type": [
1525
+ "integer",
1526
+ "null"
1527
+ ]
1528
+ },
1529
+ "axleNumber": {
1530
+ "type": [
1531
+ "integer",
1532
+ "null"
1533
+ ]
1534
+ }
1535
+ },
1536
+ "additionalProperties": false
1537
+ },
1538
+ "notes": {
1539
+ "type": "string"
1540
+ }
1541
+ },
1542
+ "additionalProperties": false,
1543
+ "required": [
1544
+ "location",
1545
+ "notes"
1546
+ ]
1547
+ },
1548
+ "itemNumber": {
1549
+ "type": "integer"
1550
+ },
1551
+ "itemDescription": {
1552
+ "type": "string"
1553
+ },
1554
+ "deficiencyRef": {
1555
+ "type": "string"
1556
+ },
1557
+ "deficiencyId": {
1558
+ "type": [
1559
+ "string",
1560
+ "null"
1561
+ ]
1562
+ },
1563
+ "deficiencySubId": {
1564
+ "type": [
1565
+ "string",
1566
+ "null"
1567
+ ]
1568
+ },
1569
+ "deficiencyCategory": {
1570
+ "type": "string"
1571
+ },
1572
+ "deficiencyText": {
1573
+ "type": [
1574
+ "string",
1575
+ "null"
1576
+ ]
1577
+ },
1578
+ "stdForProhibition": {
1579
+ "type": [
1580
+ "boolean",
1581
+ "null"
1582
+ ]
1583
+ },
1584
+ "prs": {
1585
+ "type": [
1586
+ "boolean",
1587
+ "null"
1588
+ ]
1589
+ },
1590
+ "prohibitionIssued": {
1591
+ "type": [
1592
+ "boolean",
1593
+ "null"
1594
+ ]
1595
+ },
1596
+ "metadata": {
1597
+ "title": "Defect Metadata Schema",
1598
+ "type": "object",
1599
+ "properties": {
1600
+ "category": {
1601
+ "properties": {
1602
+ "additionalInfo": {
1603
+ "title": "Defect Additional Details Metadata Schema",
1604
+ "type": "object",
1605
+ "properties": {
1606
+ "location": {
1607
+ "title": "Defect Location Metadata Schema",
1608
+ "type": "object",
1609
+ "properties": {
1610
+ "vertical": {
1611
+ "anyOf": [
1612
+ {
1613
+ "type": "array",
1614
+ "items": {
1615
+ "type": "string"
1616
+ }
1617
+ },
1618
+ {
1619
+ "type": "null"
1620
+ }
1621
+ ]
1622
+ },
1623
+ "horizontal": {
1624
+ "anyOf": [
1625
+ {
1626
+ "type": "array",
1627
+ "items": {
1628
+ "type": "string"
1629
+ }
1630
+ },
1631
+ {
1632
+ "type": "null"
1633
+ }
1634
+ ]
1635
+ },
1636
+ "lateral": {
1637
+ "anyOf": [
1638
+ {
1639
+ "type": "array",
1640
+ "items": {
1641
+ "type": "string"
1642
+ }
1643
+ },
1644
+ {
1645
+ "type": "null"
1646
+ }
1647
+ ]
1648
+ },
1649
+ "longitudinal": {
1650
+ "anyOf": [
1651
+ {
1652
+ "type": "array",
1653
+ "items": {
1654
+ "type": "string"
1655
+ }
1656
+ },
1657
+ {
1658
+ "type": "null"
1659
+ }
1660
+ ]
1661
+ },
1662
+ "rowNumber": {
1663
+ "anyOf": [
1664
+ {
1665
+ "type": "array",
1666
+ "items": {
1667
+ "type": "number"
1668
+ }
1669
+ },
1670
+ {
1671
+ "type": "null"
1672
+ }
1673
+ ]
1674
+ },
1675
+ "seatNumber": {
1676
+ "anyOf": [
1677
+ {
1678
+ "type": "array",
1679
+ "items": {
1680
+ "type": "integer"
1681
+ }
1682
+ },
1683
+ {
1684
+ "type": "null"
1685
+ }
1686
+ ]
1687
+ },
1688
+ "axleNumber": {
1689
+ "anyOf": [
1690
+ {
1691
+ "type": "array",
1692
+ "items": {
1693
+ "type": "number"
1694
+ }
1695
+ },
1696
+ {
1697
+ "type": "null"
1698
+ }
1699
+ ]
1700
+ }
1701
+ },
1702
+ "additionalProperties": false
1703
+ },
1704
+ "notes": {
1705
+ "type": "boolean"
1706
+ }
1707
+ },
1708
+ "additionalProperties": false,
1709
+ "required": [
1710
+ "location",
1711
+ "notes"
1712
+ ]
1713
+ }
1714
+ },
1715
+ "additionalProperties": false
1716
+ }
1717
+ },
1718
+ "additionalProperties": false,
1719
+ "required": [
1720
+ "category"
1721
+ ]
1722
+ }
1723
+ },
1724
+ "additionalProperties": false,
1725
+ "required": [
1726
+ "imNumber",
1727
+ "imDescription",
1728
+ "additionalInformation",
1729
+ "itemNumber",
1730
+ "itemDescription",
1731
+ "deficiencyRef",
1732
+ "deficiencyId",
1733
+ "deficiencySubId",
1734
+ "deficiencyCategory",
1735
+ "deficiencyText",
1736
+ "stdForProhibition",
1737
+ "prs",
1738
+ "prohibitionIssued",
1739
+ "metadata"
1740
+ ]
1741
+ }
1742
+ },
1743
+ "customDefects": {
1744
+ "type": [
1745
+ "array"
1746
+ ],
1747
+ "items": {
1748
+ "title": "Specialist Custom Defects Schema",
1749
+ "type": "object",
1750
+ "properties": {
1751
+ "referenceNumber": {
1752
+ "type": "string"
1753
+ },
1754
+ "defectName": {
1755
+ "type": "string"
1756
+ },
1757
+ "defectNotes": {
1758
+ "type": "string"
1759
+ },
1760
+ "hasAllMandatoryFields": {
1761
+ "type": "boolean",
1762
+ "description": "FE only"
1763
+ }
1764
+ },
1765
+ "additionalProperties": false,
1766
+ "required": [
1767
+ "referenceNumber",
1768
+ "defectName",
1769
+ "defectNotes"
1770
+ ]
1771
+ }
1772
+ },
1773
+ "completionStatus": {
1774
+ "type": "string"
1775
+ },
1776
+ "testTypeCategoryName": {
1777
+ "type": "string"
1778
+ },
1779
+ "reasons": {
1780
+ "type": "array",
1781
+ "items": {
1782
+ "type": "string"
1783
+ }
1784
+ },
1785
+ "testNumber": {
1786
+ "type": "string"
1787
+ },
1788
+ "linkedIds": {
1789
+ "anyOf": [
1790
+ {
1791
+ "type": "array",
1792
+ "items": {
1793
+ "type": "string"
1794
+ }
1795
+ },
1796
+ {
1797
+ "type": "null"
1798
+ }
1799
+ ]
1800
+ }
1801
+ },
1802
+ "required": [
1803
+ "testTypeName",
1804
+ "name",
1805
+ "testTypeId",
1806
+ "certificateNumber",
1807
+ "secondaryCertificateNumber",
1808
+ "testTypeStartTimestamp",
1809
+ "testTypeEndTimestamp",
1810
+ "testResult",
1811
+ "prohibitionIssued",
1812
+ "reasonForAbandoning",
1813
+ "additionalNotesRecorded",
1814
+ "additionalCommentsForAbandon",
1815
+ "defects"
1816
+ ],
1817
+ "additionalProperties": false
1818
+ }
1819
+ },
1820
+ "trailerId": {
1821
+ "description": "trailer only",
1822
+ "type": "string"
1823
+ }
1824
+ },
1825
+ "additionalProperties": false,
1826
+ "required": [
1827
+ "systemNumber",
1828
+ "vrm",
1829
+ "vin",
1830
+ "techRecord"
1831
+ ]
1832
+ },
1833
+ "additionalProperties": false
1834
+ }
1835
+ },
1836
+ "required": [
1837
+ "startTime",
1838
+ "endTime",
1839
+ "status",
1840
+ "reasonForCancellation",
1841
+ "vehicles"
1842
+ ]
1843
+ }