@defillama/sdk 2.3.48 → 2.3.51
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/build/abi/multicall.d.ts
CHANGED
|
@@ -6,6 +6,14 @@ export declare const MULTICALL_ADDRESS_GOERLI = "0x77dca2c955b15e9de4dbbcf1246b4
|
|
|
6
6
|
export declare const MULTICALL_ADDRESS_POLYGON = "0x95028E5B8a734bb7E2071F96De89BABe75be9C8E";
|
|
7
7
|
export declare const MULTICALL_ADDRESS_BSC = "0x1Ee38d535d541c55C9dae27B12edf090C608E6Fb";
|
|
8
8
|
export declare const MULTICALL_ADDRESS_FANTOM = "0xb828C456600857abd4ed6C32FAcc607bD0464F4F";
|
|
9
|
+
export declare const MULTICALL_ADDRESS_XDAI = "0xb5b692a88BDFc81ca69dcB1d924f59f0413A602a";
|
|
10
|
+
export declare const MULTICALL_ADDRESS_HECO = "0xc9a9F768ebD123A00B52e7A0E590df2e9E998707";
|
|
11
|
+
export declare const MULTICALL_ADDRESS_HARMONY = "0xFE4980f62D708c2A84D3929859Ea226340759320";
|
|
12
|
+
export declare const MULTICALL_ADDRESS_ARBITRUM = "0x842eC2c7D803033Edf55E478F461FC547Bc54EB2";
|
|
13
|
+
export declare const MULTICALL_ADDRESS_AVAX = "0xdf2122931FEb939FB8Cf4e67Ea752D1125e18858";
|
|
14
|
+
export declare const MULTICALL_ADDRESS_MOONRIVER = "0xe05349d6fE12602F6084550995B247a5C80C0E2C";
|
|
15
|
+
export declare const MULTICALL_ADDRESS_AURORA = "0xe0e3887b158F7F9c80c835a61ED809389BC08d1b";
|
|
16
|
+
export declare const MULTICALL_ADDRESS_OPTIMISM = "0xD0E99f15B24F265074747B2A1444eB02b9E30422";
|
|
9
17
|
export declare const AGGREGATE_SELECTOR = "0x252dba42";
|
|
10
18
|
export default function makeMultiCall(functionABI: any, calls: {
|
|
11
19
|
contract: string;
|
package/build/abi/multicall.js
CHANGED
|
@@ -39,7 +39,7 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
39
39
|
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
40
40
|
};
|
|
41
41
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
42
|
-
exports.AGGREGATE_SELECTOR = exports.MULTICALL_ADDRESS_FANTOM = exports.MULTICALL_ADDRESS_BSC = exports.MULTICALL_ADDRESS_POLYGON = exports.MULTICALL_ADDRESS_GOERLI = exports.MULTICALL_ADDRESS_RINKEBY = exports.MULTICALL_ADDRESS_KOVAN = exports.MULTICALL_ADDRESS_MAINNET = void 0;
|
|
42
|
+
exports.AGGREGATE_SELECTOR = exports.MULTICALL_ADDRESS_OPTIMISM = exports.MULTICALL_ADDRESS_AURORA = exports.MULTICALL_ADDRESS_MOONRIVER = exports.MULTICALL_ADDRESS_AVAX = exports.MULTICALL_ADDRESS_ARBITRUM = exports.MULTICALL_ADDRESS_HARMONY = exports.MULTICALL_ADDRESS_HECO = exports.MULTICALL_ADDRESS_XDAI = exports.MULTICALL_ADDRESS_FANTOM = exports.MULTICALL_ADDRESS_BSC = exports.MULTICALL_ADDRESS_POLYGON = exports.MULTICALL_ADDRESS_GOERLI = exports.MULTICALL_ADDRESS_RINKEBY = exports.MULTICALL_ADDRESS_KOVAN = exports.MULTICALL_ADDRESS_MAINNET = void 0;
|
|
43
43
|
var ethers_1 = require("ethers");
|
|
44
44
|
var utils_1 = require("ethers/lib/utils");
|
|
45
45
|
var general_1 = require("../general");
|
|
@@ -51,6 +51,14 @@ exports.MULTICALL_ADDRESS_GOERLI = "0x77dca2c955b15e9de4dbbcf1246b4b85b651e50e";
|
|
|
51
51
|
exports.MULTICALL_ADDRESS_POLYGON = "0x95028E5B8a734bb7E2071F96De89BABe75be9C8E";
|
|
52
52
|
exports.MULTICALL_ADDRESS_BSC = "0x1Ee38d535d541c55C9dae27B12edf090C608E6Fb";
|
|
53
53
|
exports.MULTICALL_ADDRESS_FANTOM = "0xb828C456600857abd4ed6C32FAcc607bD0464F4F";
|
|
54
|
+
exports.MULTICALL_ADDRESS_XDAI = "0xb5b692a88BDFc81ca69dcB1d924f59f0413A602a";
|
|
55
|
+
exports.MULTICALL_ADDRESS_HECO = "0xc9a9F768ebD123A00B52e7A0E590df2e9E998707";
|
|
56
|
+
exports.MULTICALL_ADDRESS_HARMONY = "0xFE4980f62D708c2A84D3929859Ea226340759320";
|
|
57
|
+
exports.MULTICALL_ADDRESS_ARBITRUM = "0x842eC2c7D803033Edf55E478F461FC547Bc54EB2";
|
|
58
|
+
exports.MULTICALL_ADDRESS_AVAX = "0xdf2122931FEb939FB8Cf4e67Ea752D1125e18858";
|
|
59
|
+
exports.MULTICALL_ADDRESS_MOONRIVER = "0xe05349d6fE12602F6084550995B247a5C80C0E2C";
|
|
60
|
+
exports.MULTICALL_ADDRESS_AURORA = "0xe0e3887b158F7F9c80c835a61ED809389BC08d1b";
|
|
61
|
+
exports.MULTICALL_ADDRESS_OPTIMISM = "0xD0E99f15B24F265074747B2A1444eB02b9E30422";
|
|
54
62
|
exports.AGGREGATE_SELECTOR = "0x252dba42";
|
|
55
63
|
function makeMultiCall(functionABI, calls, chain, block) {
|
|
56
64
|
return __awaiter(this, void 0, void 0, function () {
|
|
@@ -204,6 +212,22 @@ function multicallAddress(chainId) {
|
|
|
204
212
|
return exports.MULTICALL_ADDRESS_BSC;
|
|
205
213
|
case 250:
|
|
206
214
|
return exports.MULTICALL_ADDRESS_FANTOM;
|
|
215
|
+
case 100:
|
|
216
|
+
return exports.MULTICALL_ADDRESS_XDAI;
|
|
217
|
+
case 128:
|
|
218
|
+
return exports.MULTICALL_ADDRESS_HECO;
|
|
219
|
+
case 1666600000:
|
|
220
|
+
return exports.MULTICALL_ADDRESS_HARMONY;
|
|
221
|
+
case 42161:
|
|
222
|
+
return exports.MULTICALL_ADDRESS_ARBITRUM;
|
|
223
|
+
case 43114:
|
|
224
|
+
return exports.MULTICALL_ADDRESS_AVAX;
|
|
225
|
+
case 1285:
|
|
226
|
+
return exports.MULTICALL_ADDRESS_MOONRIVER;
|
|
227
|
+
case 1313161554:
|
|
228
|
+
return exports.MULTICALL_ADDRESS_AURORA;
|
|
229
|
+
case 10:
|
|
230
|
+
return exports.MULTICALL_ADDRESS_OPTIMISM;
|
|
207
231
|
default:
|
|
208
232
|
return null;
|
|
209
233
|
}
|
|
@@ -46,6 +46,7 @@ export declare const chainToCoingeckoId: {
|
|
|
46
46
|
metis: string;
|
|
47
47
|
telos: string;
|
|
48
48
|
moonbeam: string;
|
|
49
|
+
velas: string;
|
|
49
50
|
};
|
|
50
51
|
export default function (rawBalances: Balances, timestamp: number | "now", verbose?: boolean, knownTokenPrices?: TokenPrices, getCoingeckoLock?: GetCoingeckoLog, coingeckoMaxRetries?: number): Promise<{
|
|
51
52
|
usdTvl: number;
|
|
@@ -108,6 +108,7 @@ exports.chainToCoingeckoId = {
|
|
|
108
108
|
metis: "metis-andromeda",
|
|
109
109
|
telos: "telos",
|
|
110
110
|
moonbeam: "moonbeam",
|
|
111
|
+
velas: "velas",
|
|
111
112
|
};
|
|
112
113
|
var chains = Object.keys(exports.chainToCoingeckoId);
|
|
113
114
|
function getHistoricalChainPrices(ids, timestamp, knownTokenPrices, getCoingeckoLock, coingeckoMaxRetries) {
|
package/build/general.d.ts
CHANGED
|
@@ -2,7 +2,7 @@ import { ethers, BigNumber } from "ethers";
|
|
|
2
2
|
export declare const providers: {
|
|
3
3
|
[chain: string]: ethers.providers.BaseProvider;
|
|
4
4
|
};
|
|
5
|
-
export declare type Chain = "ethereum" | "bsc" | "polygon" | "heco" | "fantom" | "rsk" | "tomochain" | "xdai" | "avax" | "wan" | "iotex" | "harmony" | "thundercore" | "okexchain" | "optimism" | "arbitrum" | "energyweb" | "songbird" | "hpb" | "gochain" | "
|
|
5
|
+
export declare type Chain = "ethereum" | "bsc" | "polygon" | "heco" | "fantom" | "rsk" | "tomochain" | "xdai" | "avax" | "wan" | "iotex" | "harmony" | "thundercore" | "okexchain" | "optimism" | "arbitrum" | "energyweb" | "songbird" | "hpb" | "gochain" | "ethereumclassic" | "xdaiarb" | "kardia" | "fuse" | "smartbch" | "elastos" | "hoo" | "fusion" | "aurora" | "ronin" | "boba" | "cronos" | "polis" | "zyx" | "telos" | "metis" | "ubiq" | "velas" | "callisto" | "csc" | "nahmii" | "liquidchain" | "meter" | "theta" | "oasis" | "syscoin" | "moonbeam" | "curio" | "astar" | "godwoken" | "evmos" | "conflux";
|
|
6
6
|
export declare function getProvider(chain?: Chain): ethers.providers.BaseProvider;
|
|
7
7
|
export declare const TEN: ethers.BigNumber;
|
|
8
8
|
export declare function handleDecimals(num: BigNumber, decimals?: number): string;
|
package/build/general.js
CHANGED
|
@@ -43,14 +43,14 @@ exports.providers = {
|
|
|
43
43
|
kcc: createProvider("kcc", "https://rpc-mainnet.kcc.network", 321),
|
|
44
44
|
celo: createProvider("celo", "https://forno.celo.org", 42220),
|
|
45
45
|
iotex: createProvider("iotex", "https://babel-api.mainnet.iotex.io", 4689),
|
|
46
|
-
moonriver: createProvider("moonriver", "https://rpc.api.moonriver.moonbeam.network/", 1285),
|
|
46
|
+
moonriver: createProvider("moonriver", "https://rpc.api.moonriver.moonbeam.network/,https://moonriver.api.onfinality.io/public", 1285),
|
|
47
47
|
shiden: createProvider("shiden", "https://rpc.shiden.astar.network:8545/", 336),
|
|
48
48
|
palm: createProvider("palm", "https://palm-mainnet.infura.io/v3/3a961d6501e54add9a41aa53f15de99b", 11297108109),
|
|
49
49
|
energyweb: createProvider("energyweb", "https://rpc.energyweb.org", 246),
|
|
50
50
|
songbird: createProvider("songbird", "https://songbird.towolabs.com/rpc", 19),
|
|
51
51
|
hpb: createProvider("hpb", "https://hpbnode.com", 269),
|
|
52
52
|
gochain: createProvider("gochain", "https://rpc.gochain.io", 60),
|
|
53
|
-
|
|
53
|
+
ethereumclassic: createProvider("ethereumclassic", "https://www.ethercluster.com/etc,https://blockscout.com/etc/mainnet/api/eth-rpc", 61),
|
|
54
54
|
xdaiarb: createProvider("xdaiarb", "https://arbitrum.xdaichain.com", 200),
|
|
55
55
|
kardia: createProvider("kardia", "https://rpc.kardiachain.io/", 0),
|
|
56
56
|
fuse: createProvider("fuse", "https://rpc.fuse.io", 122),
|
|
@@ -82,6 +82,7 @@ exports.providers = {
|
|
|
82
82
|
astar: createProvider("astar", "https://rpc.astar.network:8545", 592),
|
|
83
83
|
godwoken: createProvider("godwoken", "https://mainnet.godwoken.io/rpc/eth-wallet", 71394),
|
|
84
84
|
evmos: createProvider("evmos", "https://eth.bd.evmos.org:8545/", 9001),
|
|
85
|
+
conflux: createProvider("conflux", "https://evm.confluxrpc.com", 1030)
|
|
85
86
|
};
|
|
86
87
|
function getProvider(chain) {
|
|
87
88
|
if (chain === void 0) { chain = "ethereum"; }
|