@instadapp/avocado-base 0.0.55 → 0.0.57
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +1 -1
- package/utils/network.ts +108 -98
package/package.json
CHANGED
package/utils/network.ts
CHANGED
|
@@ -1,30 +1,18 @@
|
|
|
1
1
|
import { ethers } from "ethers";
|
|
2
|
+
import {
|
|
3
|
+
AVO_PROD_CHAIN_NAME,
|
|
4
|
+
AVO_PROD_CHAIN_ID,
|
|
5
|
+
AVO_PROD_RPC_URL,
|
|
6
|
+
AVO_PROD_EXPLORER_URL,
|
|
7
|
+
AVO_STAGING_CHAIN_NAME,
|
|
8
|
+
AVO_STAGING_CHAIN_ID,
|
|
9
|
+
AVO_STAGING_RPC_URL,
|
|
10
|
+
AVO_STAGING_EXPLORER_URL,
|
|
11
|
+
} from './avocado'
|
|
2
12
|
|
|
3
13
|
export const bridgeDisabledNetworks = [1101];
|
|
4
14
|
|
|
5
15
|
export const networks: Network[] = [
|
|
6
|
-
{
|
|
7
|
-
name: "Ethereum",
|
|
8
|
-
debankName: "eth",
|
|
9
|
-
ankrName: "eth",
|
|
10
|
-
zerionName: "ethereum",
|
|
11
|
-
chainId: 1,
|
|
12
|
-
explorerUrl: "https://etherscan.io",
|
|
13
|
-
color: "#5D5FEF",
|
|
14
|
-
get serverRpcUrl() {
|
|
15
|
-
return process.env?.MAINNET_RPC_URL || this.params.rpcUrls[0];
|
|
16
|
-
},
|
|
17
|
-
balanceResolverAddress: "0x5b7D61b389D12e1f5873d0cCEe7E675915AB5F43",
|
|
18
|
-
usdcAddress: "0xa0b86991c6218b36c1d19d4a2e9eb0ce3606eb48",
|
|
19
|
-
params: {
|
|
20
|
-
rpcUrls: ["https://rpc.ankr.com/eth"],
|
|
21
|
-
nativeCurrency: {
|
|
22
|
-
name: "Ethereum",
|
|
23
|
-
symbol: "ETH",
|
|
24
|
-
decimals: 18,
|
|
25
|
-
},
|
|
26
|
-
},
|
|
27
|
-
},
|
|
28
16
|
{
|
|
29
17
|
name: "Polygon",
|
|
30
18
|
debankName: "matic",
|
|
@@ -71,6 +59,48 @@ export const networks: Network[] = [
|
|
|
71
59
|
rpcUrls: ["https://arb1.arbitrum.io/rpc"],
|
|
72
60
|
},
|
|
73
61
|
},
|
|
62
|
+
{
|
|
63
|
+
name: "Ethereum",
|
|
64
|
+
debankName: "eth",
|
|
65
|
+
ankrName: "eth",
|
|
66
|
+
zerionName: "ethereum",
|
|
67
|
+
chainId: 1,
|
|
68
|
+
explorerUrl: "https://etherscan.io",
|
|
69
|
+
color: "#5D5FEF",
|
|
70
|
+
get serverRpcUrl() {
|
|
71
|
+
return process.env?.MAINNET_RPC_URL || this.params.rpcUrls[0];
|
|
72
|
+
},
|
|
73
|
+
balanceResolverAddress: "0x5b7D61b389D12e1f5873d0cCEe7E675915AB5F43",
|
|
74
|
+
usdcAddress: "0xa0b86991c6218b36c1d19d4a2e9eb0ce3606eb48",
|
|
75
|
+
params: {
|
|
76
|
+
rpcUrls: ["https://rpc.ankr.com/eth"],
|
|
77
|
+
nativeCurrency: {
|
|
78
|
+
name: "Ethereum",
|
|
79
|
+
symbol: "ETH",
|
|
80
|
+
decimals: 18,
|
|
81
|
+
},
|
|
82
|
+
},
|
|
83
|
+
},
|
|
84
|
+
{
|
|
85
|
+
name: 'Base',
|
|
86
|
+
chainId: 8453,
|
|
87
|
+
color: '#1E2024',
|
|
88
|
+
explorerUrl: 'https://basescan.org',
|
|
89
|
+
get serverRpcUrl() {
|
|
90
|
+
return process.env?.BASE_RPC_URL || this.params.rpcUrls[0];
|
|
91
|
+
},
|
|
92
|
+
usdcAddress: '0xd9aAEc86B65D86f6A7B5B1b0c42FFA531710b6CA',
|
|
93
|
+
balanceResolverAddress: '0x23c8EAb8a4373dD16b0947Ebe8bf76Ff7A49d13C',
|
|
94
|
+
params: {
|
|
95
|
+
rpcUrls: ['https://rpc.ankr.com/base'],
|
|
96
|
+
chainName: "Base",
|
|
97
|
+
nativeCurrency: {
|
|
98
|
+
name: "Ethereum",
|
|
99
|
+
symbol: "ETH",
|
|
100
|
+
decimals: 18,
|
|
101
|
+
},
|
|
102
|
+
}
|
|
103
|
+
},
|
|
74
104
|
{
|
|
75
105
|
name: "Optimism",
|
|
76
106
|
debankName: "op",
|
|
@@ -95,26 +125,23 @@ export const networks: Network[] = [
|
|
|
95
125
|
},
|
|
96
126
|
},
|
|
97
127
|
{
|
|
98
|
-
name: "
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
usdcAddress: "0xb97ef9ef8734c71904d8002f8b6bc66dd9c48a6e",
|
|
105
|
-
balanceResolverAddress: "0x63009f31D054E0ac9F321Cf0D642375236A4Bf1E",
|
|
106
|
-
explorerUrl: "https://snowtrace.io",
|
|
128
|
+
name: "Polygon zkEVM",
|
|
129
|
+
chainId: 1101,
|
|
130
|
+
color: "#8544f6",
|
|
131
|
+
explorerUrl: "https://zkevm.polygonscan.com",
|
|
132
|
+
balanceResolverAddress: "0x48D1Fa5Ee6691a1E0B45d2B515650997BEA27a01",
|
|
133
|
+
usdcAddress: "0xa8ce8aee21bc2a48a5ef670afcc9274c7bbbc035",
|
|
107
134
|
get serverRpcUrl() {
|
|
108
|
-
return process.env?.
|
|
135
|
+
return process.env?.POLYGON_ZKEVM_RPC_URL || this.params.rpcUrls[0];
|
|
109
136
|
},
|
|
110
137
|
params: {
|
|
111
|
-
chainName: "
|
|
138
|
+
chainName: "polygon zkEVM",
|
|
139
|
+
rpcUrls: ["https://zkevm-rpc.com"],
|
|
112
140
|
nativeCurrency: {
|
|
113
|
-
name: "
|
|
114
|
-
symbol: "
|
|
141
|
+
name: "Ethereum",
|
|
142
|
+
symbol: "ETH",
|
|
115
143
|
decimals: 18,
|
|
116
144
|
},
|
|
117
|
-
rpcUrls: ["https://rpc.ankr.com/avalanche"],
|
|
118
145
|
},
|
|
119
146
|
},
|
|
120
147
|
{
|
|
@@ -140,6 +167,51 @@ export const networks: Network[] = [
|
|
|
140
167
|
},
|
|
141
168
|
},
|
|
142
169
|
},
|
|
170
|
+
{
|
|
171
|
+
name: "Avalanche",
|
|
172
|
+
debankName: "avax",
|
|
173
|
+
ankrName: "avalanche",
|
|
174
|
+
zerionName: "avalanche",
|
|
175
|
+
color: "#EB5757",
|
|
176
|
+
chainId: 43114,
|
|
177
|
+
usdcAddress: "0xb97ef9ef8734c71904d8002f8b6bc66dd9c48a6e",
|
|
178
|
+
balanceResolverAddress: "0x63009f31D054E0ac9F321Cf0D642375236A4Bf1E",
|
|
179
|
+
explorerUrl: "https://snowtrace.io",
|
|
180
|
+
get serverRpcUrl() {
|
|
181
|
+
return process.env?.AVALANCHE_RPC_URL || this.params.rpcUrls[0];
|
|
182
|
+
},
|
|
183
|
+
params: {
|
|
184
|
+
chainName: "Avalanche Network",
|
|
185
|
+
nativeCurrency: {
|
|
186
|
+
name: "Avalanche",
|
|
187
|
+
symbol: "AVAX",
|
|
188
|
+
decimals: 18,
|
|
189
|
+
},
|
|
190
|
+
rpcUrls: ["https://rpc.ankr.com/avalanche"],
|
|
191
|
+
},
|
|
192
|
+
},
|
|
193
|
+
{
|
|
194
|
+
name: "Fantom",
|
|
195
|
+
chainId: 250,
|
|
196
|
+
zerionName: "fantom",
|
|
197
|
+
explorerUrl: "https://ftmscan.com",
|
|
198
|
+
ankrName: "fantom",
|
|
199
|
+
color: "#1969ff",
|
|
200
|
+
get serverRpcUrl() {
|
|
201
|
+
return process.env?.FANTOM_RPC_URL || this.params.rpcUrls[0];
|
|
202
|
+
},
|
|
203
|
+
usdcAddress: "0x04068da6c83afcfa0e13ba15a6696662335d5b75",
|
|
204
|
+
balanceResolverAddress: "0x929376c77a2fb8152375a089a4fccf84ff481479",
|
|
205
|
+
params: {
|
|
206
|
+
rpcUrls: ["https://rpc.ankr.com/fantom"],
|
|
207
|
+
chainName: "Fantom",
|
|
208
|
+
nativeCurrency: {
|
|
209
|
+
name: "Fantom",
|
|
210
|
+
symbol: "FTM",
|
|
211
|
+
decimals: 18,
|
|
212
|
+
},
|
|
213
|
+
},
|
|
214
|
+
},
|
|
143
215
|
{
|
|
144
216
|
name: "Gnosis",
|
|
145
217
|
debankName: "xdai",
|
|
@@ -162,26 +234,6 @@ export const networks: Network[] = [
|
|
|
162
234
|
},
|
|
163
235
|
},
|
|
164
236
|
},
|
|
165
|
-
{
|
|
166
|
-
name: "Polygon zkEVM",
|
|
167
|
-
chainId: 1101,
|
|
168
|
-
color: "#8544f6",
|
|
169
|
-
explorerUrl: "https://zkevm.polygonscan.com",
|
|
170
|
-
balanceResolverAddress: "0x48D1Fa5Ee6691a1E0B45d2B515650997BEA27a01",
|
|
171
|
-
usdcAddress: "0xa8ce8aee21bc2a48a5ef670afcc9274c7bbbc035",
|
|
172
|
-
get serverRpcUrl() {
|
|
173
|
-
return process.env?.POLYGON_ZKEVM_RPC_URL || this.params.rpcUrls[0];
|
|
174
|
-
},
|
|
175
|
-
params: {
|
|
176
|
-
chainName: "polygon zkEVM",
|
|
177
|
-
rpcUrls: ["https://zkevm-rpc.com"],
|
|
178
|
-
nativeCurrency: {
|
|
179
|
-
name: "Ethereum",
|
|
180
|
-
symbol: "ETH",
|
|
181
|
-
decimals: 18,
|
|
182
|
-
},
|
|
183
|
-
},
|
|
184
|
-
},
|
|
185
237
|
{
|
|
186
238
|
name: "Aurora",
|
|
187
239
|
chainId: 1313161554,
|
|
@@ -203,48 +255,6 @@ export const networks: Network[] = [
|
|
|
203
255
|
},
|
|
204
256
|
},
|
|
205
257
|
},
|
|
206
|
-
{
|
|
207
|
-
name: "Fantom",
|
|
208
|
-
chainId: 250,
|
|
209
|
-
zerionName: "fantom",
|
|
210
|
-
explorerUrl: "https://ftmscan.com",
|
|
211
|
-
ankrName: "fantom",
|
|
212
|
-
color: "#1969ff",
|
|
213
|
-
get serverRpcUrl() {
|
|
214
|
-
return process.env?.FANTOM_RPC_URL || this.params.rpcUrls[0];
|
|
215
|
-
},
|
|
216
|
-
usdcAddress: "0x04068da6c83afcfa0e13ba15a6696662335d5b75",
|
|
217
|
-
balanceResolverAddress: "0x929376c77a2fb8152375a089a4fccf84ff481479",
|
|
218
|
-
params: {
|
|
219
|
-
rpcUrls: ["https://rpc.ankr.com/fantom"],
|
|
220
|
-
chainName: "Fantom",
|
|
221
|
-
nativeCurrency: {
|
|
222
|
-
name: "Fantom",
|
|
223
|
-
symbol: "FTM",
|
|
224
|
-
decimals: 18,
|
|
225
|
-
},
|
|
226
|
-
},
|
|
227
|
-
},
|
|
228
|
-
{
|
|
229
|
-
name: 'Base',
|
|
230
|
-
chainId: 8453,
|
|
231
|
-
color: '#1E2024',
|
|
232
|
-
explorerUrl: 'https://basescan.org',
|
|
233
|
-
get serverRpcUrl() {
|
|
234
|
-
return process.env?.BASE_RPC_URL || this.params.rpcUrls[0];
|
|
235
|
-
},
|
|
236
|
-
usdcAddress: '0xd9aAEc86B65D86f6A7B5B1b0c42FFA531710b6CA',
|
|
237
|
-
balanceResolverAddress: '0x23c8EAb8a4373dD16b0947Ebe8bf76Ff7A49d13C',
|
|
238
|
-
params: {
|
|
239
|
-
rpcUrls: ['https://rpc.ankr.com/base'],
|
|
240
|
-
chainName: "Base",
|
|
241
|
-
nativeCurrency: {
|
|
242
|
-
name: "Ethereum",
|
|
243
|
-
symbol: "ETH",
|
|
244
|
-
decimals: 18,
|
|
245
|
-
},
|
|
246
|
-
}
|
|
247
|
-
},
|
|
248
258
|
{
|
|
249
259
|
name: AVO_PROD_CHAIN_NAME,
|
|
250
260
|
chainId: AVO_PROD_CHAIN_ID,
|