prembly-react-kyc 1.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.
package/README.md ADDED
@@ -0,0 +1,75 @@
1
+ # react-identity-kyc
2
+
3
+ >IdentityPass ReactJS Verification library
4
+
5
+ >INTRODUCING PREMBLY 2.0
6
+
7
+ [![NPM](https://img.shields.io/npm/v/react-identity-kyc.svg)](https://www.npmjs.com/package/react-identity-kyc) [![JavaScript Style Guide](https://img.shields.io/badge/code_style-standard-brightgreen.svg)](https://standardjs.com)
8
+
9
+ ## Install
10
+
11
+ ```bash
12
+ npm install --save react-identity-kyc
13
+ ```
14
+
15
+ ## Usage
16
+
17
+ ```jsx
18
+ import React from 'react'
19
+ import useIdentityPayKYC from 'react-identity-kyc'
20
+
21
+ const App = () => {
22
+ const config = {
23
+ first_name:"test",
24
+ last_name:"test",
25
+ email:"kayode@myidentitypass.com",
26
+ merchant_key:"",
27
+ user_ref:"a unique ref for your user",
28
+ is_test:false, //set this to through for a test
29
+ config_id:"<configuration ID retrieve from your widget settings", //optional
30
+ callback:(response)=>console.log(response)
31
+ }
32
+ const verifyWithIdentity = useIdentityPayKYC(config)
33
+
34
+ return <button onClick={verifyWithIdentity} >Click to Test</button>
35
+ }
36
+ export default App
37
+
38
+ ```
39
+
40
+
41
+ ```jsx
42
+ RESPONSES
43
+
44
+ 1. Failed response:
45
+ {
46
+ code: "E01",
47
+ message: "Message goes here",
48
+ status: "failed"
49
+ }
50
+
51
+ 2. Cancelled
52
+ {
53
+ code: "E02",
54
+ message: "Verification Canceled",
55
+ status: "failed"
56
+ }
57
+ 3. Success
58
+ {
59
+ code: "00",
60
+ status: "success",
61
+ message: "Verification Successful",
62
+ data:{
63
+ //Verification data goes here
64
+ // kindly check official documentation for data structure for each channel
65
+ //https://developer.myidentitypass.com
66
+ },
67
+ channel:"Channel goes here", e.g BVN,NIN and many more
68
+
69
+ }
70
+ ```
71
+
72
+ ## License
73
+
74
+ MIT © [kayode001(Kayode Olayiwola)](https://github.com/kayode001)
75
+ "# react-identity-kyc"