@augustdigital/sdk 4.15.5-alpha.0 → 4.16.0
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/lib/abis/AddressResolver.d.ts +28 -40
- package/lib/abis/ChainlinkV3.d.ts +83 -109
- package/lib/abis/ERC20.d.ts +137 -191
- package/lib/abis/ERC20_Bytes32.d.ts +125 -178
- package/lib/abis/ERC4626.d.ts +341 -480
- package/lib/abis/ERC721.d.ts +213 -299
- package/lib/abis/FeeOracle.d.ts +112 -149
- package/lib/abis/LendingPool.d.ts +1293 -1702
- package/lib/abis/LendingPoolV2.d.ts +37 -42
- package/lib/abis/LendingPoolV3.d.ts +25 -29
- package/lib/abis/Loan.d.ts +768 -1007
- package/lib/abis/Multicall3.d.ts +30 -43
- package/lib/abis/PoolAdapter.d.ts +35 -46
- package/lib/abis/RewardDistributor.d.ts +33 -38
- package/lib/abis/SmartAccount.d.ts +16 -23
- package/lib/abis/TextResolver.d.ts +16 -23
- package/lib/abis/TokenizedVaultV2.d.ts +1292 -1684
- package/lib/abis/TokenizedVaultV2DepositWithPermit.d.ts +55 -62
- package/lib/abis/TokenizedVaultV2Receipt.d.ts +1463 -1934
- package/lib/abis/TokenizedVaultV2WhitelistedAssets.d.ts +250 -333
- package/lib/abis/UniversalResolverResolve.d.ts +69 -97
- package/lib/abis/UniversalSignatureValidator.d.ts +17 -23
- package/lib/abis/WrapperAdapter.d.ts +67 -89
- package/lib/adapters/evm/getters.d.ts +2 -8
- package/lib/adapters/evm/index.d.ts +15 -19
- package/lib/adapters/evm/utils.d.ts +2 -12
- package/lib/adapters/solana/constants.d.ts +17 -23
- package/lib/adapters/solana/getters.d.ts +1 -4
- package/lib/adapters/solana/idl/vault-idl.d.ts +279 -340
- package/lib/adapters/solana/index.d.ts +116 -212
- package/lib/adapters/solana/types.d.ts +50 -50
- package/lib/adapters/solana/utils.d.ts +78 -139
- package/lib/adapters/solana/vault.actions.d.ts +12 -37
- package/lib/adapters/sui/constants.d.ts +8 -9
- package/lib/adapters/sui/getters.d.ts +1 -3
- package/lib/adapters/sui/index.d.ts +21 -29
- package/lib/adapters/sui/transformer.d.ts +2 -6
- package/lib/adapters/sui/types.d.ts +56 -56
- package/lib/adapters/sui/utils.d.ts +1 -4
- package/lib/core/base.class.d.ts +23 -30
- package/lib/core/constants/adapters.d.ts +83 -111
- package/lib/core/constants/core.d.ts +69 -76
- package/lib/core/constants/vaults.d.ts +5 -63
- package/lib/core/constants/vaults.js +3 -3
- package/lib/core/constants/vaults.js.map +1 -1
- package/lib/core/constants/web3.d.ts +18 -19
- package/lib/core/fetcher.d.ts +17 -71
- package/lib/core/helpers/adapters.d.ts +2 -7
- package/lib/core/helpers/core.d.ts +8 -33
- package/lib/core/helpers/signer.d.ts +2 -6
- package/lib/core/helpers/vaults.d.ts +15 -38
- package/lib/core/helpers/web3.d.ts +19 -87
- package/lib/core/logger/index.d.ts +11 -11
- package/lib/core/logger/slack.d.ts +8 -9
- package/lib/index.d.ts +1 -61
- package/lib/main.d.ts +141 -158
- package/lib/modules/vaults/adapter.helpers.d.ts +38 -72
- package/lib/modules/vaults/fetcher.d.ts +69 -85
- package/lib/modules/vaults/getters.d.ts +100 -205
- package/lib/modules/vaults/index.d.ts +1 -6
- package/lib/modules/vaults/main.d.ts +131 -224
- package/lib/modules/vaults/read.actions.d.ts +2 -8
- package/lib/modules/vaults/utils.d.ts +19 -55
- package/lib/modules/vaults/write.actions.d.ts +14 -26
- package/lib/services/coingecko/fetcher.d.ts +1 -4
- package/lib/services/debank/fetcher.d.ts +1 -4
- package/lib/services/debank/utils.d.ts +27 -38
- package/lib/services/octavfi/fetcher.d.ts +1 -3
- package/lib/services/octavfi/types.d.ts +24 -24
- package/lib/services/octavfi/utils.d.ts +2 -6
- package/lib/services/subgraph/fetcher.d.ts +2 -12
- package/lib/services/subgraph/vaults.d.ts +9 -42
- package/lib/types/points.d.ts +26 -35
- package/lib/types/pools.d.ts +112 -149
- package/lib/types/staking.d.ts +25 -25
- package/lib/types/subgraph.d.ts +33 -33
- package/lib/types/vaults.d.ts +219 -232
- package/lib/types/web3.d.ts +9 -9
- package/lib/types/webserver.d.ts +448 -466
- package/package.json +1 -1
package/lib/main.d.ts
CHANGED
|
@@ -1,169 +1,152 @@
|
|
|
1
1
|
import SolanaAdapter from './adapters/solana';
|
|
2
2
|
import SuiAdapter from './adapters/sui';
|
|
3
3
|
import EVMAdapter from './adapters/evm';
|
|
4
|
-
import {
|
|
5
|
-
IAddress,
|
|
6
|
-
IChainId,
|
|
7
|
-
IVaultHistoricalParams,
|
|
8
|
-
IWSMonitorHeaders,
|
|
9
|
-
} from './types';
|
|
4
|
+
import { IAddress, IChainId, IVaultHistoricalParams, IWSMonitorHeaders } from './types';
|
|
10
5
|
import { AugustBase, IAugustBase } from './core';
|
|
11
6
|
import { IVaultBaseOptions, IVaultCustomOptions } from './modules/vaults';
|
|
12
7
|
import { Signer, Wallet } from 'ethers';
|
|
13
8
|
import { IContractWriteOptions } from './modules/vaults/write.actions';
|
|
14
9
|
export declare class AugustSDK extends AugustBase {
|
|
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
|
-
}): Promise<import('./types').IVaultLoan[]>;
|
|
52
|
-
getVaultAllocations(props: { vault: IAddress; chainId?: IChainId }): Promise<
|
|
53
|
-
| import('./types').IVaultAllocations
|
|
54
|
-
| {
|
|
10
|
+
private vaults;
|
|
11
|
+
solana: SolanaAdapter;
|
|
12
|
+
sui: SuiAdapter;
|
|
13
|
+
evm: EVMAdapter;
|
|
14
|
+
name: string;
|
|
15
|
+
constructor(baseConfig: IAugustBase);
|
|
16
|
+
switchNetwork(chainId: IChainId): void;
|
|
17
|
+
updateWallet(address: IAddress): void;
|
|
18
|
+
clearWallet(): void;
|
|
19
|
+
getPrice(symbol: string): Promise<any>;
|
|
20
|
+
getVaults(options?: {
|
|
21
|
+
chainIds?: number[];
|
|
22
|
+
headers?: IWSMonitorHeaders;
|
|
23
|
+
loadSubaccounts?: boolean;
|
|
24
|
+
loadSnapshots?: boolean;
|
|
25
|
+
} & IVaultCustomOptions): Promise<import("./types").IVault[]>;
|
|
26
|
+
getTotalDeposited(options?: {
|
|
27
|
+
loadSubaccounts?: boolean;
|
|
28
|
+
loadSnapshots?: boolean;
|
|
29
|
+
}): Promise<number>;
|
|
30
|
+
vaultDeposit(signer: Signer | Wallet, options: IContractWriteOptions): Promise<string>;
|
|
31
|
+
getVault(props: {
|
|
32
|
+
vault: IAddress;
|
|
33
|
+
chainId?: IChainId;
|
|
34
|
+
options?: IVaultCustomOptions;
|
|
35
|
+
loadSubaccounts?: boolean;
|
|
36
|
+
loadSnapshots?: boolean;
|
|
37
|
+
}): Promise<import("./types").IVault>;
|
|
38
|
+
getVaultLoans(props: {
|
|
39
|
+
vault: IAddress;
|
|
40
|
+
chainId?: IChainId;
|
|
41
|
+
}): Promise<import("./types").IVaultLoan[]>;
|
|
42
|
+
getVaultAllocations(props: {
|
|
43
|
+
vault: IAddress;
|
|
44
|
+
chainId?: IChainId;
|
|
45
|
+
}): Promise<import("./types").IVaultAllocations | {
|
|
55
46
|
status: number;
|
|
56
47
|
message: string;
|
|
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
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
vault: IAddress;
|
|
162
|
-
chainId?: IChainId;
|
|
163
|
-
}): Promise<import('./types').IVaultWithdrawals>;
|
|
164
|
-
previewRedemption(props: {
|
|
165
|
-
vault: IAddress;
|
|
166
|
-
sharesAmount: string | bigint | number;
|
|
167
|
-
chainId?: IChainId;
|
|
168
|
-
}): Promise<import('./types').INormalizedNumber>;
|
|
48
|
+
}>;
|
|
49
|
+
getVaultApy(props: {
|
|
50
|
+
vault: IAddress;
|
|
51
|
+
historical?: {
|
|
52
|
+
daysAgo?: number;
|
|
53
|
+
};
|
|
54
|
+
}): Promise<{
|
|
55
|
+
value: number;
|
|
56
|
+
timestamp: string;
|
|
57
|
+
}[]>;
|
|
58
|
+
getVaultTvl(props: {
|
|
59
|
+
vault: IAddress;
|
|
60
|
+
historical?: IVaultHistoricalParams;
|
|
61
|
+
chainId?: IChainId;
|
|
62
|
+
}): Promise<{
|
|
63
|
+
value: import("./types").INormalizedNumber;
|
|
64
|
+
timestamp: string;
|
|
65
|
+
}[]>;
|
|
66
|
+
getVaultHistoricalTimeseries(props: {
|
|
67
|
+
vault: IAddress;
|
|
68
|
+
nDays?: number;
|
|
69
|
+
}): Promise<import("./types").IHistoricalTimeseriesResponse>;
|
|
70
|
+
getYieldLastRealizedOn(props: {
|
|
71
|
+
vault: IAddress;
|
|
72
|
+
chainId?: IChainId;
|
|
73
|
+
}): Promise<number>;
|
|
74
|
+
getVaultAvailableRedemptions(props: {
|
|
75
|
+
vault: IAddress;
|
|
76
|
+
chainId?: IChainId;
|
|
77
|
+
wallet?: IAddress;
|
|
78
|
+
verbose?: boolean;
|
|
79
|
+
}): Promise<{
|
|
80
|
+
processedWithdrawals: import("./types").ISubgraphWithdrawProccessed[];
|
|
81
|
+
requestedWithdrawals: import("./types").ISubgraphWithdrawRequest[];
|
|
82
|
+
availableRedemptions: import("./types").IVaultAvailableRedemption[];
|
|
83
|
+
pendingRedemptions: import("./types").IVaultAvailableRedemption[];
|
|
84
|
+
}>;
|
|
85
|
+
getVaultPositions(props: {
|
|
86
|
+
vault?: IAddress;
|
|
87
|
+
wallet?: IAddress;
|
|
88
|
+
chainId?: IChainId;
|
|
89
|
+
showAllVaults?: boolean;
|
|
90
|
+
solanaWallet?: string;
|
|
91
|
+
options?: IVaultBaseOptions;
|
|
92
|
+
}): Promise<import("./types").IVaultPosition[]>;
|
|
93
|
+
getVaultUserHistory(props: {
|
|
94
|
+
wallet: IAddress;
|
|
95
|
+
chainId?: IChainId;
|
|
96
|
+
vault?: IAddress;
|
|
97
|
+
options?: IVaultBaseOptions;
|
|
98
|
+
}): Promise<import("./types").IVaultUserHistoryItem[]>;
|
|
99
|
+
getVaultUserTransfers(props: {
|
|
100
|
+
wallet: IAddress;
|
|
101
|
+
chainId?: IChainId;
|
|
102
|
+
vault?: IAddress;
|
|
103
|
+
options?: IVaultBaseOptions;
|
|
104
|
+
}): Promise<{
|
|
105
|
+
id: string;
|
|
106
|
+
value: string;
|
|
107
|
+
to: string;
|
|
108
|
+
from: string;
|
|
109
|
+
pool: string;
|
|
110
|
+
block: number;
|
|
111
|
+
timestamp: number;
|
|
112
|
+
transactionHash: string;
|
|
113
|
+
}[]>;
|
|
114
|
+
getVaultUserLifetimePnl(props: {
|
|
115
|
+
vault: IAddress;
|
|
116
|
+
wallet: IAddress;
|
|
117
|
+
chainId?: IChainId;
|
|
118
|
+
}): Promise<import("./types").IVaultUserLifetimePnl>;
|
|
119
|
+
getVaultPnl(props: {
|
|
120
|
+
vault: IAddress;
|
|
121
|
+
chainId?: IChainId;
|
|
122
|
+
}): Promise<import("./types").IVaultPnl>;
|
|
123
|
+
getVaultStakingPositions(props: {
|
|
124
|
+
wallet?: IAddress;
|
|
125
|
+
chainId?: IChainId;
|
|
126
|
+
}): Promise<import("./types").IActiveStakingPosition[]>;
|
|
127
|
+
getVaultBorrowerHealthFactor(props?: {
|
|
128
|
+
chainId?: IChainId;
|
|
129
|
+
}): Promise<{}>;
|
|
130
|
+
getUserPoints(userAddress: IAddress): Promise<any>;
|
|
131
|
+
registerUserForPoints(userAddress: IAddress, referrerAddress?: IAddress): Promise<Response>;
|
|
132
|
+
fetchPointsLeaderboard(params?: {
|
|
133
|
+
page?: number;
|
|
134
|
+
perPage?: number;
|
|
135
|
+
sortBy?: 'streakDays' | 'totalPoints';
|
|
136
|
+
}): Promise<any>;
|
|
137
|
+
getVaultAnnualizedApy(props: {
|
|
138
|
+
vault: IAddress;
|
|
139
|
+
}): Promise<import("./types").IVaultAnnualizedApy>;
|
|
140
|
+
getVaultSummary(props: {
|
|
141
|
+
vault: IAddress;
|
|
142
|
+
}): Promise<import("./types").IVaultSummary>;
|
|
143
|
+
getVaultWithdrawals(props: {
|
|
144
|
+
vault: IAddress;
|
|
145
|
+
chainId?: IChainId;
|
|
146
|
+
}): Promise<import("./types").IVaultWithdrawals>;
|
|
147
|
+
previewRedemption(props: {
|
|
148
|
+
vault: IAddress;
|
|
149
|
+
sharesAmount: string | bigint | number;
|
|
150
|
+
chainId?: IChainId;
|
|
151
|
+
}): Promise<import("./types").INormalizedNumber>;
|
|
169
152
|
}
|
|
@@ -1,80 +1,46 @@
|
|
|
1
1
|
import { BaseContract, Signer, Wallet } from 'ethers';
|
|
2
2
|
import { IAddress } from '../../types';
|
|
3
3
|
import { IVaultAdapterConfig } from '../../types/vaults';
|
|
4
|
-
export declare function getParaswapQuote({
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
}: {
|
|
12
|
-
srcToken: string;
|
|
13
|
-
destToken: string;
|
|
14
|
-
amount: string;
|
|
15
|
-
network: string;
|
|
16
|
-
srcDecimals: number;
|
|
17
|
-
destDecimals: number;
|
|
4
|
+
export declare function getParaswapQuote({ srcToken, destToken, amount, network, srcDecimals, destDecimals, }: {
|
|
5
|
+
srcToken: string;
|
|
6
|
+
destToken: string;
|
|
7
|
+
amount: string;
|
|
8
|
+
network: string;
|
|
9
|
+
srcDecimals: number;
|
|
10
|
+
destDecimals: number;
|
|
18
11
|
}): Promise<any>;
|
|
19
|
-
export declare function buildSwapAndDepositTransaction({
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
}: {
|
|
30
|
-
signer: Signer | Wallet;
|
|
31
|
-
srcToken: IAddress;
|
|
32
|
-
srcDecimals: number;
|
|
33
|
-
destToken: IAddress;
|
|
34
|
-
destDecimals: number;
|
|
35
|
-
amount: string;
|
|
36
|
-
network: string;
|
|
37
|
-
adapterConfig: IVaultAdapterConfig;
|
|
38
|
-
userAddress: IAddress;
|
|
12
|
+
export declare function buildSwapAndDepositTransaction({ signer, srcToken, srcDecimals, destToken, destDecimals, amount, network, adapterConfig, userAddress, }: {
|
|
13
|
+
signer: Signer | Wallet;
|
|
14
|
+
srcToken: IAddress;
|
|
15
|
+
srcDecimals: number;
|
|
16
|
+
destToken: IAddress;
|
|
17
|
+
destDecimals: number;
|
|
18
|
+
amount: string;
|
|
19
|
+
network: string;
|
|
20
|
+
adapterConfig: IVaultAdapterConfig;
|
|
21
|
+
userAddress: IAddress;
|
|
39
22
|
}): Promise<BaseContract>;
|
|
40
|
-
export declare function buildNativeDepositTransaction({
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
}: {
|
|
48
|
-
signer: Signer | Wallet;
|
|
49
|
-
srcToken: IAddress;
|
|
50
|
-
amount: string;
|
|
51
|
-
poolName?: string;
|
|
52
|
-
adapterConfig: IVaultAdapterConfig;
|
|
53
|
-
userAddress: IAddress;
|
|
23
|
+
export declare function buildNativeDepositTransaction({ signer, srcToken, amount, poolName, adapterConfig, userAddress, }: {
|
|
24
|
+
signer: Signer | Wallet;
|
|
25
|
+
srcToken: IAddress;
|
|
26
|
+
amount: string;
|
|
27
|
+
poolName?: string;
|
|
28
|
+
adapterConfig: IVaultAdapterConfig;
|
|
29
|
+
userAddress: IAddress;
|
|
54
30
|
}): Promise<{
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
31
|
+
contract: BaseContract;
|
|
32
|
+
functionName: string;
|
|
33
|
+
args: any[];
|
|
34
|
+
value?: bigint;
|
|
59
35
|
}>;
|
|
60
|
-
export declare function previewAdapterDeposit({
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
}: {
|
|
71
|
-
signer: Signer | Wallet;
|
|
72
|
-
vaultAddress: IAddress;
|
|
73
|
-
srcToken: IAddress;
|
|
74
|
-
srcAmount: string;
|
|
75
|
-
srcDecimals: number;
|
|
76
|
-
destToken: IAddress;
|
|
77
|
-
destDecimals: number;
|
|
78
|
-
adapterConfig: IVaultAdapterConfig;
|
|
79
|
-
chainId: number;
|
|
36
|
+
export declare function previewAdapterDeposit({ signer, vaultAddress, srcToken, srcAmount, srcDecimals, destToken, destDecimals, adapterConfig, chainId, }: {
|
|
37
|
+
signer: Signer | Wallet;
|
|
38
|
+
vaultAddress: IAddress;
|
|
39
|
+
srcToken: IAddress;
|
|
40
|
+
srcAmount: string;
|
|
41
|
+
srcDecimals: number;
|
|
42
|
+
destToken: IAddress;
|
|
43
|
+
destDecimals: number;
|
|
44
|
+
adapterConfig: IVaultAdapterConfig;
|
|
45
|
+
chainId: number;
|
|
80
46
|
}): Promise<bigint>;
|
|
@@ -1,56 +1,46 @@
|
|
|
1
1
|
import { IVaultMetadata } from '../../types';
|
|
2
|
-
export declare function fetchVaultWithFallback<T>(
|
|
3
|
-
vaultAddress: string,
|
|
4
|
-
fetchFn: () => Promise<T>,
|
|
5
|
-
options?: {
|
|
2
|
+
export declare function fetchVaultWithFallback<T>(vaultAddress: string, fetchFn: () => Promise<T>, options?: {
|
|
6
3
|
maxRetries?: number;
|
|
7
4
|
baseDelay?: number;
|
|
8
5
|
fallbackStrategies?: Array<() => Promise<T>>;
|
|
9
6
|
timeout?: number;
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
strategy: string;
|
|
7
|
+
}): Promise<{
|
|
8
|
+
success: boolean;
|
|
9
|
+
data?: T;
|
|
10
|
+
error?: Error;
|
|
11
|
+
strategy: string;
|
|
16
12
|
}>;
|
|
17
|
-
export declare function fetchVaultsBatch<T>(
|
|
18
|
-
vaults: Array<{
|
|
13
|
+
export declare function fetchVaultsBatch<T>(vaults: Array<{
|
|
19
14
|
address: string;
|
|
20
15
|
fetchFn: () => Promise<T>;
|
|
21
|
-
|
|
22
|
-
options?: {
|
|
16
|
+
}>, options?: {
|
|
23
17
|
maxRetries?: number;
|
|
24
18
|
baseDelay?: number;
|
|
25
19
|
batchSize?: number;
|
|
26
20
|
parallelLimit?: number;
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
successRate: number;
|
|
21
|
+
}): Promise<{
|
|
22
|
+
successful: Array<{
|
|
23
|
+
index: number;
|
|
24
|
+
data: T;
|
|
25
|
+
strategy: string;
|
|
26
|
+
}>;
|
|
27
|
+
failed: Array<{
|
|
28
|
+
index: number;
|
|
29
|
+
error: Error;
|
|
30
|
+
address: string;
|
|
31
|
+
}>;
|
|
32
|
+
totalAttempted: number;
|
|
33
|
+
successRate: number;
|
|
41
34
|
}>;
|
|
42
|
-
export declare function fetchVaultsComprehensive<T>(
|
|
43
|
-
vaults: Array<{
|
|
35
|
+
export declare function fetchVaultsComprehensive<T>(vaults: Array<{
|
|
44
36
|
address: string;
|
|
45
37
|
chain: number;
|
|
46
|
-
|
|
47
|
-
fetchFn: (vault: {
|
|
38
|
+
}>, fetchFn: (vault: {
|
|
48
39
|
address: string;
|
|
49
40
|
chain: number;
|
|
50
41
|
fallbackRpc?: string;
|
|
51
42
|
minimal?: boolean;
|
|
52
|
-
|
|
53
|
-
options?: {
|
|
43
|
+
}) => Promise<T>, options?: {
|
|
54
44
|
maxRetries?: number;
|
|
55
45
|
baseDelay?: number;
|
|
56
46
|
batchSize?: number;
|
|
@@ -59,65 +49,59 @@ export declare function fetchVaultsComprehensive<T>(
|
|
|
59
49
|
includeInvisible?: boolean;
|
|
60
50
|
fallbackRpcUrls?: Record<number, string[]>;
|
|
61
51
|
timeout?: number;
|
|
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
|
-
};
|
|
52
|
+
}): Promise<{
|
|
53
|
+
successful: Array<{
|
|
54
|
+
index: number;
|
|
55
|
+
data: T;
|
|
56
|
+
strategy: string;
|
|
57
|
+
attempts: number;
|
|
58
|
+
}>;
|
|
59
|
+
failed: Array<{
|
|
60
|
+
index: number;
|
|
61
|
+
error: Error;
|
|
62
|
+
address: string;
|
|
63
|
+
chain: number;
|
|
64
|
+
attempts: number;
|
|
65
|
+
}>;
|
|
66
|
+
totalAttempted: number;
|
|
67
|
+
successRate: number;
|
|
68
|
+
coverageReport: {
|
|
69
|
+
totalVaults: number;
|
|
70
|
+
successfulVaults: number;
|
|
71
|
+
failedVaults: number;
|
|
72
|
+
closedVaults: number;
|
|
73
|
+
invisibleVaults: number;
|
|
74
|
+
rpcFailures: Record<number, number>;
|
|
75
|
+
};
|
|
87
76
|
}>;
|
|
88
|
-
export declare function filterVaultsIntelligently<
|
|
89
|
-
T extends {
|
|
77
|
+
export declare function filterVaultsIntelligently<T extends {
|
|
90
78
|
status?: string;
|
|
91
79
|
isVisible?: boolean;
|
|
92
80
|
is_visible?: boolean;
|
|
93
|
-
|
|
94
|
-
>(
|
|
95
|
-
vaults: (T | null)[],
|
|
96
|
-
options?: {
|
|
81
|
+
}>(vaults: (T | null)[], options?: {
|
|
97
82
|
includeClosed?: boolean;
|
|
98
83
|
includeInvisible?: boolean;
|
|
99
84
|
includeNull?: boolean;
|
|
100
85
|
minStatus?: string[];
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
};
|
|
86
|
+
}): {
|
|
87
|
+
active: T[];
|
|
88
|
+
closed: T[];
|
|
89
|
+
invisible: T[];
|
|
90
|
+
failed: Array<{
|
|
91
|
+
index: number;
|
|
92
|
+
reason: string;
|
|
93
|
+
}>;
|
|
94
|
+
summary: {
|
|
95
|
+
total: number;
|
|
96
|
+
active: number;
|
|
97
|
+
closed: number;
|
|
98
|
+
invisible: number;
|
|
99
|
+
failed: number;
|
|
100
|
+
successRate: number;
|
|
101
|
+
};
|
|
118
102
|
};
|
|
119
103
|
export declare function fetchVaultMetadata(opts?: {
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
104
|
+
options?: {
|
|
105
|
+
headers?: Record<string, string>;
|
|
106
|
+
};
|
|
123
107
|
}): Promise<IVaultMetadata>;
|