@regulaforensics/document-reader 8.4.401-beta → 8.4.507-rc

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 (88) hide show
  1. package/README.md +1 -1
  2. package/RNDocumentReader.podspec +2 -2
  3. package/android/build.gradle +2 -2
  4. package/android/cordova.gradle +2 -2
  5. package/android/src/main/java/com/regula/plugin/documentreader/Config.kt +11 -31
  6. package/android/src/main/java/com/regula/plugin/documentreader/JSONConstructor.kt +338 -59
  7. package/android/src/main/java/com/regula/plugin/documentreader/Main.kt +69 -35
  8. package/android/src/main/java/com/regula/plugin/documentreader/Utils.kt +62 -0
  9. package/examples/capacitor/ios/App/App/Info.plist +2 -0
  10. package/examples/capacitor/package-lock.json +9 -9
  11. package/examples/capacitor/package.json +3 -3
  12. package/examples/ionic/config.xml +2 -0
  13. package/examples/ionic/package-lock.json +5262 -2655
  14. package/examples/ionic/package.json +12 -12
  15. package/examples/react_native/app.config.ts +3 -1
  16. package/examples/react_native/package-lock.json +37 -37
  17. package/examples/react_native/package.json +3 -3
  18. package/ios/RGLWConfig.m +11 -32
  19. package/ios/RGLWJSONConstructor.h +19 -1
  20. package/ios/RGLWJSONConstructor.m +349 -18
  21. package/ios/RGLWMain.m +49 -46
  22. package/package.json +1 -1
  23. package/plugin.xml +2 -2
  24. package/test/json.tsx +201 -124
  25. package/test/package-lock.json +1 -1
  26. package/test/test.tsx +12 -3
  27. package/www/capacitor/engagement/DataRetrieval.js +55 -0
  28. package/www/capacitor/engagement/DeviceEngagement.js +30 -0
  29. package/www/capacitor/engagement/DeviceRetrievalMethod.js +41 -0
  30. package/www/capacitor/engagement/DocumentRequestMDL.js +212 -0
  31. package/www/capacitor/engagement/NameSpaceMDL.js +33 -0
  32. package/www/capacitor/index.js +58 -7
  33. package/www/capacitor/info/DocReaderException.js +2 -0
  34. package/www/capacitor/params/Functionality.js +16 -0
  35. package/www/capacitor/params/customization/Customization.js +8 -0
  36. package/www/capacitor/params/process_params/AuthenticityParams.js +1 -44
  37. package/www/capacitor/params/process_params/LivenessParams.js +0 -36
  38. package/www/capacitor/params/process_params/ProcessParams.js +26 -30
  39. package/www/capacitor/results/Results.js +8 -1
  40. package/www/capacitor/results/status/AgeStatus.js +35 -0
  41. package/www/capacitor/results/status/ResultsStatus.js +13 -0
  42. package/www/capacitor/results/visible_digital_seals/DocFeature.js +23 -0
  43. package/www/capacitor/results/visible_digital_seals/VDSData.js +75 -0
  44. package/www/capacitor/results/visual_results/FieldType.js +3 -0
  45. package/www/capacitor/rfid/PKDCertificate.js +3 -0
  46. package/www/cordova.js +1276 -683
  47. package/www/react-native/engagement/DataRetrieval.js +55 -0
  48. package/www/react-native/engagement/DeviceEngagement.js +30 -0
  49. package/www/react-native/engagement/DeviceRetrievalMethod.js +41 -0
  50. package/www/react-native/engagement/DocumentRequestMDL.js +212 -0
  51. package/www/react-native/engagement/NameSpaceMDL.js +33 -0
  52. package/www/react-native/index.js +58 -7
  53. package/www/react-native/info/DocReaderException.js +2 -0
  54. package/www/react-native/params/Functionality.js +16 -0
  55. package/www/react-native/params/customization/Customization.js +8 -0
  56. package/www/react-native/params/process_params/AuthenticityParams.js +1 -44
  57. package/www/react-native/params/process_params/LivenessParams.js +0 -36
  58. package/www/react-native/params/process_params/ProcessParams.js +26 -30
  59. package/www/react-native/results/Results.js +8 -1
  60. package/www/react-native/results/status/AgeStatus.js +35 -0
  61. package/www/react-native/results/status/ResultsStatus.js +13 -0
  62. package/www/react-native/results/visible_digital_seals/DocFeature.js +23 -0
  63. package/www/react-native/results/visible_digital_seals/VDSData.js +75 -0
  64. package/www/react-native/results/visual_results/FieldType.js +3 -0
  65. package/www/react-native/rfid/PKDCertificate.js +3 -0
  66. package/www/types/engagement/DataRetrieval.d.ts +28 -0
  67. package/www/types/engagement/DeviceEngagement.d.ts +16 -0
  68. package/www/types/engagement/DeviceRetrievalMethod.d.ts +18 -0
  69. package/www/types/engagement/DocumentRequestMDL.d.ts +61 -0
  70. package/www/types/engagement/NameSpaceMDL.d.ts +16 -0
  71. package/www/types/index.d.ts +40 -8
  72. package/www/types/info/DocReaderException.d.ts +2 -0
  73. package/www/types/params/Functionality.d.ts +7 -0
  74. package/www/types/params/customization/Customization.d.ts +5 -0
  75. package/www/types/params/process_params/AuthenticityParams.d.ts +0 -25
  76. package/www/types/params/process_params/LivenessParams.d.ts +0 -18
  77. package/www/types/params/process_params/ProcessParams.d.ts +18 -11
  78. package/www/types/results/Results.d.ts +9 -1
  79. package/www/types/results/status/AgeStatus.d.ts +14 -0
  80. package/www/types/results/status/ResultsStatus.d.ts +9 -0
  81. package/www/types/results/visible_digital_seals/DocFeature.d.ts +9 -0
  82. package/www/types/results/visible_digital_seals/VDSData.d.ts +32 -0
  83. package/www/types/results/visible_digital_seals/VDSNCData.d.ts +1 -1
  84. package/www/types/results/visual_results/FieldType.d.ts +6 -0
  85. package/www/types/rfid/PKDCertificate.d.ts +7 -1
  86. package/www/capacitor/params/process_params/FilterObject.js +0 -60
  87. package/www/react-native/params/process_params/FilterObject.js +0 -60
  88. package/www/types/params/process_params/FilterObject.d.ts +0 -32
