|
|
|
@ -229,6 +229,23 @@ class GenericCommands(object):
|
|
|
|
|
rtrn = caller.nuke_ads()
|
|
|
|
|
msg(dumps(rtrn))
|
|
|
|
|
|
|
|
|
|
class wallet(object):
|
|
|
|
|
@staticmethod
|
|
|
|
|
def run(cmd, spl, length, authed, msg, agora, tx, ux, xmr, caller):
|
|
|
|
|
if xmr:
|
|
|
|
|
rtrn_xmr = caller.wallet_balance_xmr()
|
|
|
|
|
if not rtrn_xmr["success"]:
|
|
|
|
|
msg("Error getting XMR wallet details.")
|
|
|
|
|
return
|
|
|
|
|
balance_xmr = rtrn_xmr["response"]["data"]["total"]["balance"]
|
|
|
|
|
msg(f"XMR wallet balance: {balance_xmr}")
|
|
|
|
|
rtrn_btc = caller.wallet_balance()
|
|
|
|
|
if not rtrn_btc["success"]:
|
|
|
|
|
msg("Error getting BTC wallet details.")
|
|
|
|
|
return
|
|
|
|
|
balance_btc = rtrn_btc["response"]["data"]["total"]["balance"]
|
|
|
|
|
msg(f"BTC wallet balance: {balance_btc}")
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
class IRCCommands(object):
|
|
|
|
|
class atrades(object):
|
|
|
|
@ -509,25 +526,23 @@ class IRCCommands(object):
|
|
|
|
|
def run(cmd, spl, length, authed, msg, agora, tx, ux):
|
|
|
|
|
GenericCommands.nuke.run(cmd, spl, length, authed, msg, agora, tx, ux, tx.lbtc)
|
|
|
|
|
|
|
|
|
|
class wallet(object):
|
|
|
|
|
name = "wallet"
|
|
|
|
|
class awallet(object):
|
|
|
|
|
authed = True
|
|
|
|
|
name = "awallet"
|
|
|
|
|
helptext = "Get Agora wallet balances."
|
|
|
|
|
|
|
|
|
|
@staticmethod
|
|
|
|
|
def run(cmd, spl, length, authed, msg, agora, tx, ux):
|
|
|
|
|
rtrn_xmr = agora.agora.wallet_balance_xmr()
|
|
|
|
|
if not rtrn_xmr["success"]:
|
|
|
|
|
msg("Error getting XMR wallet details.")
|
|
|
|
|
return
|
|
|
|
|
rtrn_btc = agora.agora.wallet_balance()
|
|
|
|
|
if not rtrn_btc["success"]:
|
|
|
|
|
msg("Error getting BTC wallet details.")
|
|
|
|
|
return
|
|
|
|
|
balance_xmr = rtrn_xmr["response"]["data"]["total"]["balance"]
|
|
|
|
|
balance_btc = rtrn_btc["response"]["data"]["total"]["balance"]
|
|
|
|
|
msg(f"XMR wallet balance: {balance_xmr}")
|
|
|
|
|
msg(f"BTC wallet balance: {balance_btc}")
|
|
|
|
|
GenericCommands.wallet.run(cmd, spl, length, authed, msg, agora, tx, ux, True, agora.agora)
|
|
|
|
|
|
|
|
|
|
class lwallet(object):
|
|
|
|
|
authed = True
|
|
|
|
|
name = "lwallet"
|
|
|
|
|
helptext = "Get LBTC wallet balances."
|
|
|
|
|
|
|
|
|
|
@staticmethod
|
|
|
|
|
def run(cmd, spl, length, authed, msg, agora, tx, ux):
|
|
|
|
|
GenericCommands.wallet.run(cmd, spl, length, authed, msg, agora, tx, ux, False, tx.lbtc.lbtc)
|
|
|
|
|
|
|
|
|
|
class apubads(object):
|
|
|
|
|
authed = True
|
|
|
|
|