@dvsa/cvs-type-definitions 6.3.0 → 7.0.0

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 (67) hide show
  1. package/json-schemas/v1/activity/index.json +53 -8
  2. package/json-schemas/v1/enums/activityType.enum.json +14 -0
  3. package/json-schemas/v1/enums/emissionStandard.enum.json +26 -0
  4. package/json-schemas/v1/enums/fuelType.enum.json +22 -0
  5. package/json-schemas/v1/enums/odometerReadingUnits.enum.json +12 -0
  6. package/json-schemas/v1/enums/sources.enum.json +12 -0
  7. package/json-schemas/v1/enums/testResult.enum.json +16 -0
  8. package/json-schemas/v1/enums/testStationType.enum.json +16 -0
  9. package/json-schemas/v1/enums/testStatus.enum.json +12 -0
  10. package/json-schemas/v1/enums/typeOfTest.enum.json +14 -0
  11. package/json-schemas/v1/enums/waitReason.enum.json +18 -0
  12. package/json-schemas/v1/test/index.json +631 -87
  13. package/json-schemas/v1/test-result/index.json +448 -53
  14. package/json-schemas/v1/test-type/index.json +183 -34
  15. package/json-schemas/v1/vehicle/index.json +631 -87
  16. package/json-schemas/v1/visit/index.json +631 -87
  17. package/json-schemas/v3/tech-record/get/hgv/complete/index.json +1 -2
  18. package/json-schemas/v3/tech-record/get/hgv/skeleton/index.json +1 -2
  19. package/json-schemas/v3/tech-record/get/hgv/testable/index.json +1 -2
  20. package/json-schemas/v3/tech-record/get/trl/complete/index.json +1 -2
  21. package/json-schemas/v3/tech-record/get/trl/skeleton/index.json +1 -2
  22. package/json-schemas/v3/tech-record/get/trl/testable/index.json +1 -2
  23. package/json-schemas/v3/tech-record/put/hgv/complete/index.json +1 -2
  24. package/json-schemas/v3/tech-record/put/hgv/skeleton/index.json +1 -2
  25. package/json-schemas/v3/tech-record/put/hgv/testable/index.json +1 -2
  26. package/json-schemas/v3/tech-record/put/trl/complete/index.json +1 -2
  27. package/json-schemas/v3/tech-record/put/trl/skeleton/index.json +1 -2
  28. package/json-schemas/v3/tech-record/put/trl/testable/index.json +1 -2
  29. package/package.json +1 -1
  30. package/schemas.d.ts +1 -1
  31. package/schemas.js +10 -0
  32. package/types/v1/activity/index.d.ts +26 -6
  33. package/types/v1/enums/activityType.enum.d.ts +10 -0
  34. package/types/v1/enums/activityType.enum.js +15 -0
  35. package/types/v1/enums/activityType.enum.ts +12 -0
  36. package/types/v1/enums/emissionStandard.enum.d.ts +16 -0
  37. package/types/v1/enums/emissionStandard.enum.js +21 -0
  38. package/types/v1/enums/emissionStandard.enum.ts +18 -0
  39. package/types/v1/enums/fuelType.enum.d.ts +14 -0
  40. package/types/v1/enums/fuelType.enum.js +19 -0
  41. package/types/v1/enums/fuelType.enum.ts +16 -0
  42. package/types/v1/enums/odometerReadingUnits.enum.d.ts +9 -0
  43. package/types/v1/enums/odometerReadingUnits.enum.js +14 -0
  44. package/types/v1/enums/odometerReadingUnits.enum.ts +11 -0
  45. package/types/v1/enums/sources.enum.d.ts +9 -0
  46. package/types/v1/enums/sources.enum.js +14 -0
  47. package/types/v1/enums/sources.enum.ts +11 -0
  48. package/types/v1/enums/testResult.enum.d.ts +11 -0
  49. package/types/v1/enums/testResult.enum.js +16 -0
  50. package/types/v1/enums/testResult.enum.ts +13 -0
  51. package/types/v1/enums/testStationType.enum.d.ts +11 -0
  52. package/types/v1/enums/testStationType.enum.js +16 -0
  53. package/types/v1/enums/testStationType.enum.ts +13 -0
  54. package/types/v1/enums/testStatus.enum.d.ts +9 -0
  55. package/types/v1/enums/testStatus.enum.js +14 -0
  56. package/types/v1/enums/testStatus.enum.ts +11 -0
  57. package/types/v1/enums/typeOfTest.enum.d.ts +10 -0
  58. package/types/v1/enums/typeOfTest.enum.js +15 -0
  59. package/types/v1/enums/typeOfTest.enum.ts +12 -0
  60. package/types/v1/enums/waitReason.enum.d.ts +12 -0
  61. package/types/v1/enums/waitReason.enum.js +17 -0
  62. package/types/v1/enums/waitReason.enum.ts +14 -0
  63. package/types/v1/test/index.d.ts +143 -28
  64. package/types/v1/test-result/index.d.ts +143 -28
  65. package/types/v1/test-type/index.d.ts +65 -14
  66. package/types/v1/vehicle/index.d.ts +143 -28
  67. package/types/v1/visit/index.d.ts +143 -28