@@ -1,5 +1,4 @@
1
1
  import { DocumentReader } from '../../index';
2
- import { FilterObject } from './FilterObject';
3
2
 
4
3
  export class LivenessParams {
5
4
  get checkOVI() { return this._checkOVI; }
@@ -44,28 +43,6 @@ export class LivenessParams {
44
43
  this._set({ "checkGeometry": val });
45
44
  }
46
45
 
47
- _checkFilters = {};
48
-
49
- setCheckFilter(checkType, filter) {
50
- this._checkFilters[checkType] = filter;
51
- this._set({
52
- "setCheckFilter": {
53
- "checkType": checkType,
54
- "filterObject": filter.toJson(),
55
- },
56
- });
57
- }
58
-
59
- removeCheckFilter(checkType) {
60
- delete this._checkFilters[checkType];
61
- this._set({ "removeCheckFilter": checkType });
62
- }
63
-
64
- clearCheckFilter() {
65
- this._checkFilters = {};
66
- this._set({ "clearCheckFilter": null });
67
- }
68
-
69
46
  static fromJson(jsonObject) {
70
47
  if (jsonObject == null) return new LivenessParams();
71
48
 
@@ -77,8 +54,6 @@ export class LivenessParams {
77
54
  result._checkBlackAndWhiteCopy = jsonObject["checkBlackAndWhiteCopy"];
78
55
  result._checkDynaprint = jsonObject["checkDynaprint"];
79
56
  result._checkGeometry = jsonObject["checkGeometry"];
80
- result._checkFilters = Object.fromEntries(Object.entries(jsonObject["checkFilters"] ?? {})
81
- .map(([k, v]) => [k, FilterObject.fromJson(v)]));
82
57
 
83
58
  return result;
84
59
  }
@@ -99,17 +74,6 @@ export class LivenessParams {
99
74
  "checkBlackAndWhiteCopy": this.checkBlackAndWhiteCopy,
100
75
  "checkDynaprint": this.checkDynaprint,
101
76
  "checkGeometry": this.checkGeometry,
102
- "checkFilters": Object.fromEntries(Object.entries(this._checkFilters).map(([k, v]) => [k, v.toJson()])),
103
77
  }
104
78
  }
105
79
  }
106
-
107
- export const LivenessCheckType = {
108
- OVI: "checkOVI",
109
- MLI: "checkMLI",
110
- HOLO: "checkHolo",
111
- ED: "checkED",
112
- BLACK_AND_WHITE_COPY: "checkBlackAndWhiteCopy",
113
- DYNAPRINT: "checkDynaprint",
114
- GEOMETRY: "checkGeometry",
115
- };
@@ -5,7 +5,6 @@ import { RFIDParams } from './RFIDParams';
5
5
  import { FaceApiParams } from './FaceApiParams';
6
6
  import { BackendProcessingConfig } from './BackendProcessingConfig';
7
7
  import { AuthenticityParams } from './AuthenticityParams';
8
- import { FilterObject } from './FilterObject';
9
8
 
