assentify-sdk-react-native 0.0.1 → 0.0.3
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/README.md +4 -0
- package/lib/commonjs/AssentifyWrapper.js +1 -30
- package/lib/commonjs/AssentifyWrapper.js.map +1 -1
- package/lib/module/AssentifyWrapper.js +2 -31
- package/lib/module/AssentifyWrapper.js.map +1 -1
- package/lib/typescript/example/src/Home.d.ts.map +1 -1
- package/lib/typescript/lib/commonjs/AssentifyWrapper.d.ts.map +1 -1
- package/lib/typescript/lib/module/AssentifyWrapper.d.ts.map +1 -1
- package/lib/typescript/src/AssentifyWrapper.d.ts.map +1 -1
- package/package.json +1 -2
- package/src/AssentifyWrapper.ts +15 -67
package/README.md
CHANGED
|
@@ -16,6 +16,10 @@ With a focus on cutting-edge technologies such as machine learning, natural lang
|
|
|
16
16
|
- **Scalability:** Scale seamlessly as your application grows, with robust support from Assentify's infrastructure.
|
|
17
17
|
- **Security:** Ensure the highest levels of data security and compliance with Assentify's industry-leading standards.
|
|
18
18
|
|
|
19
|
+
## Example
|
|
20
|
+
|
|
21
|
+
[To run the example project](https://github.com/AssentifyLTD/Assentify.ReactNative.Demo)
|
|
22
|
+
|
|
19
23
|
## Installation
|
|
20
24
|
|
|
21
25
|
To install the Assentify React Native package, simply add it to your project:
|
|
@@ -5,7 +5,6 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
5
5
|
});
|
|
6
6
|
exports.default = void 0;
|
|
7
7
|
var _reactNative = require("react-native");
|
|
8
|
-
var _reactNativePermissions = require("react-native-permissions");
|
|
9
8
|
const LINKING_ERROR = `The package 'assentify-sdk-react-native-react-native' doesn't seem to be linked. Make sure: \n\n` + _reactNative.Platform.select({
|
|
10
9
|
ios: "- You have run 'pod install'\n",
|
|
11
10
|
default: ''
|
|
@@ -21,35 +20,7 @@ const AssentifySdk = _reactNative.NativeModules.NativeAssentifySdk ? _reactNativ
|
|
|
21
20
|
const AssentifyWrapper = {
|
|
22
21
|
/// Initialize
|
|
23
22
|
initialize: function (apiKey, tenantIdentifier, instanceHash, processMrz, storeCapturedDocument, performLivenessDocument, performLivenessFace, storeImageStream, saveCapturedVideoID, saveCapturedVideoFace, ENV_CustomColor, enableDetect, enableGuide) {
|
|
24
|
-
(
|
|
25
|
-
android: _reactNativePermissions.PERMISSIONS.ANDROID.CAMERA,
|
|
26
|
-
ios: _reactNativePermissions.PERMISSIONS.IOS.CAMERA,
|
|
27
|
-
default: _reactNativePermissions.PERMISSIONS.ANDROID.CAMERA
|
|
28
|
-
})).then(result => {
|
|
29
|
-
if (result === _reactNativePermissions.RESULTS.GRANTED) {
|
|
30
|
-
AssentifySdk.initialize(apiKey, tenantIdentifier, instanceHash, processMrz ?? true, storeCapturedDocument ?? true, performLivenessDocument ?? false, performLivenessFace ?? false, storeImageStream ?? true, saveCapturedVideoID ?? true, saveCapturedVideoFace ?? true, ENV_CustomColor ?? '#f5a103', enableDetect ?? true, enableGuide ?? true);
|
|
31
|
-
} else if (result === _reactNativePermissions.RESULTS.UNAVAILABLE || result === _reactNativePermissions.RESULTS.DENIED || result === _reactNativePermissions.RESULTS.BLOCKED) {
|
|
32
|
-
_reactNative.Alert.alert('Warning!', 'Please allow your camera permission in order to proceed further', [{
|
|
33
|
-
text: 'Open Settings',
|
|
34
|
-
onPress: () => {
|
|
35
|
-
_reactNative.Linking.openSettings();
|
|
36
|
-
}
|
|
37
|
-
}, {
|
|
38
|
-
text: 'Cancel',
|
|
39
|
-
onPress: () => {}
|
|
40
|
-
}]);
|
|
41
|
-
}
|
|
42
|
-
}, () => {
|
|
43
|
-
_reactNative.Alert.alert('Warning!', 'Please allow your camera permission in order to proceed further', [{
|
|
44
|
-
text: 'Open Settings',
|
|
45
|
-
onPress: () => {
|
|
46
|
-
_reactNative.Linking.openSettings();
|
|
47
|
-
}
|
|
48
|
-
}, {
|
|
49
|
-
text: 'Cancel',
|
|
50
|
-
onPress: () => {}
|
|
51
|
-
}]);
|
|
52
|
-
});
|
|
23
|
+
AssentifySdk.initialize(apiKey, tenantIdentifier, instanceHash, processMrz ?? true, storeCapturedDocument ?? true, performLivenessDocument ?? false, performLivenessFace ?? false, storeImageStream ?? true, saveCapturedVideoID ?? true, saveCapturedVideoFace ?? true, ENV_CustomColor ?? '#f5a103', enableDetect ?? true, enableGuide ?? true);
|
|
53
24
|
},
|
|
54
25
|
/// Passport
|
|
55
26
|
startScanPassport: function (language) {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["_reactNative","require","
|
|
1
|
+
{"version":3,"names":["_reactNative","require","LINKING_ERROR","Platform","select","ios","default","NativeAssentifySdk","NativeModules","AssentifySdk","Proxy","get","Error","AssentifyWrapper","initialize","apiKey","tenantIdentifier","instanceHash","processMrz","storeCapturedDocument","performLivenessDocument","performLivenessFace","storeImageStream","saveCapturedVideoID","saveCapturedVideoFace","ENV_CustomColor","enableDetect","enableGuide","startScanPassport","language","startScanOther","startScanOtherIDPage","startScanIDCard","kycDocumentDetailsList","flippingCard","startScanIDPage","JSON","stringify","startFaceMatch","imageUrl","showCountDown","submitData","dataMap","_default","exports"],"sourceRoot":"..\\..\\src","sources":["AssentifyWrapper.ts"],"mappings":";;;;;;AAAA,IAAAA,YAAA,GAAAC,OAAA;AAIA,MAAMC,aAAa,GACjB,kGAAkG,GAClGC,qBAAQ,CAACC,MAAM,CAAC;EAAEC,GAAG,EAAE,gCAAgC;EAAEC,OAAO,EAAE;AAAG,CAAC,CAAC,GACvE,sDAAsD,GACtD,+BAA+B;AAEjC,MAAM;EAAEC;AAAmB,CAAC,GAAGC,0BAAa;AAE5C,MAAMC,YAAY,GAAGD,0BAAa,CAACD,kBAAkB,GACjDC,0BAAa,CAACD,kBAAkB,GAChC,IAAIG,KAAK,CACP,CAAC,CAAC,EACF;EACEC,GAAGA,CAAA,EAAG;IACJ,MAAM,IAAIC,KAAK,CAACV,aAAa,CAAC;EAChC;AACF,CACF,CAAC;AAEL,MAAMW,gBAAgB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ACgC,UAAU,CAACC,OAAO,CAAC;EACpC;AAMN,CAAC;AAAC,IAAAC,QAAA,GAAAC,OAAA,CAAAtC,OAAA,GAEaO,gBAAgB","ignoreList":[]}
|
|
@@ -1,5 +1,4 @@
|
|
|
1
|
-
import { NativeModules, Platform
|
|
2
|
-
import { request, PERMISSIONS, RESULTS } from 'react-native-permissions';
|
|
1
|
+
import { NativeModules, Platform } from 'react-native';
|
|
3
2
|
const LINKING_ERROR = `The package 'assentify-sdk-react-native-react-native' doesn't seem to be linked. Make sure: \n\n` + Platform.select({
|
|
4
3
|
ios: "- You have run 'pod install'\n",
|
|
5
4
|
default: ''
|
|
@@ -15,35 +14,7 @@ const AssentifySdk = NativeModules.NativeAssentifySdk ? NativeModules.NativeAsse
|
|
|
15
14
|
const AssentifyWrapper = {
|
|
16
15
|
/// Initialize
|
|
17
16
|
initialize: function (apiKey, tenantIdentifier, instanceHash, processMrz, storeCapturedDocument, performLivenessDocument, performLivenessFace, storeImageStream, saveCapturedVideoID, saveCapturedVideoFace, ENV_CustomColor, enableDetect, enableGuide) {
|
|
18
|
-
|
|
19
|
-
android: PERMISSIONS.ANDROID.CAMERA,
|
|
20
|
-
ios: PERMISSIONS.IOS.CAMERA,
|
|
21
|
-
default: PERMISSIONS.ANDROID.CAMERA
|
|
22
|
-
})).then(result => {
|
|
23
|
-
if (result === RESULTS.GRANTED) {
|
|
24
|
-
AssentifySdk.initialize(apiKey, tenantIdentifier, instanceHash, processMrz ?? true, storeCapturedDocument ?? true, performLivenessDocument ?? false, performLivenessFace ?? false, storeImageStream ?? true, saveCapturedVideoID ?? true, saveCapturedVideoFace ?? true, ENV_CustomColor ?? '#f5a103', enableDetect ?? true, enableGuide ?? true);
|
|
25
|
-
} else if (result === RESULTS.UNAVAILABLE || result === RESULTS.DENIED || result === RESULTS.BLOCKED) {
|
|
26
|
-
Alert.alert('Warning!', 'Please allow your camera permission in order to proceed further', [{
|
|
27
|
-
text: 'Open Settings',
|
|
28
|
-
onPress: () => {
|
|
29
|
-
Linking.openSettings();
|
|
30
|
-
}
|
|
31
|
-
}, {
|
|
32
|
-
text: 'Cancel',
|
|
33
|
-
onPress: () => {}
|
|
34
|
-
}]);
|
|
35
|
-
}
|
|
36
|
-
}, () => {
|
|
37
|
-
Alert.alert('Warning!', 'Please allow your camera permission in order to proceed further', [{
|
|
38
|
-
text: 'Open Settings',
|
|
39
|
-
onPress: () => {
|
|
40
|
-
Linking.openSettings();
|
|
41
|
-
}
|
|
42
|
-
}, {
|
|
43
|
-
text: 'Cancel',
|
|
44
|
-
onPress: () => {}
|
|
45
|
-
}]);
|
|
46
|
-
});
|
|
17
|
+
AssentifySdk.initialize(apiKey, tenantIdentifier, instanceHash, processMrz ?? true, storeCapturedDocument ?? true, performLivenessDocument ?? false, performLivenessFace ?? false, storeImageStream ?? true, saveCapturedVideoID ?? true, saveCapturedVideoFace ?? true, ENV_CustomColor ?? '#f5a103', enableDetect ?? true, enableGuide ?? true);
|
|
47
18
|
},
|
|
48
19
|
/// Passport
|
|
49
20
|
startScanPassport: function (language) {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["NativeModules","Platform","
|
|
1
|
+
{"version":3,"names":["NativeModules","Platform","LINKING_ERROR","select","ios","default","NativeAssentifySdk","AssentifySdk","Proxy","get","Error","AssentifyWrapper","initialize","apiKey","tenantIdentifier","instanceHash","processMrz","storeCapturedDocument","performLivenessDocument","performLivenessFace","storeImageStream","saveCapturedVideoID","saveCapturedVideoFace","ENV_CustomColor","enableDetect","enableGuide","startScanPassport","language","startScanOther","startScanOtherIDPage","startScanIDCard","kycDocumentDetailsList","flippingCard","startScanIDPage","JSON","stringify","startFaceMatch","imageUrl","showCountDown","submitData","dataMap"],"sourceRoot":"..\\..\\src","sources":["AssentifyWrapper.ts"],"mappings":"AAAA,SAASA,aAAa,EAAEC,QAAQ,QAAwB,cAAc;AAItE,MAAMC,aAAa,GACjB,kGAAkG,GAClGD,QAAQ,CAACE,MAAM,CAAC;EA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AA4C,EAACJ,QAAsB,EAACK,YAAqB,EAAC;IAClHzB,YAAY,CAAC0B,eAAe,CAACC,IAAI,CAACC,SAAS,CAACJ,sBAAsB,CAAC,EAACJ,QAAQ,EAACK,YAAY,CAAC;EAC7F,CAAC;EAED;EACCI,cAAc,EAAE,SAAAA,CAAUC,QAAgB,EAACC,aAAsB,EAAC;IAC5D/B,YAAY,CAAC6B,cAAc,CAACC,QAAQ,EAACC,aAAa,CAAC;EACzD,CAAC;EAGD;EACAC,UAAU,EAAE,SAAAA,CAAUC,OAA8B,EAAE;IACjDjC,YAAY,CAACgC,UAAU,CAACC,OAAO,CAAC;EACpC;AAMN,CAAC;AAED,eAAe7B,gBAAgB","ignoreList":[]}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Home.d.ts","sourceRoot":"","sources":["../../../../example/src/Home.tsx"],"names":[],"mappings":"AACA,OAAO,
|
|
1
|
+
{"version":3,"file":"Home.d.ts","sourceRoot":"","sources":["../../../../example/src/Home.tsx"],"names":[],"mappings":"AACA,OAAO,KAA8B,MAAM,OAAO,CAAC;AAiBnD,QAAA,MAAM,IAAI,yBAgMT,CAAC;AAEF,eAAe,IAAI,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"AssentifyWrapper.d.ts","sourceRoot":"","sources":["../../../commonjs/AssentifyWrapper.js"],"names":[],"mappings":";;;
|
|
1
|
+
{"version":3,"file":"AssentifyWrapper.d.ts","sourceRoot":"","sources":["../../../commonjs/AssentifyWrapper.js"],"names":[],"mappings":";;;IAqBc,8TAEX;IAEkB,gDAElB;IAEe,6CAEf;IAEgB,8FAEhB;IAEe,iEAEf;IAEW,wCAEX"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"AssentifyWrapper.d.ts","sourceRoot":"","sources":["../../../module/AssentifyWrapper.js"],"names":[],"mappings":";;
|
|
1
|
+
{"version":3,"file":"AssentifyWrapper.d.ts","sourceRoot":"","sources":["../../../module/AssentifyWrapper.js"],"names":[],"mappings":";;IAec,8TAEX;IAEkB,gDAElB;IAEe,6CAEf;IAEgB,8FAEhB;IAEe,iEAEf;IAEW,wCAEX"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"AssentifyWrapper.d.ts","sourceRoot":"","sources":["../../../src/AssentifyWrapper.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"AssentifyWrapper.d.ts","sourceRoot":"","sources":["../../../src/AssentifyWrapper.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,KAAK,YAAY,EAAE,MAAM,YAAY,CAAC;AAC/C,OAAO,EAAE,KAAK,kBAAkB,EAAE,MAAM,SAAS,CAAC;AAqBlD,QAAA,MAAM,gBAAgB;yBAGV,MAAM,oBACI,MAAM,gBACV,MAAM,eACP,OAAO,0BACI,OAAO,4BACL,OAAO,wBACX,OAAO,qBACV,OAAO,wBACJ,OAAO,0BACL,OAAO,oBACb,MAAM,iBACT,OAAO,gBACR,OAAO;kCAoBiB,YAAY;+BAKd,YAAY;8CAKG,kBAAkB,EAAE,YAAW,YAAY,gBAAe,OAAO;+BAK/E,MAAM,iBAAgB,OAAO;0BAMnC,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC;CAQxD,CAAC;AAEF,eAAe,gBAAgB,CAAC"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "assentify-sdk-react-native",
|
|
3
|
-
"version": "0.0.
|
|
3
|
+
"version": "0.0.3",
|
|
4
4
|
"description": "This package provides integration with Assentify's services, allowing developers to incorporate Assentify functionalities seamlessly into their applications.",
|
|
5
5
|
"main": "lib/commonjs/index",
|
|
6
6
|
"module": "lib/module/index",
|
|
@@ -90,7 +90,6 @@
|
|
|
90
90
|
"react": "*",
|
|
91
91
|
"react-native": "*",
|
|
92
92
|
"react-native-gesture-handler": "^2.0.0",
|
|
93
|
-
"react-native-permissions": "^4.0.0",
|
|
94
93
|
"react-native-reanimated": ">= 3.0.0",
|
|
95
94
|
"react-native-safe-area-context": ">= 3.0.0",
|
|
96
95
|
"react-native-screens": ">= 3.0.0"
|
package/src/AssentifyWrapper.ts
CHANGED
|
@@ -1,5 +1,4 @@
|
|
|
1
1
|
import { NativeModules, Platform, Alert, Linking } from 'react-native';
|
|
2
|
-
import { request, PERMISSIONS, RESULTS } from 'react-native-permissions';
|
|
3
2
|
import { type LanguageCode } from './Language';
|
|
4
3
|
import { type KycDocumentDetails } from './types';
|
|
5
4
|
|
|
@@ -39,72 +38,21 @@ const AssentifyWrapper = {
|
|
|
39
38
|
enableDetect?: boolean,
|
|
40
39
|
enableGuide?: boolean
|
|
41
40
|
) {
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
performLivenessDocument ?? false,
|
|
58
|
-
performLivenessFace ?? false,
|
|
59
|
-
storeImageStream ?? true,
|
|
60
|
-
saveCapturedVideoID ?? true,
|
|
61
|
-
saveCapturedVideoFace ?? true,
|
|
62
|
-
ENV_CustomColor ?? '#f5a103',
|
|
63
|
-
enableDetect ?? true,
|
|
64
|
-
enableGuide ?? true
|
|
65
|
-
);
|
|
66
|
-
} else if (
|
|
67
|
-
result === RESULTS.UNAVAILABLE ||
|
|
68
|
-
result === RESULTS.DENIED ||
|
|
69
|
-
result === RESULTS.BLOCKED
|
|
70
|
-
) {
|
|
71
|
-
Alert.alert(
|
|
72
|
-
'Warning!',
|
|
73
|
-
'Please allow your camera permission in order to proceed further',
|
|
74
|
-
[
|
|
75
|
-
{
|
|
76
|
-
text: 'Open Settings',
|
|
77
|
-
onPress: () => {
|
|
78
|
-
Linking.openSettings();
|
|
79
|
-
},
|
|
80
|
-
},
|
|
81
|
-
{
|
|
82
|
-
text: 'Cancel',
|
|
83
|
-
onPress: () => {},
|
|
84
|
-
},
|
|
85
|
-
]
|
|
86
|
-
);
|
|
87
|
-
}
|
|
88
|
-
},
|
|
89
|
-
() => {
|
|
90
|
-
Alert.alert(
|
|
91
|
-
'Warning!',
|
|
92
|
-
'Please allow your camera permission in order to proceed further',
|
|
93
|
-
[
|
|
94
|
-
{
|
|
95
|
-
text: 'Open Settings',
|
|
96
|
-
onPress: () => {
|
|
97
|
-
Linking.openSettings();
|
|
98
|
-
},
|
|
99
|
-
},
|
|
100
|
-
{
|
|
101
|
-
text: 'Cancel',
|
|
102
|
-
onPress: () => {},
|
|
103
|
-
},
|
|
104
|
-
]
|
|
105
|
-
);
|
|
106
|
-
}
|
|
107
|
-
);
|
|
41
|
+
AssentifySdk.initialize(
|
|
42
|
+
apiKey,
|
|
43
|
+
tenantIdentifier,
|
|
44
|
+
instanceHash,
|
|
45
|
+
processMrz ?? true,
|
|
46
|
+
storeCapturedDocument ?? true,
|
|
47
|
+
performLivenessDocument ?? false,
|
|
48
|
+
performLivenessFace ?? false,
|
|
49
|
+
storeImageStream ?? true,
|
|
50
|
+
saveCapturedVideoID ?? true,
|
|
51
|
+
saveCapturedVideoFace ?? true,
|
|
52
|
+
ENV_CustomColor ?? '#f5a103',
|
|
53
|
+
enableDetect ?? true,
|
|
54
|
+
enableGuide ?? true
|
|
55
|
+
);
|
|
108
56
|
},
|
|
109
57
|
|
|
110
58
|
/// Passport
|