@@ -6,22 +6,56 @@
6
6
  "type": "string"
7
7
  },
8
8
  "testStationName": {
9
- "type": "string"
9
+ "type": [
10
+ "string",
11
+ "null"
12
+ ],
13
+ "maxLength": 999
10
14
  },
11
15
  "testStationPNumber": {
12
- "type": "string"
16
+ "type": [
17
+ "string",
18
+ "null"
19
+ ],
20
+ "maxLength": 20
13
21
  },
14
22
  "testStationType": {
15
- "type": "string"
23
+ "anyOf": [
24
+ {
25
+ "title": "Test Station Types",
26
+ "type": "string",
27
+ "tsEnumNames": [
28
+ "ATF",
29
+ "GVTS",
30
+ "HQ",
31
+ "POTF"
32
+ ],
33
+ "enum": [
34
+ "atf",
35
+ "gvts",
36
+ "hq",
37
+ "potf"
38
+ ]
39
+ }
40
+ ]
16
41
  },
17
42
  "testerName": {
18
- "type": "string"
43
+ "type": [
44
+ "string",
45
+ "null"
46
+ ],
47
+ "maxLength": 60
19
48
  },
20
49
  "testerStaffId": {
21
- "type": "string"
50
+ "type": "string",
51
+ "maxLength": 36
22
52
  },
23
53
  "testerEmailAddress": {
24
- "type": "string"
54
+ "type": [
55
+ "string",
56
+ "null"
57
+ ],
58
+ "maxLength": 60
25
59
  },
26
60
  "testStartTimestamp": {
27
61
  "type": "string"
@@ -30,7 +64,20 @@
30
64
  "type": "string"
31
65
  },
32
66
  "testStatus": {
33
- "type": "string"
67
+ "anyOf": [
68
+ {
69
+ "title": "Test Status",
70
+ "type": "string",
71
+ "tsEnumNames": [
72
+ "SUBMITTED",
73
+ "CANCELLED"
74
+ ],
75
+ "enum": [
76
+ "submitted",
77
+ "cancelled"
78
+ ]
79
+ }
80
+ ]
34
81
  },
35
82
  "reasonForCancellation": {
36
83
  "type": [
@@ -42,13 +89,15 @@
42
89
  "type": "string"
43
90
  },
44
91
  "vrm": {
45
- "type": "string"
92
+ "type": "string",
93
+ "maxLength": 9
46
94
  },
47
95
  "trailerId": {
48
96
  "type": "string"
49
97
  },
50
98
  "vin": {
51
- "type": "string"
99
+ "type": "string",
100
+ "maxLength": 21
52
101
  },
53
102
  "vehicleClass": {
54
103
  "title": "Vehicle Class Schema",
@@ -74,7 +123,20 @@
74
123
  }
75
124
  },
76
125
  "vehicleType": {
77
- "type": "string"
126
+ "anyOf": [
127
+ {
128
+ "title": "Vehicle Type",
129
+ "type": "string",
130
+ "enum": [
131
+ "psv",
132
+ "trl",
133
+ "hgv",
134
+ "car",
135
+ "lgv",
136
+ "motorcycle"
137
+ ]
138
+ }
139
+ ]
78
140
  },
79
141
  "vehicleConfiguration": {
80
142
  "type": "string"
@@ -86,19 +148,83 @@
86
148
  ]
87
149
  },
