forked from realaskaer/BeraMachine
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathfunctions.py
142 lines (86 loc) · 5.58 KB
/
functions.py
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
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
from modules import *
from utils.networks import *
def get_client(account_number, private_key, proxy, email_address=None, email_password=None) -> Client:
return Client(account_number, private_key, proxy, email_address, email_password)
def get_network_by_chain_id(chain_id):
return {
48: BeraChainRPC
}[chain_id]
async def mint_berachain_tokens(account_number, private_key, proxy, *_):
worker = Faucet(get_client(account_number, private_key, proxy))
return await worker.claim_berachain_tokens()
async def swap_bex(account_number, private_key, proxy, *_, **kwargs):
worker = BeraChain(get_client(account_number, private_key, proxy))
return await worker.swap_bex(**kwargs)
async def swap_btc_bex(account_number, private_key, proxy, *_, **kwargs):
worker = Custom(get_client(account_number, private_key, proxy))
return await worker.swap_btc_bex(**kwargs)
async def swap_eth_bex(account_number, private_key, proxy, *_, **kwargs):
worker = Custom(get_client(account_number, private_key, proxy))
return await worker.swap_eth_bex(**kwargs)
async def swap_honey_bex(account_number, private_key, proxy, *_, **kwargs):
worker = Custom(get_client(account_number, private_key, proxy))
return await worker.swap_honey_bex(**kwargs)
async def swap_stgusdc_bex(account_number, private_key, proxy, *_, **kwargs):
worker = Custom(get_client(account_number, private_key, proxy))
return await worker.swap_stgusdc_bex(**kwargs)
async def add_liqiudity_bex_bera_usdc(account_number, private_key, proxy, *_, **kwargs):
worker = BeraChain(get_client(account_number, private_key, proxy))
return await worker.add_liquidity_bex(**kwargs)
async def add_liqiudity_bex_honey_mim(account_number, private_key, proxy, *_, **kwargs):
worker = BeraChain(get_client(account_number, private_key, proxy))
return await worker.add_liquidity_bex_mim(**kwargs)
async def supply_honey_bend(account_number, private_key, proxy, *_, **kwargs):
worker = BeraChain(get_client(account_number, private_key, proxy))
return await worker.supply_honey_bend(**kwargs)
async def deposit_honey_berps(account_number, private_key, proxy, *_, **kwargs):
worker = BeraChain(get_client(account_number, private_key, proxy))
return await worker.deposit_honey_berps_vault(**kwargs)
async def claim_bgt_on_berps(account_number, private_key, proxy, *_, **kwargs):
worker = BeraChain(get_client(account_number, private_key, proxy))
return await worker.claim_bgt_on_berps(**kwargs)
async def delegate_bgt_on_station(account_number, private_key, proxy, *_, **kwargs):
worker = BeraChain(get_client(account_number, private_key, proxy))
return await worker.delegate_bgt_on_station(**kwargs)
async def vote_bgt_on_station(account_number, private_key, proxy, *_, **kwargs):
worker = BeraChain(get_client(account_number, private_key, proxy))
return await worker.vote_bgt_on_station(**kwargs)
async def deploy_contract(account_number, private_key, proxy, *_, **kwargs):
worker = BeraChain(get_client(account_number, private_key, proxy))
return await worker.deploy_contract(**kwargs)
async def supply_btc_bend(account_number, private_key, proxy, *_, **kwargs):
worker = BeraChain(get_client(account_number, private_key, proxy))
return await worker.supply_btc_bend(**kwargs)
async def supply_eth_bend(account_number, private_key, proxy, *_, **kwargs):
worker = BeraChain(get_client(account_number, private_key, proxy))
return await worker.supply_eth_bend(**kwargs)
async def withdraw_honey_bend(account_number, private_key, proxy, *_, **kwargs):
worker = BeraChain(get_client(account_number, private_key, proxy))
return await worker.withdraw_honey_bend(**kwargs)
async def withdraw_btc_bend(account_number, private_key, proxy, *_, **kwargs):
worker = BeraChain(get_client(account_number, private_key, proxy))
return await worker.withdraw_btc_bend(**kwargs)
async def withdraw_eth_bend(account_number, private_key, proxy, *_, **kwargs):
worker = BeraChain(get_client(account_number, private_key, proxy))
return await worker.withdraw_eth_bend(**kwargs)
async def mint_honey(account_number, private_key, proxy, *_, **kwargs):
worker = BeraChain(get_client(account_number, private_key, proxy))
return await worker.swap_honey(**kwargs)
async def mint_booga_ticket(account_number, private_key, proxy, *_, **kwargs):
worker = BeraChain(get_client(account_number, private_key, proxy))
return await worker.mint_booga_ticket(**kwargs)
async def mint_bera_red(account_number, private_key, proxy, *_, **kwargs):
worker = BeraChain(get_client(account_number, private_key, proxy))
return await worker.mint_bera_red(**kwargs)
async def mint_valhala_nft(account_number, private_key, proxy, *_, **kwargs):
worker = BeraChain(get_client(account_number, private_key, proxy))
return await worker.mint_valhala_nft(**kwargs)
async def mint_domain(account_number, private_key, proxy, *_, **kwargs):
worker = BeraChain(get_client(account_number, private_key, proxy))
return await worker.mint_domain(**kwargs)
async def claim_galxe_points(account_number, private_key, proxy, email_address, email_password, **kwargs):
worker = Galxe(get_client(account_number, private_key, proxy, email_address, email_password))
return await worker.claim_galxe_points_berachain_faucet(**kwargs)
async def claim_galxe_campaign_points(account_number, private_key, proxy, email_address, email_password, **kwargs):
worker = Galxe(get_client(account_number, private_key, proxy, email_address, email_password))
return await worker.claim_bera_campaign_points()