| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
1 parent e9f728c commit ff42c04
3 files changed
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -72,6 +72,7 @@ You don't need to add any code to initalize. KeyAuth will initalize when the ins | |||
| 72 | 72 | ## **Display application information** | |
| 73 | 73 | ||
| 74 | 74 | ```py | |
| 75 | + keyauthapp.fetchStats() | ||
| 75 | 76 | print(f""" | |
| 76 | 77 | App data: | |
| 77 | 78 | Number of users: {keyauthapp.app_data.numUsers} | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -96,7 +96,9 @@ def init(self): | |||
| 96 | 96 | ||
| 97 | 97 | self.sessionid = json["sessionid"] | |
| 98 | 98 | self.initialized = True | |
| 99 | - self.__load_app_data(json["appinfo"]) | ||
| 99 | + | ||
| 100 | + if json["newSession"]: | ||
| 101 | + time.sleep(0.1) | ||
| 100 | 102 | ||
| 101 | 103 | def register(self, user, password, license, hwid=None): | |
| 102 | 104 | self.checkinit() | |
@@ -408,7 +410,24 @@ def fetchOnline(self): | |||
| 408 | 410 | return json["users"] | |
| 409 | 411 | else: | |
| 410 | 412 | return None | |
| 413 | + | ||
| 414 | + def fetchStats(self): | ||
| 415 | + self.checkinit() | ||
| 411 | 416 | ||
| 417 | + post_data = { | ||
| 418 | + "type": "fetchStats", | ||
| 419 | + "sessionid": self.sessionid, | ||
| 420 | + "name": self.name, | ||
| 421 | + "ownerid": self.ownerid | ||
| 422 | + } | ||
| 423 | + | ||
| 424 | + response = self.__do_request(post_data) | ||
| 425 | + | ||
| 426 | + json = jsond.loads(response) | ||
| 427 | + | ||
| 428 | + if json["success"]: | ||
| 429 | + self.__load_app_data(json["appinfo"]) | ||
| 430 | + | ||
| 412 | 431 | def chatGet(self, channel): | |
| 413 | 432 | self.checkinit() | |
| 414 | 433 | ||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -46,22 +46,13 @@ def getchecksum(): | |||
| 46 | 46 | ||
| 47 | 47 | ||
| 48 | 48 | keyauthapp = api( | |
| 49 | - name = "", #App name (Manage Applications --> Application name) | ||
| 50 | - ownerid = "", #Owner ID (Account-Settings --> OwnerID) | ||
| 51 | - secret = "", #App secret(Manage Applications --> App credentials code) | ||
| 49 | + name = "", | ||
| 50 | + ownerid = "", | ||
| 51 | + secret = "", | ||
| 52 | 52 | version = "1.0", | |
| 53 | 53 | hash_to_check = getchecksum() | |
| 54 | 54 | ) | |
| 55 | 55 | ||
| 56 | - print(f""" | ||
| 57 | - App data: | ||
| 58 | - Number of users: {keyauthapp.app_data.numUsers} | ||
| 59 | - Number of online users: {keyauthapp.app_data.onlineUsers} | ||
| 60 | - Number of keys: {keyauthapp.app_data.numKeys} | ||
| 61 | - Application Version: {keyauthapp.app_data.app_ver} | ||
| 62 | - Customer panel link: {keyauthapp.app_data.customer_panel} | ||
| 63 | - """) | ||
| 64 | - | ||
| 65 | 56 | def answer(): | |
| 66 | 57 | try: | |
| 67 | 58 | print("""1.Login | |
| Back | FazBrowse Home | New Git URL |
0 commit comments