88
150
  "odometerReadingUnits": {
151
+ "anyOf": [
152
+ {
153
+ "title": "Odometer Reading Units",
154
+ "type": "string",
155
+ "tsEnumNames": [
156
+ "KILOMETRES",
157
+ "MILES"
158
+ ],
159
+ "enum": [
160
+ "kilometres",
161
+ "miles"
162
+ ]
163
+ },
164
+ {
165
+ "type": "null"
166
+ }
167
+ ]
168
+ },
169
+ "preparerId": {
89
170
  "type": [
90
171
  "string",
91
172
  "null"
92
173
  ]
93
174
  },
94
- "preparerId": {
95
- "type": "string"
96
- },
97
175
  "preparerName": {
98
- "type": "string"
176
+ "type": [
177
+ "string",
178
+ "null"
179
+ ]
99
180
  },
100
181
  "euVehicleCategory": {
101
- "type": "string"
182
+ "anyOf": [
183
+ {
184
+ "title": "EU vehicle category",
185
+ "type": "string",
186
+ "tsEnumNames": [
187
+ "M1",
188
+ "M2",
189
+ "M3",
190
+ "N1",
191
+ "N2",
192
+ "N3",
193
+ "O1",
194
+ "O2",
195
+ "O3",
196
+ "O4",
197
+ "L1E_A",
198
+ "l1E",
199
+ "L2e",
200
+ "L3E",
201
+ "L4E",
202
+ "L5E",
203
+ "L6E",
204
+ "L7E"
205
+ ],
206
+ "enum": [
207
+ "m1",
208
+ "m2",
209
+ "m3",
210
+ "n1",
211
+ "n2",
212
+ "n3",
213
+ "o1",
214
+ "o2",
215
+ "o3",
216
+ "o4",
217
+ "l1e-a",
218
+ "l1e",
219
+ "l2e",
220
+ "l3e",
221
+ "l4e",
222
+ "l5e",
223
+ "l6e",
224
+ "l7e"
225
+ ]
226
+ }
227
+ ]
102
228
  },
103
229
  "countryOfRegistration": {
104
230
  "type": [
@@ -107,10 +233,14 @@
107
233
  ]
108
234
  },
109
235
  "noOfAxles": {
110
- "type": "integer"
236
+ "type": "integer",
237
+ "maximum": 99
111
238
  },
112
239
  "numberOfWheelsDriven": {
113
- "type": "integer"
240
+ "type": [
241
+ "integer",
242
+ "null"
243
+ ]
114
244
  },
115
245
  "vehicleSize": {
116
246
  "type": "string"
@@ -119,10 +249,16 @@
119
249
  "type": "integer"
120
250
  },
121
251
  "regnDate": {
122
- "type": "string"
252
+ "type": [
253
+ "string",
254
+ "null"
255
+ ]
123
256
  },
124
257
  "firstUseDate": {
125
- "type": "string"
258
+ "type": [
259
+ "string",
260
+ "null"
261
+ ]
126
262
  },
127
263
  "testTypes": {
128
264
  "type": "array",
@@ -131,7 +267,10 @@
131
267
  "type": "object",
132
268
  "properties": {
133
269
  "testTypeName": {
134
- "type": "string"
270
+ "type": [
271
+ "string",
272
+ "null"
273
+ ]
135
274
  },
136
275
  "name": {
137
276
  "type": "string"
@@ -164,9 +303,26 @@
164
303
  ]
165
304
  },
166
305
  "testResult": {
167
- "type": [
168
- "string",
169
- "null"
306
+ "anyOf": [
307
+ {
308
+ "type:": "null"
309
+ },
310
+ {
311
+ "title": "Test Results",
312
+ "type": "string",
313
+ "tsEnumNames": [
314
+ "PASS",
315
+ "PRS",
316
+ "FAIL",
317
+ "ABANDONED"
318
+ ],
319
+ "enum": [
320
+ "pass",
321
+ "prs",
322
+ "fail",
323
+ "abandoned"
324
+ ]
325
+ }
170
326
  ]
171
327
  },
172
328
  "prohibitionIssued": {
@@ -185,13 +341,15 @@
185
341
  "type": [
186
342
  "string",
187
343
  "null"
188
- ]
344
+ ],
345
+ "maxLength": 500
189
346
  },
190
347
  "additionalCommentsForAbandon": {
191
348
  "type": [
192
349
  "string",
193
350
  "null"
194
- ]
351
+ ],
352
+ "maxLength": 500
195
353
  },
