-
Notifications
You must be signed in to change notification settings - Fork 0
/
index.html
31 lines (30 loc) · 1.01 KB
/
index.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Login using sawo</title>
<link rel="stylesheet" href="style.css">
</head>
<body>
<div id="sawo-container" style="height: 300px; width: 300px;"></div>
<script src="https://websdk.sawolabs.com/sawo.min.js"></script>
<script>
var config = {
// should be same as the id of the container created on 3rd step
containerID: "sawo-container",
// can be one of 'email' or 'phone_number_sms'
identifierType: "phone_number_sms",
// Add the API key copied from 2nd step
apiKey: "a6e6d1c0-b14d-45ee-8914-1a0a34ec077b",
// Add a callback here to handle the payload sent by sdk
onSuccess: (payload) => {
window.location.href="mainpage.html"
},
};
var sawo = new Sawo(config);
sawo.showForm();
</script>
</body>
</html>