10
9
  export class ProcessParams {
11
10
  get multipageProcessing() { return this._multipageProcessing; }
@@ -242,6 +241,18 @@ export class ProcessParams {
242
241
  this._set({ "strictSecurityChecks": val });
243
242
  }
244
243
 
244
+ get returnTransliteratedFields() { return this._returnTransliteratedFields; }
245
+ set returnTransliteratedFields(val) {
246
+ this._returnTransliteratedFields = val;
247
+ this._set({ "returnTransliteratedFields": val });
248
+ }
249
+
250
+ get checkCaptureProcessIntegrity() { return this._checkCaptureProcessIntegrity; }
251
+ set checkCaptureProcessIntegrity(val) {
252
+ this._checkCaptureProcessIntegrity = val;
253
+ this._set({ "checkCaptureProcessIntegrity": val });
254
+ }
255
+
245
256
  get barcodeParserType() { return this._barcodeParserType; }
246
257
  set barcodeParserType(val) {
247
258
  this._barcodeParserType = val;
@@ -434,6 +445,13 @@ export class ProcessParams {
434
445
  this._set({ "lcidFilter": val });
435
446
  }
436
447
 
448
+ get fieldTypesIgnoreFilter() { return this._fieldTypesIgnoreFilter; }
449
+ set fieldTypesIgnoreFilter(val) {
450
+ this._fieldTypesIgnoreFilter = val;
451
+ this._set({ "fieldTypesIgnoreFilter": val });
452
+ }
453
+
454
+ _imageQA = new ImageQA();
437
455
  get imageQA() { return this._imageQA; }
438
456
  set imageQA(val) { (this._imageQA = val)._apply(); }
439
457
 
@@ -455,6 +473,7 @@ export class ProcessParams {
455
473
  this._set({ "backendProcessingConfig": val });
456
474
  }
457
475
 
476
+ _authenticityParams = new AuthenticityParams();
458
477
  get authenticityParams() { return this._authenticityParams; }
459
478
  set authenticityParams(val) { (this._authenticityParams = val)._apply(); }
460
479
 
@@ -464,28 +483,6 @@ export class ProcessParams {
464
483
  this._set({ "customParams": val });
465
484
  }
466
485
 
467
- _checkFilters = {};
468
-
469
- setCheckFilter(checkType, filter) {
470
- this._checkFilters[checkType] = filter;
471
- this._set({
472
- "setCheckFilter": {
473
- "checkType": checkType,
474
- "filterObject": filter.toJson(),
475
- },
476
- });
477
- }
478
-
479
- removeCheckFilter(checkType) {
480
- delete this._checkFilters[checkType];
481
- this._set({ "removeCheckFilter": checkType });
482
- }
483
-
484
- clearCheckFilter() {
485
- this._checkFilters = {};
486
- this._set({ "clearCheckFilter": null });
487
- }
488
-
489
486
  static fromJson(jsonObject) {
490
487
  if (jsonObject == null) return new ProcessParams();
491
488
  const result = new ProcessParams();
@@ -529,6 +526,8 @@ export class ProcessParams {
529
526
  result._generateAlpha2Codes = jsonObject["generateAlpha2Codes"];
530
527
  result._disableAuthResolutionFilter = jsonObject["disableAuthResolutionFilter"];
531
528
  result._strictSecurityChecks = jsonObject["strictSecurityChecks"];
529
+ result._returnTransliteratedFields = jsonObject["returnTransliteratedFields"];
530
+ result._checkCaptureProcessIntegrity = jsonObject["checkCaptureProcessIntegrity"];
532
531
  result._barcodeParserType = jsonObject["barcodeParserType"];
533
532
  result._perspectiveAngle = jsonObject["perspectiveAngle"];
534
533
  result._minDPI = jsonObject["minDPI"];
@@ -561,14 +560,13 @@ export class ProcessParams {
561
560
  result._documentGroupFilter = jsonObject["documentGroupFilter"];
562
561
  result._lcidIgnoreFilter = jsonObject["lcidIgnoreFilter"];
563
562
  result._lcidFilter = jsonObject["lcidFilter"];
563
+ result._fieldTypesIgnoreFilter = jsonObject["fieldTypesIgnoreFilter"];
564
564
  result._imageQA = ImageQA.fromJson(jsonObject["imageQA"]);
565
565
  result._rfidParams = RFIDParams.fromJson(jsonObject["rfidParams"]);
566
566
  result._faceApiParams = FaceApiParams.fromJson(jsonObject["faceApiParams"]);
567
567
  result._backendProcessingConfig = BackendProcessingConfig.fromJson(jsonObject["backendProcessingConfig"]);
568
568
  result._authenticityParams = AuthenticityParams.fromJson(jsonObject["authenticityParams"]);
569
569
  result._customParams = jsonObject["customParams"];
570
- result._checkFilters = Object.fromEntries(Object.entries(jsonObject["checkFilters"] ?? {})
571
- .map(([k, v]) => [k, FilterObject.fromJson(v)]));
572
570
 
573
571
  return result;
574
572
  }
@@ -613,6 +611,8 @@ export class ProcessParams {
613
611
  "generateAlpha2Codes": this.generateAlpha2Codes,
614
612
  "disableAuthResolutionFilter": this.disableAuthResolutionFilter,
615
613
  "strictSecurityChecks": this.strictSecurityChecks,
614
+ "returnTransliteratedFields": this.returnTransliteratedFields,
615
+ "checkCaptureProcessIntegrity": this.checkCaptureProcessIntegrity,
616
616
  "measureSystem": this.measureSystem,
617
617
  "barcodeParserType": this.barcodeParserType,
618
618
  "perspectiveAngle": this.perspectiveAngle,
@@ -645,13 +645,13 @@ export class ProcessParams {
645
645
  "documentGroupFilter": this.documentGroupFilter,
646
646
  "lcidIgnoreFilter": this.lcidIgnoreFilter,
647
647
  "lcidFilter": this.lcidFilter,
648
+ "fieldTypesIgnoreFilter": this.fieldTypesIgnoreFilter,
648
649
  "imageQA": this.imageQA?.toJson(),
649
650
  "rfidParams": this.rfidParams?.toJson(),
650
651
  "faceApiParams": this.faceApiParams?.toJson(),
651
652
  "backendProcessingConfig": this.backendProcessingConfig?.toJson(),
652
653
  "authenticityParams": this.authenticityParams?.toJson(),
653
654
  "customParams": this.customParams,
654
- "checkFilters": Object.fromEntries(Object.entries(this._checkFilters).map(([k, v]) => [k, v.toJson()])),
655
655
  }
656
656
  }
657
657
 
@@ -689,7 +689,3 @@ export const MrzDetectionModes = {
689
689
  RESIZE_BINARIZE_WINDOW: 1,
690
690
  BLUR_BEFORE_BINARIZATION: 2
691
691
  };
692
-
693
- export const FilterCheckType = {
694
- AUTH: "checkAuth",
695
- };
@@ -13,6 +13,7 @@ import { GraphicResult } from "./visual_results/GraphicResult";
13
13
  import { TextResult } from "./visual_results/TextResult";
14
14
  import { TextField } from "./visual_results/TextField";
15
15
  import { VDSNCData } from "./visible_digital_seals/VDSNCData";
16
+ import { VDSData } from "./visible_digital_seals/VDSData";
16
17
  import { Position } from "./Position";
17
18
  import { DocumentType } from "./DocumentType";
18
19
  import { TransactionInfo } from "./TransactionInfo";
@@ -31,6 +32,7 @@ export class Results {
31
32
  chipPage
32
33
  barcodeResult
33
34
  vdsncData
35
+ vdsData
34
36
  dtcData
35
37
  processingFinishedStatus
36
38
  morePagesAvailable
@@ -205,6 +207,7 @@ export class Results {
205
207
  result.barcodeResult = BarcodeResult.fromJson(jsonObject["barcodeResult"]);
206
208
  result.status = ResultsStatus.fromJson(jsonObject["status"]);
207
209
  result.vdsncData = VDSNCData.fromJson(jsonObject["vdsncData"]);
210
+ result.vdsData = VDSData.fromJson(jsonObject["vdsData"]);
208
211
  result.dtcData = jsonObject["dtcData"];
209
212
  result.transactionInfo = TransactionInfo.fromJson(jsonObject["transactionInfo"]);
210
213
 
@@ -275,6 +278,7 @@ export class Results {
275
278
  "rfidSessionData": this.rfidSessionData?.toJson(),
276
279
  "barcodeResult": this.barcodeResult?.toJson(),
277
280
  "vdsncData": this.vdsncData?.toJson(),
281
+ "vdsData": this.vdsData?.toJson(),
278
282
  "dtcData": this.dtcData,
279
283
  "chipPage": this.chipPage,
280
284
  "processingFinishedStatus": this.processingFinishedStatus,
@@ -339,5 +343,8 @@ export const ResultType = {
339
343
  RFID_IMAGE_DATA: 103,
340
344
  RFID_BINARY_DATA: 104,
341
345
  RFID_ORIGINAL_GRAPHICS: 105,
342
- RFID_DTC_VC: 109
346
+ RFID_DTC_VC: 109,
347
+ MDL_PARSED_RESPONSE: 121,
348
+ VDS_NC: 124,
349
+ VDS: 125,
343
350
  };
@@ -0,0 +1,35 @@
1
+ import { CheckResult } from './CheckResult';
2
+
3
+ export class AgeStatus {
4
+ threshold
5
+ overThreshold
6
+ over18
7
+ over21
8
+ over25
9
+ over65
10
+
11
+ static fromJson(jsonObject) {
12
+ if (jsonObject == null) return null;
13
+ const result = new AgeStatus();
14
+
15
+ result.threshold = jsonObject["threshold"];
16
+ result.overThreshold = jsonObject["overThreshold"];
17
+ result.over18 = jsonObject["over18"];
18
+ result.over21 = jsonObject["over21"];
19
+ result.over25 = jsonObject["over25"];
20
+ result.over65 = jsonObject["over65"];
21
+
22
+ return result;
23
+ }
24
+
25
+ toJson() {
26
+ return {
27
+ "threshold": this.threshold,
28
+ "overThreshold": this.overThreshold,
29
+ "over18": this.over18,
30
+ "over21": this.over21,
31
+ "over25": this.over25,
32
+ "over65": this.over65,
33
+ }
34
+ }
35
+ }
@@ -1,5 +1,6 @@
1
1
  import { CheckResult } from './CheckResult';
2
2
  import { OpticalStatus } from './OpticalStatus';
3
+ import { AgeStatus } from './AgeStatus';
3
4
  import { RFIDStatus } from './RFIDStatus';
4
5
 
5
6
  export class ResultsStatus {
@@ -10,6 +11,10 @@ export class ResultsStatus {
10
11
  detailsRFID
11
12
  portrait
12
13
  stopList
14
+ mDL
15
+ age
16
+ captureProcessIntegrity
17
+ ageStatus
13
18
 
14
19
  static fromJson(jsonObject) {
15
20
  if (jsonObject == null) return null;
@@ -22,6 +27,10 @@ export class ResultsStatus {
22
27
  result.detailsRFID = RFIDStatus.fromJson(jsonObject["detailsRFID"]);
23
28
  result.portrait = jsonObject["portrait"];
24
29
  result.stopList = jsonObject["stopList"];
30
+ result.mDL = jsonObject["mDL"];
31
+ result.age = jsonObject["age"];
32
+ result.captureProcessIntegrity = jsonObject["captureProcessIntegrity"];
33
+ result.ageStatus = AgeStatus.fromJson(jsonObject["detailsAge"]);
25
34
 
26
35
  return result;
27
36
  }
@@ -33,8 +42,12 @@ export class ResultsStatus {
33
42
  "rfid": this.rfid,
34
43
  "portrait": this.portrait,
35
44
  "stopList": this.stopList,
45
+ "mDL": this.mDL,
46
+ "age": this.age,
47
+ "captureProcessIntegrity": this.captureProcessIntegrity,
36
48
  "detailsOptical": this.detailsOptical?.toJson(),
37
49
  "detailsRFID": this.detailsRFID?.toJson(),
50
+ "detailsAge": this.ageStatus?.toJson(),
38
51
  }
39
52
  }
40
53
  }
@@ -0,0 +1,23 @@
1
+ import { BytesData } from './BytesData';
2
+
3
+ export class DocFeature {
4
+ type
5
+ data
6
+
7
+ static fromJson(jsonObject) {
8
+ if (jsonObject == null) return null;
9
+
10
+ const result = new DocFeature();
11
+ result.type = jsonObject["type"];
12
+ result.data = BytesData.fromJson(jsonObject["data"]);
13
+
14
+ return result;
15
+ }
16
+
17
+ toJson() {
18
+ return {
19
+ "type": this.type,
20
+ "data": this.data?.toJson(),
21
+ }
22
+ }
23
+ }
@@ -0,0 +1,75 @@
1
+ import { CertificateChain } from '../rfid/CertificateChain';
2
+ import { BytesData } from './BytesData';
3
+ import { DocFeature } from './DocFeature';
4
+
5
+ export class VDSData {
6
+ type
7
+ docType
8
+ featureRef
9
+ version
10
+ issuingCountry
11
+ docIssueDate
12
+ signature
13
+ signatureDate
14
+ signer
15
+ certificate
16
+ certificateChain
17
+ docFeatures
18
+ notifications
19
+
20
+ static fromJson(jsonObject) {
21
+ if (jsonObject == null) return null;
22
+ const result = new VDSData();
23
+
24
+ result.type = jsonObject["type"];
25
+ result.docType = jsonObject["docType"];
26
+ result.featureRef = jsonObject["featureRef"];
27
+ result.version = jsonObject["version"];
28
+ result.issuingCountry = jsonObject["issuingCountry"];
29
+ result.docIssueDate = jsonObject["docIssueDate"];
30
+ result.signature = BytesData.fromJson(jsonObject["signature"]);
31
+ result.signatureDate = jsonObject["signatureDate"];
32
+ result.signer = jsonObject["signer"];
33
+ result.certificate = jsonObject["certificate"];
34
+ result.notifications = jsonObject["notifications"];
35
+
36
+ if (jsonObject["certificateChain"] != null) {
37
+ result.certificateChain = [];
38
+ for (const item of jsonObject["certificateChain"]) {
39
+ const certificateChain = CertificateChain.fromJson(item);
40
+ if (certificateChain != null) {
41
+ result.certificateChain.push(certificateChain);
42
+ }
43
+ }
44
+ }
45
+ if (jsonObject["docFeatures"] != null) {
46
+ result.docFeatures = [];
47
+ for (const item of jsonObject["docFeatures"]) {
48
+ const docFeature = DocFeature.fromJson(item);
49
+ if (docFeature != null) {
50
+ result.docFeatures.push(docFeature);
51
+ }
52
+ }
53
+ }
54
+
55
+ return result;
56
+ }
57
+
58
+ toJson() {
59
+ return {
60
+ "type": this.type,
61
+ "docType": this.docType,
62
+ "featureRef": this.featureRef,
63
+ "version": this.version,
64
+ "issuingCountry": this.issuingCountry,
65
+ "docIssueDate": this.docIssueDate,
66
+ "signature": this.signature?.toJson(),
67
+ "signatureDate": this.signatureDate,
68
+ "signer": this.signer,
69
+ "certificate": this.certificate,
70
+ "certificateChain": this.certificateChain?.map(e => e.toJson()),
71
+ "docFeatures": this.docFeatures?.map(e => e.toJson()),
72
+ "notifications": this.notifications,
73
+ }
74
+ }
75
+ }
@@ -653,6 +653,9 @@ export const FieldType = {
653
653
  NATIONALITY_CODE_ALPHA_2: 697,
654
654
  FIRST_ISSUE_DATE_CHECKDIGIT: 698,
655
655
  FIRST_ISSUE_DATE_CHECKSUM: 699,
656
+ COMMERCIAL_INDICATOR: 701,
657
+ NON_DOMICILED_INDICATOR: 702,
658
+ JURISDICTION_SPECIFIC_DATA: 703,
656
659
  }
657
660
 
658
661
  FieldType.getTranslation = async function (value) {
@@ -36,6 +36,9 @@ export const PKDResourceType = {
36
36
  DEFL: 5,
37
37
  DEVL: 6,
38
38
  BL: 7,
39
+ LDIF_TA: 8,
40
+ ML_TA: 9,
41
+ CBOR: 10,
39
42
 
40
43
  getType(value) {
41
44
  switch (value) {
@@ -0,0 +1,28 @@
1
+ import { DocumentRequestMDL } from "./DocumentRequestMDL";
2
+ import { MDLIntentToRetain } from "./NameSpaceMDL";
3
+
4
+ export declare class DataRetrieval {
5
+ constructor(deviceRetrieval: MDLDocRequestPreset);
6
+
7
+ setDocRequestPreset(docRequestPreset: MDLDocRequestPreset, intentToRetain: MDLIntentToRetain): void
8
+ addDocRequest(request: DocumentRequestMDL): void;
9
+
10
+ /**
11
+ * Allows you to deserialize object.
12
+ * @param jsonObject
13
+ */
14
+ static fromJson(jsonObject: any): DataRetrieval | null;
15
+ }
16
+
17
+ export declare enum MDLDocRequestPreset {
18
+ ALL = 0,
19
+ AGE = 1,
20
+ STANDARD_ID = 2,
21
+ TRAVEL = 3,
22
+ DRIVERS_LICENSE = 4,
23
+ }
24
+
25
+ export declare enum MDLDeviceRetrieval {
26
+ NFC = 1,
27
+ BLE = 2,
28
+ }
@@ -0,0 +1,16 @@
1
+ import { DeviceRetrievalMethod } from "./DeviceRetrievalMethod";
2
+
3
+ export declare class DeviceEngagement {
4
+ deviceRetrievalMethods: DeviceRetrievalMethod[];
5
+
6
+ /**
7
+ * Allows you to deserialize object.
8
+ * @param jsonObject
9
+ */
10
+ static fromJson(jsonObject: any): DeviceEngagement | null;
11
+ }
12
+
13
+ export declare enum MDLDeviceEngagement {
14
+ QR = 0,
15
+ NFC = 1,
16
+ }
@@ -0,0 +1,18 @@
1
+ import { MDLDeviceRetrieval } from "./DataRetrieval";
2
+
3
+ export declare class DeviceRetrievalMethod {
4
+ readonly type: MDLDeviceRetrieval;
5
+ readonly version?: number;
6
+ readonly cmdMaxLength?: number;
7
+ readonly respMaxLength?: number;
8
+ readonly clientModeSupport?: boolean;
9
+ readonly clientModeUUID?: string;
10
+ readonly serverModeSupport?: boolean;
11
+ readonly serverModeUUID?: string;
12
+
13
+ /**
14
+ * Allows you to deserialize object.
15
+ * @param jsonObject
16
+ */
17
+ static fromJson(jsonObject: any): DeviceRetrievalMethod | null;
18
+ }
@@ -0,0 +1,61 @@
1
+ import { NameSpaceMDL, MDLIntentToRetain } from "./NameSpaceMDL";
2
+
3
+ export declare class DocumentRequestMDL {
4
+ constructor(docType: string);
5
+
6
+ addNameSpace(namespace: NameSpaceMDL): void;
7
+
8
+ /**
9
+ * Allows you to deserialize object.
10
+ * @param jsonObject
11
+ */
12
+ static fromJson(jsonObject: any): DocumentRequestMDL | null;
13
+ }
14
+
15
+ export declare class DocumentRequest18013MDL extends DocumentRequestMDL {
16
+ familyName? : MDLIntentToRetain;
17
+ givenName? : MDLIntentToRetain;
18
+ birthDate? : MDLIntentToRetain;
19
+ issueDate? : MDLIntentToRetain;
20
+ expiryDate? : MDLIntentToRetain;
21
+ issuingCountry? : MDLIntentToRetain;
22
+ issuingAuthority? : MDLIntentToRetain;
23
+ documentNumber? : MDLIntentToRetain;
24
+ portrait? : MDLIntentToRetain;
25
+ drivingPrivileges? : MDLIntentToRetain;
26
+ unDistinguishingSign? : MDLIntentToRetain;
27
+ administrativeNumber? : MDLIntentToRetain;
28
+ sex? : MDLIntentToRetain;
29
+ height? : MDLIntentToRetain;
30
+ weight? : MDLIntentToRetain;
31
+ eyeColour? : MDLIntentToRetain;
32
+ hairColour? : MDLIntentToRetain;
33
+ birthPlace? : MDLIntentToRetain;
34
+ residentAddress? : MDLIntentToRetain;
35
+ portraitCaptureDate? : MDLIntentToRetain;
36
+ ageInYears? : MDLIntentToRetain;
37
+ ageBirthYear? : MDLIntentToRetain;
38
+ ageOver18? : MDLIntentToRetain;
39
+ issuingJurisdiction? : MDLIntentToRetain;
40
+ nationality? : MDLIntentToRetain;
41
+ residentCity? : MDLIntentToRetain;
42
+ residentState? : MDLIntentToRetain;
43
+ residentPostalCode? : MDLIntentToRetain;
44
+ residentCountry? : MDLIntentToRetain;
45
+ biometricTemplateFace? : MDLIntentToRetain;
46
+ biometricTemplateIris? : MDLIntentToRetain;
47
+ biometricTemplateFinger? : MDLIntentToRetain;
48
+ biometricTemplateSignatureSign? : MDLIntentToRetain;
49
+ familyNameNationalCharacter? : MDLIntentToRetain;
50
+ givenNameNationalCharacter? : MDLIntentToRetain;
51
+ signatureUsualMark? : MDLIntentToRetain;
52
+
53
+ disableIntentToRetainValues(): void
54
+ enableIntentToRetainValues(): void
55
+
56
+ /**
57
+ * Allows you to deserialize object.
58
+ * @param jsonObject
59
+ */
60
+ static fromJson(jsonObject: any): DocumentRequest18013MDL | null;
61
+ }
@@ -0,0 +1,16 @@
1
+ export declare class NameSpaceMDL {
2
+ constructor(name: string);
3
+
4
+ addField(name: string, intentToRetain: MDLIntentToRetain): void;
5
+
6
+ /**
7
+ * Allows you to deserialize object.
8
+ * @param jsonObject
9
+ */
10
+ static fromJson(jsonObject: any): NameSpaceMDL | null;
11
+ }
12
+
13
+ export declare enum MDLIntentToRetain {
14
+ FALSE = 0,
15
+ TRUE = 1,
16
+ }
@@ -41,8 +41,9 @@ import { RFIDStatus } from './results/status/RFIDStatus';
41
41
  import { ResultsStatus } from './results/status/ResultsStatus';
42
42
  import { CheckResult } from './results/status/CheckResult';
43
43
  import { OpticalStatus } from './results/status/OpticalStatus';
44
+ import { AgeStatus } from './results/status/AgeStatus';
44
45
  import { ProcessingFinishedStatus } from './results/Results';
45
- export { RFIDStatus, ResultsStatus, CheckResult, OpticalStatus, ProcessingFinishedStatus };
46
+ export { RFIDStatus, ResultsStatus, CheckResult, OpticalStatus, AgeStatus, ProcessingFinishedStatus };
46
47
 
47
48
  import { CheckDiagnose } from './results/authenticity/CheckDiagnose';
48
49
  import { AuthenticityElement } from './results/authenticity/AuthenticityElement';
@@ -67,8 +68,10 @@ export { ImageQuality, ImageQualityGroup, ImageQualityCheckType };
67
68
  import { LDSParsingErrorCodes } from './results/visible_digital_seals/LDSParsingErrorCodes';
68
69
  import { VDSNCData } from './results/visible_digital_seals/VDSNCData';
69
70
  import { BytesData } from './results/visible_digital_seals/BytesData';
71
+ import { DocFeature } from './results/visible_digital_seals/DocFeature';
72
+ import { VDSData } from './results/visible_digital_seals/VDSData';
70
73
  import { LDSParsingNotificationCodes } from './results/visible_digital_seals/LDSParsingNotificationCodes';
71
- export { LDSParsingErrorCodes, VDSNCData, BytesData, LDSParsingNotificationCodes };
74
+ export { LDSParsingErrorCodes, VDSNCData, BytesData, DocFeature, VDSData, LDSParsingNotificationCodes };
72
75
 
73
76
  import { SecurityObject } from './results/rfid/SecurityObject';
74
77
  import { CardProperties } from './results/rfid/CardProperties';
@@ -92,17 +95,16 @@ import { Extension } from './results/rfid/Extension';
92
95
  import { AccessControlProcedureType } from './results/rfid/AccessControlProcedureType';
93
96
  export { SecurityObject, CardProperties, DataField, Attribute, SignerInfo, SecurityObjectCertificates, CertificateChain, Authority, File, RFIDValue, RFIDValidity, RFIDDataFileType, CertificateData, FileData, RFIDCertificateType, RFIDSessionData, Application, RFIDApplicationType, RFIDAccessControlProcedureType, Extension, AccessControlProcedureType };
94
97
 
95
- import { FilterObject, FilterObjectType } from './params/process_params/FilterObject';
96
- import { LivenessParams, LivenessCheckType } from './params/process_params/LivenessParams';
97
- import { ProcessParams, MeasureSystem, MRZFormat, LogLevel, MrzDetectionModes, FilterCheckType } from './params/process_params/ProcessParams';
98
+ import { LivenessParams } from './params/process_params/LivenessParams';
99
+ import { ProcessParams, MeasureSystem, MRZFormat, LogLevel, MrzDetectionModes } from './params/process_params/ProcessParams';
98
100
  import { GlaresCheckParams } from './params/process_params/GlaresCheckParams';
99
101
  import { FaceApiParams } from './params/process_params/FaceApiParams';
100
102
  import { RFIDParams } from './params/process_params/RFIDParams';
101
103
  import { ImageQA } from './params/process_params/ImageQA';
102
- import { AuthenticityParams, AuthenticityCheckType } from './params/process_params/AuthenticityParams';
104
+ import { AuthenticityParams } from './params/process_params/AuthenticityParams';
103
105
  import { BackendProcessingConfig } from './params/process_params/BackendProcessingConfig';
104
106
  import { FaceApiSearchParams } from './params/process_params/FaceApiSearchParams';
105
- export { FilterObject, FilterObjectType, LivenessParams, LivenessCheckType, ProcessParams, FilterCheckType, MeasureSystem, MRZFormat, LogLevel, MrzDetectionModes, GlaresCheckParams, FaceApiParams, RFIDParams, ImageQA, AuthenticityParams, AuthenticityCheckType,BackendProcessingConfig, FaceApiSearchParams };
107
+ export { LivenessParams, ProcessParams, MeasureSystem, MRZFormat, LogLevel, MrzDetectionModes, GlaresCheckParams, FaceApiParams, RFIDParams, ImageQA, AuthenticityParams,BackendProcessingConfig, FaceApiSearchParams };
106
108
 
107
109
  import { Functionality, CameraPosition, CaptureMode, CameraMode, CaptureSessionPreset, DocReaderFrame, CameraSize } from './params/Functionality';
108
110
  export { Functionality, CameraPosition, CaptureMode, CameraMode, CaptureSessionPreset, DocReaderFrame, CameraSize };
@@ -130,6 +132,13 @@ import { TAChallenge } from './rfid/TAChallenge';
130
132
  import { PKDCertificate, PKDResourceType } from './rfid/PKDCertificate';
131
133
  export { PAResourcesIssuer, RFIDErrorCodes, TccParams, RFIDNotification, RFIDNotificationCodes, PAAttribute, TAChallenge, PKDCertificate, PKDResourceType };
132
134
 
135
+ import { DataRetrieval, MDLDocRequestPreset, MDLDeviceRetrieval } from './engagement/DataRetrieval';
136
+ import { DeviceEngagement, MDLDeviceEngagement } from './engagement/DeviceEngagement';
137
+ import { NameSpaceMDL, MDLIntentToRetain } from './engagement/NameSpaceMDL';
138
+ import { DocumentRequestMDL, DocumentRequest18013MDL } from './engagement/DocumentRequestMDL';
139
+ import { DeviceRetrievalMethod } from './engagement/DeviceRetrievalMethod';
140
+ export { DataRetrieval, MDLDocRequestPreset, MDLDeviceRetrieval, DeviceEngagement, MDLDeviceEngagement, DeviceRetrievalMethod, DocumentRequest18013MDL, MDLIntentToRetain, NameSpaceMDL, DocumentRequestMDL };
141
+
133
142
 
134
143
  /**
135
144
  * Entry point of the Regula Document Reader.
@@ -346,7 +355,7 @@ export class DocumentReader {
346
355
  *
347
356
  * @param certificates - PKD certificates.
348
357
  */
349
- addPKDCertificates(certificates: [PKDCertificate]): void;
358
+ addPKDCertificates(certificates: PKDCertificate[]): void;
350
359
 
351
360
  /** It's used to remove certificates from your app that are used during the
352
361
  * RFID chip processing.
@@ -370,6 +379,29 @@ export class DocumentReader {
370
379
 
371
380
  /** It's used to end transaction during backend processing. */
372
381
  endBackendTransaction(): void;
382
+
383
+ /**
384
+ * Used to read MDL.
385
+ */
386
+ readMDL(type: MDLDeviceEngagement, retrieval: DataRetrieval): Promise<[action: DocReaderAction, results: Results | null, error: DocReaderException | null]>;
387
+
388
+ /**
389
+ * Used to engage device.
390
+ *
391
+ * @param withoutUI - If `true`, then Regula's UI will not be shown and user is supposed to implement the UI himself.
392
+ *
393
+ * @param data - Required if @param type = {@link MDLDeviceEngagement.QR} and @param withoutUI = `true`.
394
+ */
395
+ engageDevice(type: MDLDeviceEngagement, options?: {withoutUI: boolean, data?: string}): Promise<[engagement: DeviceEngagement | null, error: DocReaderException | null]>;
396
+
397
+ /**
398
+ * Used to retrieve data.
399
+ *
400
+ * @param withoutUI - If set, then Regula's UI will not be shown and user is supposed to implement the UI himself.
401
+ *
402
+ * @param engagement - Required for @param withoutUI = `null` or {@link MDLDeviceRetrieval.BLE}. Not needed for {@link MDLDeviceRetrieval.NFC}
403
+ */
404
+ retrieveData(retrieval: DataRetrieval, options?: {withoutUI: MDLDeviceRetrieval, engagement?: DeviceEngagement}): Promise<[action: DocReaderAction, results: Results | null, error: DocReaderException | null]>;
373
405
  }
374
406
 
375
407
  /**