uqudosdk-react-native 2.5.3 → 2.6.0-1

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.
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "uqudosdk-react-native",
3
3
  "title": "React Native UqudoId",
4
- "version": "2.5.3",
4
+ "version": "2.6.0-1",
5
5
  "description": "Uqudo SDK react native module",
6
6
  "main": "index.js",
7
7
  "author": {
@@ -26,6 +26,10 @@ export class UqudoIdSDK {
26
26
  return result;
27
27
  }
28
28
 
29
+ async lookup(lookupConfiguration) {
30
+ return await NativeModules.UqudoId.lookup(JSON.stringify(lookupConfiguration));
31
+ }
32
+
29
33
  async isFacialRecognitionSupported(documentType) {
30
34
  var result = await NativeModules.UqudoId.isFacialRecognitionSupported(documentType);
31
35
  return result;
@@ -35,6 +39,19 @@ export class UqudoIdSDK {
35
39
  var result = await NativeModules.UqudoId.isReadingSupported(documentType);
36
40
  return result;
37
41
  }
42
+
43
+ async isLookupSupported(documentType) {
44
+ return await NativeModules.UqudoId.isLookupSupported(documentType);
45
+ }
46
+
47
+ async isLookupFacialRecognitionSupported(documentType) {
48
+ return await NativeModules.UqudoId.isLookupFacialRecognitionSupported(documentType);
49
+ }
50
+
51
+ async isEnrollmentSupported(documentType) {
52
+ return await NativeModules.UqudoId.isEnrollmentSupported(documentType);
53
+ }
54
+
38
55
  }
39
56
 
40
57
  export const DocumentType = Object.freeze(
@@ -91,6 +108,7 @@ export const DocumentType = Object.freeze(
91
108
  IND_PAN: 'IND_PAN',
92
109
  SAU_ID_NATIONAL: 'SAU_ID_NATIONAL',
93
110
  SAU_ID_RESIDENT: 'SAU_ID_RESIDENT',
111
+ NGA_BVN: 'NGA_BVN'
94
112
  }
95
113
  );
96
114
 
@@ -232,13 +250,18 @@ export class FacialRecognitionConfigurationBuilder {
232
250
  return this;
233
251
  },
234
252
 
253
+ setLookupMinimumMatchLevel: function (lookupMinimumMatchLevel) {
254
+ this.lookupMinimumMatchLevel = lookupMinimumMatchLevel;
255
+ return this;
256
+ },
257
+
235
258
  setMaxAttempts: function (maxAttempts) {
236
259
  this.maxAttempts = maxAttempts;
237
260
  return this;
238
261
  },
239
262
 
240
263
  build: function () {
241
- return new FacialRecognitionConfiguration(this.enrollFace, this.scanMinimumMatchLevel, this.readMinimumMatchLevel, this.maxAttempts);
264
+ return new FacialRecognitionConfiguration(this.enrollFace, this.scanMinimumMatchLevel, this.readMinimumMatchLevel, this.lookupMinimumMatchLevel, this.maxAttempts);
242
265
  }
243
266
  };
244
267
  }
@@ -246,10 +269,11 @@ export class FacialRecognitionConfigurationBuilder {
246
269
 
247
270
 
248
271
  export class FacialRecognitionConfiguration {
249
- constructor(enrollFace, scanMinimumMatchLevel, readMinimumMatchLevel, maxAttempts) {
272
+ constructor(enrollFace, scanMinimumMatchLevel, readMinimumMatchLevel, lookupMinimumMatchLevel, maxAttempts) {
250
273
  this.enrollFace = enrollFace;
251
274
  this.scanMinimumMatchLevel = scanMinimumMatchLevel;
252
275
  this.readMinimumMatchLevel = readMinimumMatchLevel;
276
+ this.lookupMinimumMatchLevel = lookupMinimumMatchLevel;
253
277
  this.maxAttempts = maxAttempts;
254
278
  }
255
279
  }
@@ -607,3 +631,87 @@ export class FaceSessionConfiguration {
607
631
 
608
632
  }
609
633
  }
634
+
635
+ export class Lookup {
636
+ constructor(documentType, authorizationToken, nonce, isSecuredWindowsDisabled,
637
+ facialRecognitionSpecification, backgroundCheckConfiguration, sessionId,
638
+ userIdentifier, isReturnDataForIncompleteSession, appearanceMode) {
639
+ this.documentType = documentType;
640
+ this.authorizationToken = authorizationToken;
641
+ this.nonce = nonce;
642
+ this.isSecuredWindowsDisabled = isSecuredWindowsDisabled;
643
+ this.facialRecognitionSpecification = facialRecognitionSpecification;
644
+ this.backgroundCheckConfiguration = backgroundCheckConfiguration;
645
+ this.sessionId = sessionId;
646
+ this.userIdentifier = userIdentifier;
647
+ this.isReturnDataForIncompleteSession = isReturnDataForIncompleteSession;
648
+ this.appearanceMode = appearanceMode;
649
+ }
650
+ }
651
+
652
+ export class LookupBuilder {
653
+ setToken(token) {
654
+ this.authorizationToken = token;
655
+ return this;
656
+ }
657
+
658
+ setNonce(nonce) {
659
+ this.nonce = nonce;
660
+ return this;
661
+ }
662
+
663
+ setSessionId(sessionId) {
664
+ this.sessionId = sessionId;
665
+ return this;
666
+ }
667
+
668
+ setUserIdentifier(userIdentifier) {
669
+ this.userIdentifier = userIdentifier;
670
+ return this;
671
+ }
672
+
673
+ setDocumentType(documentType) {
674
+ this.documentType = documentType;
675
+ return this;
676
+ }
677
+
678
+ setAppearanceMode(appearanceMode) {
679
+ this.appearanceMode = appearanceMode;
680
+ return this;
681
+ }
682
+
683
+ disableSecureWindow() {
684
+ this.isSecuredWindowsDisabled = true;
685
+ return this;
686
+ }
687
+
688
+ enableFacialRecognition() {
689
+ if (arguments.length === 0) {
690
+ this.facialRecognitionSpecification = new FacialRecognitionConfigurationBuilder().build();
691
+ } else {
692
+ this.facialRecognitionSpecification = arguments[0];
693
+ }
694
+ return this;
695
+ }
696
+
697
+ enableBackgroundCheck() {
698
+ if (arguments.length === 0) {
699
+ this.backgroundCheckConfiguration = new BackgroundCheckConfigurationBuilder().build();
700
+ } else {
701
+ this.backgroundCheckConfiguration = arguments[0];
702
+ }
703
+ return this;
704
+ }
705
+
706
+ returnDataForIncompleteSession() {
707
+ this.isReturnDataForIncompleteSession = true;
708
+ return this;
709
+ }
710
+
711
+ build() {
712
+ return new Lookup(this.documentType, this.authorizationToken, this.nonce, this.isSecuredWindowsDisabled,
713
+ this.facialRecognitionSpecification, this.backgroundCheckConfiguration, this.sessionId,
714
+ this.userIdentifier, this.isReturnDataForIncompleteSession, this.appearanceMode);
715
+ }
716
+
717
+ }
@@ -13,5 +13,5 @@ Pod::Spec.new do |s|
13
13
  s.source = { :http => 'https://uqudo.com' }
14
14
  s.header_dir = 'UqudoSDK'
15
15
  s.dependency 'React'
16
- s.dependency 'UqudoSDK', '2.5.3'
16
+ s.dependency 'UqudoSDK', '2.6.0'
17
17
  end