196
354
  "numberOfSeatbeltsFitted": {
197
355
  "type": [
@@ -214,6 +372,12 @@
214
372
  "testExpiryDate": {
215
373
  "type": "string"
216
374
  },
375
+ "testAnniversaryDate": {
376
+ "type": [
377
+ "string",
378
+ "null"
379
+ ]
380
+ },
217
381
  "modType": {
218
382
  "anyOf": [
219
383
  {
@@ -242,22 +406,94 @@
242
406
  ]
243
407
  },
244
408
  "emissionStandard": {
245
- "type": "string"
409
+ "anyOf": [
410
+ {
411
+ "type:": "null"
412
+ },
413
+ {
414
+ "title": "Emission Standards",
415
+ "type": "string",
416
+ "tsEnumNames": [
417
+ "EURO3_PM",
418
+ "EURO4_PM",
419
+ "EURO3",
420
+ "EURO4",
421
+ "EURO5",
422
+ "EURO6",
423
+ "EUROV",
424
+ "EUROVI",
425
+ "FULL_ELECTRIC"
426
+ ],
427
+ "enum": [
428
+ "0.10 g/kWh Euro 3 PM",
429
+ "0.03 g/kWh Euro IV PM'",
430
+ "Euro 3",
431
+ "Euro 4",
432
+ "Euro 5",
433
+ "Euro 6",
434
+ "Euro V",
435
+ "Euro VI",
436
+ "Full Electric"
437
+ ]
438
+ }
439
+ ]
246
440
  },
247
441
  "fuelType": {
248
- "type": "string"
442
+ "anyOf": [
443
+ {
444
+ "type:": "null"
445
+ },
446
+ {
447
+ "title": "Fuel Type",
448
+ "type": "string",
449
+ "tsEnumNames": [
450
+ "DIESEL",
451
+ "GAS_CNG",
452
+ "GAS_LNG",
453
+ "GAS_LPG",
454
+ "PETROL",
455
+ "FUEL_CELL",
456
+ "FULL_ELECTRIC"
457
+ ],
458
+ "enum": [
459
+ "diesel",
460
+ "gas-cng",
461
+ "gas-lng",
462
+ "gas-lpg",
463
+ "petrol",
464
+ "fuel cell",
465
+ "full electric"
466
+ ]
467
+ }
468
+ ]
249
469
  },
250
470
  "modificationTypeUsed": {
251
- "type": "string"
471
+ "type": [
472
+ "string",
473
+ "null"
474
+ ],
475
+ "maxLength": 100
252
476
  },
253
477
  "smokeTestKLimitApplied": {
254
- "type": "string"
478
+ "type": [
479
+ "string",
480
+ "null"
481
+ ],
482
+ "maxLength": 100
255
483
  },
256
484
  "particulateTrapFitted": {
257
- "type": "string"
485
+ "type": [
486
+ "string",
487
+ "null"
488
+ ],
489
+ "maxLength": 100
258
490
  },
259
491
  "particulateTrapSerialNumber": {
260
- "type": "string"
492
+ "type": [
493
+ "string",
494
+ "null"
495
+ ],
496
+ "maxLength": 100
261
497
  },
262
498
  "defects": {
263
499
  "type": [
@@ -531,7 +767,8 @@
531
767
  },
532
768
  "customDefects": {
533
769
  "type": [
534
- "array"
770
+ "array",
771
+ "null"
535
772
  ],
536
773
  "items": {
537
774
  "title": "Specialist Custom Defects Schema",
@@ -559,32 +796,80 @@
559
796
  ]
560
797
  }
561
798
  },
562
- "completionStatus": {
563
- "type": "string"
564
- },
565
- "testTypeCategoryName": {
566
- "type": "string"
567
- },
568
- "reasons": {
569
- "type": "array",
799
+ "requiredStandards": {
800
+ "type": [
801
+ "array"
802
+ ],
570
803
  "items": {
571
- "type": "string"
804
+ "title": "Specialist Custom Defects Schema Put",
805
+ "type": "object",
806
+ "properties": {
807
+ "sectionNumber": {
808
+ "type": "string"
809
+ },
810
+ "sectionDescription": {
811
+ "type": "string"
812
+ },
813
+ "additionalNotes": {
814
+ "type": [
815
+ "string",
816
+ "null"
817
+ ]
818
+ },
819
+ "rsNumber": {
820
+ "type": "integer"
821
+ },
822
+ "requiredStandard": {
823
+ "type": "string"
824
+ },
825
+ "refCalculation": {
826
+ "type": "string"
827
+ },
828
+ "additionalInfo": {
829
+ "type": "boolean"
830
+ },
831
+ "inspectionTypes": {
832
+ "type": "array",
833
+ "items": {
834
+ "anyOf": [
835
+ {
836
+ "title": "Inspection Type",
837
+ "type": "string",
838
+ "enum": [
839
+ "basic",
840
+ "normal"
841
+ ]
842
+ }
843
+ ]
844
+ }
845
+ },
846
+ "prs": {
847
+ "type": "boolean"
848
+ }
849
+ },
850
+ "additionalProperties": false,
851
+ "required": [
852
+ "sectionNumber",
853
+ "sectionDescription",
854
+ "rsNumber",
855
+ "requiredStandard",
856
+ "refCalculation",
857
+ "additionalInfo",
858
+ "referenceNumber",
859
+ "prs"
860
+ ]
572
861
  }
573
862
  },
574
863
  "testNumber": {
575
- "type": "string"
864
+ "type": [
865
+ "string",
866
+ "null"
867
+ ]
576
868
  },
577
- "linkedIds": {
578
- "anyOf": [
579
- {
580
- "type": "array",
581
- "items": {
582
- "type": "string"
583
- }
584
- },
585
- {
586
- "type": "null"
587
- }
869
+ "reapplicationDate": {
870
+ "type": [
871
+ "string",
872
+ "null"
588
873
  ]
589
874
  }
590
875
  },
@@ -605,6 +890,116 @@
605
890
  ],
606
891
  "additionalProperties": false
607
892
  }
893
+ },
894
+ "reasonForCreation": {
895
+ "type": "string",
896
+ "maxLength": 100
897
+ },
898
+ "createdAt": {
899
+ "type": [
900
+ "string",
901
+ "null"
902
+ ]
903
+ },
904
+ "createdByEmailAddress": {
905
+ "type": "string"
906
+ },
907
+ "createdByName": {
908
+ "type": "string"
909
+ },
910
+ "createdById": {
911
+ "type": "string"
912
+ },
913
+ "lastUpdatedAt": {
914
+ "type": [
915
+ "string",
916
+ "null"
917
+ ]
918
+ },
919
+ "lastUpdatedByEmailAddress": {
920
+ "type": "string"
921
+ },
922
+ "lastUpdatedByName": {
923
+ "type": "string"
924
+ },
925
+ "lastUpdatedById": {
926
+ "type": "string"
927
+ },
928
+ "shouldEmailCertificate": {
929
+ "type": "string"
930
+ },
931
+ "contingencyTestNumber": {
932
+ "type": [
933
+ "string",
934
+ "null"
935
+ ],
936
+ "maxLength": 8,
937
+ "minLength": 6
938
+ },
939
+ "typeOfTest": {
940
+ "anyOf": [
941
+ {
942
+ "title": "Type of test",
943
+ "type": "string",
944
+ "tsEnumNames": [
945
+ "CONTINGENCY",
946
+ "DESK_BASED",
947
+ "COMPLETION"
948
+ ],
949
+ "enum": [
950
+ "contingency",
951
+ "desk-based",
952
+ "completion"
953
+ ]
954
+ }
955
+ ]
956
+ },
957
+ "source": {
958
+ "anyOf": [
959
+ {
960
+ "title": "Test Sources",
961
+ "type": "string",
962
+ "tsEnumNames": [
963
+ "VTM",
964
+ "VTA"
965
+ ],
966
+ "enum": [
967
+ "vtm",
968
+ "vta"
969
+ ]
970
+ }
971
+ ]
972
+ },
973
+ "make": {
974
+ "type": [
975
+ "string",
976
+ "null"
977
+ ]
978
+ },
979
+ "model": {
980
+ "type": [
981
+ "string",
982
+ "null"
983
+ ]
984
+ },
985
+ "bodyType": {
986
+ "title": "Body Type Schema",
987
+ "type": "object",
988
+ "properties": {
989
+ "code": {
990
+ "type": [
991
+ "string",
992
+ "null"
993
+ ]
994
+ },
995
+ "description": {
996
+ "type": [
997
+ "string",
998
+ "null"
999
+ ]
1000
+ }
1001
+ },
1002
+ "additionalProperties": false
608
1003
  }
609
1004
  },
610
1005
  "additionalProperties": false,