add mirai

This commit is contained in:
2021-05-09 17:19:10 +08:00
parent 01ed67f8f4
commit 4cb10597c5
5 changed files with 271 additions and 4 deletions

View File

@@ -56,6 +56,7 @@ class settings:
self._main, d['botOwnerList']) if 'botOwnerList' in d and d['botOwnerList'] != '' else BotOwnerList(self._main)
self._miraiApiHTTPServer = d['miraiApiHTTPServer'] if 'miraiApiHTTPServer' in d and d['miraiApiHTTPServer'] != '' else None
self._miraiApiHTTPAuthKey = d['miraiApiHTTPAuthKey'] if 'miraiApiHTTPAuthKey' in d and d['miraiApiHTTPAuthKey'] != '' else None
self._miraiApiQQ = int(d['miraiApiQQ']) if 'miraiApiQQ' in d and d['miraiApiQQ'].isnumeric() else None
@property
def token(self) -> str:
@@ -113,6 +114,10 @@ class settings:
def miraiApiHTTPAuthKey(self) -> str:
return self._miraiApiHTTPAuthKey
@property
def miraiApiQQ(self) -> int:
return self._miraiApiQQ
class commandline:
def __init__(self, commandline: List[str] = None):