@defillama/sdk 2.3.48 → 2.3.49
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/LICENSE +661 -661
- package/README.md +16 -16
- package/build/abi/cachedABIs.d.ts +4 -4
- package/build/abi/cachedABIs.js +70 -70
- package/build/abi/convertResults.d.ts +2 -2
- package/build/abi/convertResults.js +56 -56
- package/build/abi/index.d.ts +26 -26
- package/build/abi/index.js +185 -185
- package/build/abi/index.test.d.ts +1 -1
- package/build/abi/index.test.js +651 -651
- package/build/abi/multicall.d.ts +13 -13
- package/build/abi/multicall.js +210 -210
- package/build/api.d.ts +10 -10
- package/build/api.js +32 -32
- package/build/cdp/compoundTokens.d.ts +68 -68
- package/build/cdp/compoundTokens.js +69 -69
- package/build/cdp/index.d.ts +29 -29
- package/build/cdp/index.js +124 -124
- package/build/cdp/index.test.d.ts +1 -1
- package/build/cdp/index.test.js +82 -82
- package/build/cdp/makerTokens.d.ts +10 -10
- package/build/cdp/makerTokens.js +244 -244
- package/build/cli.d.ts +2 -2
- package/build/cli.js +95 -95
- package/build/computeTVL/blocks.d.ts +18 -18
- package/build/computeTVL/blocks.js +138 -138
- package/build/computeTVL/blocks.test.d.ts +1 -1
- package/build/computeTVL/blocks.test.js +56 -56
- package/build/computeTVL/humanizeNumber.d.ts +1 -1
- package/build/computeTVL/humanizeNumber.js +18 -18
- package/build/computeTVL/index.d.ts +55 -55
- package/build/computeTVL/index.js +366 -366
- package/build/computeTVL/index.test.d.ts +1 -1
- package/build/computeTVL/index.test.js +107 -107
- package/build/computeTVL/prices.d.ts +9 -9
- package/build/computeTVL/prices.js +163 -163
- package/build/erc20/index.d.ts +31 -31
- package/build/erc20/index.js +144 -144
- package/build/erc20/index.test.d.ts +1 -1
- package/build/erc20/index.test.js +124 -124
- package/build/eth/index.d.ts +21 -21
- package/build/eth/index.js +90 -90
- package/build/eth/index.test.d.ts +1 -1
- package/build/eth/index.test.js +122 -122
- package/build/general.d.ts +10 -10
- package/build/general.js +105 -105
- package/build/general.test.d.ts +1 -1
- package/build/general.test.js +73 -73
- package/build/generalUtil.d.ts +19 -19
- package/build/generalUtil.js +117 -117
- package/build/generalUtil.test.d.ts +1 -1
- package/build/generalUtil.test.js +59 -59
- package/build/index.d.ts +2 -2
- package/build/index.js +24 -24
- package/build/index.test.js +69 -69
- package/build/types.d.ts +5 -5
- package/build/types.js +2 -2
- package/build/util/index.d.ts +57 -57
- package/build/util/index.js +354 -354
- package/build/util/index.test.d.ts +1 -1
- package/build/util/index.test.js +314 -314
- package/build/util/tokenList.d.ts +14 -14
- package/build/util/tokenList.js +3631 -3631
- package/package.json +41 -41
package/build/util/index.d.ts
CHANGED
|
@@ -1,57 +1,57 @@
|
|
|
1
|
-
import { Chain } from "../general";
|
|
2
|
-
import type { Address } from "../types";
|
|
3
|
-
import type { Log } from "@ethersproject/abstract-provider";
|
|
4
|
-
export declare function getLatestBlock(chain: string): Promise<{
|
|
5
|
-
number: number;
|
|
6
|
-
timestamp: number;
|
|
7
|
-
}>;
|
|
8
|
-
export declare function lookupBlock(timestamp: number, extraParams?: {
|
|
9
|
-
chain?: Chain | "terra" | "kava";
|
|
10
|
-
}): Promise<{
|
|
11
|
-
block: number;
|
|
12
|
-
timestamp: number;
|
|
13
|
-
}>;
|
|
14
|
-
export declare function tokenList(): Promise<({
|
|
15
|
-
symbol: string;
|
|
16
|
-
contract: string;
|
|
17
|
-
decimals: number;
|
|
18
|
-
} | {
|
|
19
|
-
symbol: string;
|
|
20
|
-
contract: string;
|
|
21
|
-
decimals?: undefined;
|
|
22
|
-
} | {
|
|
23
|
-
symbol: string;
|
|
24
|
-
contract: string;
|
|
25
|
-
decimals: string;
|
|
26
|
-
})[]>;
|
|
27
|
-
export declare function kyberTokens(): Promise<{
|
|
28
|
-
output: {
|
|
29
|
-
[address: string]: {
|
|
30
|
-
symbol: string;
|
|
31
|
-
decimals: number;
|
|
32
|
-
ethPrice: number;
|
|
33
|
-
};
|
|
34
|
-
};
|
|
35
|
-
}>;
|
|
36
|
-
export declare function toSymbols(tokenBalances: {
|
|
37
|
-
[address: string]: string;
|
|
38
|
-
}): Promise<{
|
|
39
|
-
output: {
|
|
40
|
-
symbol: string;
|
|
41
|
-
address: string;
|
|
42
|
-
balance: string;
|
|
43
|
-
}[];
|
|
44
|
-
}>;
|
|
45
|
-
export declare function getLogs(params: {
|
|
46
|
-
target: Address;
|
|
47
|
-
topic: string;
|
|
48
|
-
keys: string[];
|
|
49
|
-
fromBlock: number;
|
|
50
|
-
toBlock: number;
|
|
51
|
-
topics?: string[];
|
|
52
|
-
chain?: Chain;
|
|
53
|
-
}): Promise<{
|
|
54
|
-
output: string[][];
|
|
55
|
-
} | {
|
|
56
|
-
output: Log[];
|
|
57
|
-
}>;
|
|
1
|
+
import { Chain } from "../general";
|
|
2
|
+
import type { Address } from "../types";
|
|
3
|
+
import type { Log } from "@ethersproject/abstract-provider";
|
|
4
|
+
export declare function getLatestBlock(chain: string): Promise<{
|
|
5
|
+
number: number;
|
|
6
|
+
timestamp: number;
|
|
7
|
+
}>;
|
|
8
|
+
export declare function lookupBlock(timestamp: number, extraParams?: {
|
|
9
|
+
chain?: Chain | "terra" | "kava";
|
|
10
|
+
}): Promise<{
|
|
11
|
+
block: number;
|
|
12
|
+
timestamp: number;
|
|
13
|
+
}>;
|
|
14
|
+
export declare function tokenList(): Promise<({
|
|
15
|
+
symbol: string;
|
|
16
|
+
contract: string;
|
|
17
|
+
decimals: number;
|
|
18
|
+
} | {
|
|
19
|
+
symbol: string;
|
|
20
|
+
contract: string;
|
|
21
|
+
decimals?: undefined;
|
|
22
|
+
} | {
|
|
23
|
+
symbol: string;
|
|
24
|
+
contract: string;
|
|
25
|
+
decimals: string;
|
|
26
|
+
})[]>;
|
|
27
|
+
export declare function kyberTokens(): Promise<{
|
|
28
|
+
output: {
|
|
29
|
+
[address: string]: {
|
|
30
|
+
symbol: string;
|
|
31
|
+
decimals: number;
|
|
32
|
+
ethPrice: number;
|
|
33
|
+
};
|
|
34
|
+
};
|
|
35
|
+
}>;
|
|
36
|
+
export declare function toSymbols(tokenBalances: {
|
|
37
|
+
[address: string]: string;
|
|
38
|
+
}): Promise<{
|
|
39
|
+
output: {
|
|
40
|
+
symbol: string;
|
|
41
|
+
address: string;
|
|
42
|
+
balance: string;
|
|
43
|
+
}[];
|
|
44
|
+
}>;
|
|
45
|
+
export declare function getLogs(params: {
|
|
46
|
+
target: Address;
|
|
47
|
+
topic: string;
|
|
48
|
+
keys: string[];
|
|
49
|
+
fromBlock: number;
|
|
50
|
+
toBlock: number;
|
|
51
|
+
topics?: string[];
|
|
52
|
+
chain?: Chain;
|
|
53
|
+
}): Promise<{
|
|
54
|
+
output: string[][];
|
|
55
|
+
} | {
|
|
56
|
+
output: Log[];
|
|
57
|
+
}>;
|