-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathapp.js
30 lines (23 loc) · 871 Bytes
/
app.js
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
// Function to authenticate using license key
async function authenticateLicenseKey(licenseKey) {
const url = `https://keyauth.win/api/v1/`;
const body = {
type: 'login',
key: KEYAUTH-DFFDFSFSFSDFSFSDF,
ownerid: 'AQy6nxcoDL',
app: 'Panel',
secret: '606ac307e802354e7bef2b301b24690e65937e217f1d26d68aa20d57c748bc01'
};
const response = await fetch(url, {
method: 'POST',
headers: { 'Content-Type': 'application/json' },
body: JSON.stringify(body)
});
const result = await response.json();
if (result.success) {
document.getElementById('message').innerHTML = "Login successful!";
// Add further logic after successful login
} else {
document.getElementById('message').innerHTML = "Login failed: " + result.message;
}
}