@1delta/abis 0.0.12 → 0.0.14

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.
Files changed (42) hide show
  1. package/dist/compound-v2/c-ether.d.ts +1 -1
  2. package/dist/compound-v2/c-ether.d.ts.map +1 -1
  3. package/dist/compound-v2/c-ether.js +368 -65
  4. package/dist/compound-v2/index.d.ts +1 -1
  5. package/dist/compound-v2/index.js +1 -1
  6. package/dist/fluid/index.d.ts +3 -0
  7. package/dist/fluid/index.d.ts.map +1 -0
  8. package/dist/fluid/index.js +2 -0
  9. package/dist/fluid/lendingResolver.d.ts +91 -0
  10. package/dist/fluid/lendingResolver.d.ts.map +1 -0
  11. package/dist/fluid/lendingResolver.js +55 -0
  12. package/dist/fluid/resolvers.d.ts +3 -0
  13. package/dist/fluid/resolvers.d.ts.map +1 -0
  14. package/dist/fluid/resolvers.js +12 -0
  15. package/dist/fluid/vaultResolver.d.ts +1083 -0
  16. package/dist/fluid/vaultResolver.d.ts.map +1 -0
  17. package/dist/fluid/vaultResolver.js +1479 -0
  18. package/dist/gearbox/creditFacadeV3.d.ts +59 -0
  19. package/dist/gearbox/creditFacadeV3.d.ts.map +1 -0
  20. package/dist/gearbox/creditFacadeV3.js +59 -0
  21. package/dist/gearbox/creditManagerV3.d.ts +156 -0
  22. package/dist/gearbox/creditManagerV3.d.ts.map +1 -0
  23. package/dist/gearbox/creditManagerV3.js +108 -0
  24. package/dist/gearbox/dataCompressorV3.d.ts +560 -0
  25. package/dist/gearbox/dataCompressorV3.d.ts.map +1 -0
  26. package/dist/gearbox/dataCompressorV3.js +225 -0
  27. package/dist/gearbox/index.d.ts +7 -0
  28. package/dist/gearbox/index.d.ts.map +1 -0
  29. package/dist/gearbox/index.js +6 -0
  30. package/dist/gearbox/poolQuotaKeeperV3.d.ts +65 -0
  31. package/dist/gearbox/poolQuotaKeeperV3.d.ts.map +1 -0
  32. package/dist/gearbox/poolQuotaKeeperV3.js +52 -0
  33. package/dist/gearbox/poolV3.d.ts +152 -0
  34. package/dist/gearbox/poolV3.d.ts.map +1 -0
  35. package/dist/gearbox/poolV3.js +133 -0
  36. package/dist/gearbox/priceOracleV3.d.ts +35 -0
  37. package/dist/gearbox/priceOracleV3.d.ts.map +1 -0
  38. package/dist/gearbox/priceOracleV3.js +28 -0
  39. package/dist/index.d.ts +5 -3
  40. package/dist/index.d.ts.map +1 -1
  41. package/dist/index.js +5 -3
  42. package/package.json +1 -1
@@ -0,0 +1,225 @@
1
+ // Gearbox DataCompressorV3 ABI — multicall-like aggregator for pool and
2
+ // credit account data. Collapses per-pool and per-account work into one RPC.
3
+ //
4
+ // Functions kept:
5
+ // - getPoolsV3List() -> PoolData[]
6
+ // - getCreditManagersV3List() -> CreditManagerData[]
7
+ // - getCreditAccountsByBorrower(address, PriceOnDemand[]) -> CreditAccountData[]
8
+ // - getCreditAccountData(address, PriceOnDemand[]) -> CreditAccountData
9
+ //
10
+ // Source: Sourcify metadata for the deployed DataCompressorV3 at
11
+ // 0x104c4e209329524adb0febe8b6481346a6eb75c6 on Ethereum mainnet.
12
+ //
13
+ // The CM list (collateral tokens, LTs, debt limits, …) is NOT embedded in
14
+ // `getPoolsV3List` — it must be fetched via the separate
15
+ // `getCreditManagersV3List` call and joined by `cm.pool`.
16
+ const PriceOnDemand = {
17
+ components: [
18
+ { name: 'token', type: 'address' },
19
+ { name: 'callData', type: 'bytes' },
20
+ ],
21
+ name: 'priceUpdates',
22
+ type: 'tuple[]',
23
+ };
24
+ const QuotaInfo = {
25
+ components: [
26
+ { name: 'token', type: 'address' },
27
+ { name: 'rate', type: 'uint16' },
28
+ { name: 'quotaIncreaseFee', type: 'uint16' },
29
+ { name: 'totalQuoted', type: 'uint96' },
30
+ { name: 'limit', type: 'uint96' },
31
+ { name: 'isActive', type: 'bool' },
32
+ ],
33
+ name: 'quotas',
34
+ type: 'tuple[]',
35
+ };
36
+ const LinearModel = {
37
+ components: [
38
+ { name: 'interestModel', type: 'address' },
39
+ { name: 'version', type: 'uint256' },
40
+ { name: 'U_1', type: 'uint16' },
41
+ { name: 'U_2', type: 'uint16' },
42
+ { name: 'R_base', type: 'uint16' },
43
+ { name: 'R_slope1', type: 'uint16' },
44
+ { name: 'R_slope2', type: 'uint16' },
45
+ { name: 'R_slope3', type: 'uint16' },
46
+ { name: 'isBorrowingMoreU2Forbidden', type: 'bool' },
47
+ ],
48
+ name: 'lirm',
49
+ type: 'tuple',
50
+ };
51
+ const CreditAccountDataComponents = [
52
+ { name: 'isSuccessful', type: 'bool' },
53
+ { name: 'priceFeedsNeeded', type: 'address[]' },
54
+ { name: 'addr', type: 'address' },
55
+ { name: 'borrower', type: 'address' },
56
+ { name: 'creditManager', type: 'address' },
57
+ { name: 'cmName', type: 'string' },
58
+ { name: 'creditFacade', type: 'address' },
59
+ { name: 'underlying', type: 'address' },
60
+ { name: 'debt', type: 'uint256' },
61
+ { name: 'cumulativeIndexLastUpdate', type: 'uint256' },
62
+ { name: 'cumulativeQuotaInterest', type: 'uint128' },
63
+ { name: 'accruedInterest', type: 'uint256' },
64
+ { name: 'accruedFees', type: 'uint256' },
65
+ { name: 'totalDebtUSD', type: 'uint256' },
66
+ { name: 'totalValue', type: 'uint256' },
67
+ { name: 'totalValueUSD', type: 'uint256' },
68
+ { name: 'twvUSD', type: 'uint256' },
69
+ { name: 'enabledTokensMask', type: 'uint256' },
70
+ { name: 'healthFactor', type: 'uint256' },
71
+ { name: 'baseBorrowRate', type: 'uint256' },
72
+ { name: 'aggregatedBorrowRate', type: 'uint256' },
73
+ {
74
+ components: [
75
+ { name: 'token', type: 'address' },
76
+ { name: 'balance', type: 'uint256' },
77
+ { name: 'isForbidden', type: 'bool' },
78
+ { name: 'isEnabled', type: 'bool' },
79
+ { name: 'isQuoted', type: 'bool' },
80
+ { name: 'quota', type: 'uint256' },
81
+ { name: 'quotaRate', type: 'uint16' },
82
+ { name: 'quotaCumulativeIndexLU', type: 'uint256' },
83
+ ],
84
+ name: 'balances',
85
+ type: 'tuple[]',
86
+ },
87
+ { name: 'since', type: 'uint64' },
88
+ { name: 'cfVersion', type: 'uint256' },
89
+ { name: 'expirationDate', type: 'uint40' },
90
+ { name: 'activeBots', type: 'address[]' },
91
+ ];
92
+ export const GearboxDataCompressorV3Abi = [
93
+ {
94
+ inputs: [],
95
+ name: 'getPoolsV3List',
96
+ outputs: [
97
+ {
98
+ components: [
99
+ { name: 'addr', type: 'address' },
100
+ { name: 'underlying', type: 'address' },
101
+ { name: 'dieselToken', type: 'address' },
102
+ { name: 'symbol', type: 'string' },
103
+ { name: 'name', type: 'string' },
104
+ { name: 'baseInterestIndex', type: 'uint256' },
105
+ { name: 'availableLiquidity', type: 'uint256' },
106
+ { name: 'expectedLiquidity', type: 'uint256' },
107
+ { name: 'totalBorrowed', type: 'uint256' },
108
+ { name: 'totalDebtLimit', type: 'uint256' },
109
+ {
110
+ components: [
111
+ { name: 'creditManager', type: 'address' },
112
+ { name: 'borrowed', type: 'uint256' },
113
+ { name: 'limit', type: 'uint256' },
114
+ { name: 'availableToBorrow', type: 'uint256' },
115
+ ],
116
+ name: 'creditManagerDebtParams',
117
+ type: 'tuple[]',
118
+ },
119
+ { name: 'totalAssets', type: 'uint256' },
120
+ { name: 'totalSupply', type: 'uint256' },
121
+ { name: 'supplyRate', type: 'uint256' },
122
+ { name: 'baseInterestRate', type: 'uint256' },
123
+ { name: 'dieselRate_RAY', type: 'uint256' },
124
+ { name: 'withdrawFee', type: 'uint256' },
125
+ { name: 'lastBaseInterestUpdate', type: 'uint256' },
126
+ { name: 'baseInterestIndexLU', type: 'uint256' },
127
+ { name: 'version', type: 'uint256' },
128
+ { name: 'poolQuotaKeeper', type: 'address' },
129
+ { name: 'gauge', type: 'address' },
130
+ QuotaInfo,
131
+ {
132
+ components: [
133
+ { name: 'zapper', type: 'address' },
134
+ { name: 'tokenIn', type: 'address' },
135
+ { name: 'tokenOut', type: 'address' },
136
+ ],
137
+ name: 'zappers',
138
+ type: 'tuple[]',
139
+ },
140
+ LinearModel,
141
+ { name: 'isPaused', type: 'bool' },
142
+ ],
143
+ name: 'result',
144
+ type: 'tuple[]',
145
+ },
146
+ ],
147
+ stateMutability: 'view',
148
+ type: 'function',
149
+ },
150
+ {
151
+ inputs: [],
152
+ name: 'getCreditManagersV3List',
153
+ outputs: [
154
+ {
155
+ components: [
156
+ { name: 'addr', type: 'address' },
157
+ { name: 'name', type: 'string' },
158
+ { name: 'cfVersion', type: 'uint256' },
159
+ { name: 'creditFacade', type: 'address' },
160
+ { name: 'creditConfigurator', type: 'address' },
161
+ { name: 'underlying', type: 'address' },
162
+ { name: 'pool', type: 'address' },
163
+ { name: 'totalDebt', type: 'uint256' },
164
+ { name: 'totalDebtLimit', type: 'uint256' },
165
+ { name: 'baseBorrowRate', type: 'uint256' },
166
+ { name: 'minDebt', type: 'uint256' },
167
+ { name: 'maxDebt', type: 'uint256' },
168
+ { name: 'availableToBorrow', type: 'uint256' },
169
+ { name: 'collateralTokens', type: 'address[]' },
170
+ {
171
+ components: [
172
+ { name: 'targetContract', type: 'address' },
173
+ { name: 'adapter', type: 'address' },
174
+ ],
175
+ name: 'adapters',
176
+ type: 'tuple[]',
177
+ },
178
+ { name: 'liquidationThresholds', type: 'uint256[]' },
179
+ { name: 'isDegenMode', type: 'bool' },
180
+ { name: 'degenNFT', type: 'address' },
181
+ { name: 'forbiddenTokenMask', type: 'uint256' },
182
+ { name: 'maxEnabledTokensLength', type: 'uint8' },
183
+ { name: 'feeInterest', type: 'uint16' },
184
+ { name: 'feeLiquidation', type: 'uint16' },
185
+ { name: 'liquidationDiscount', type: 'uint16' },
186
+ { name: 'feeLiquidationExpired', type: 'uint16' },
187
+ { name: 'liquidationDiscountExpired', type: 'uint16' },
188
+ QuotaInfo,
189
+ LinearModel,
190
+ { name: 'isPaused', type: 'bool' },
191
+ ],
192
+ name: 'result',
193
+ type: 'tuple[]',
194
+ },
195
+ ],
196
+ stateMutability: 'view',
197
+ type: 'function',
198
+ },
199
+ {
200
+ inputs: [{ name: 'borrower', type: 'address' }, PriceOnDemand],
201
+ name: 'getCreditAccountsByBorrower',
202
+ outputs: [
203
+ {
204
+ components: CreditAccountDataComponents,
205
+ name: 'result',
206
+ type: 'tuple[]',
207
+ },
208
+ ],
209
+ stateMutability: 'nonpayable',
210
+ type: 'function',
211
+ },
212
+ {
213
+ inputs: [{ name: '_creditAccount', type: 'address' }, PriceOnDemand],
214
+ name: 'getCreditAccountData',
215
+ outputs: [
216
+ {
217
+ components: CreditAccountDataComponents,
218
+ name: 'result',
219
+ type: 'tuple',
220
+ },
221
+ ],
222
+ stateMutability: 'nonpayable',
223
+ type: 'function',
224
+ },
225
+ ];
@@ -0,0 +1,7 @@
1
+ export { GearboxPoolV3Abi } from './poolV3.js';
2
+ export { GearboxCreditManagerV3Abi } from './creditManagerV3.js';
3
+ export { GearboxCreditFacadeV3Abi } from './creditFacadeV3.js';
4
+ export { GearboxPoolQuotaKeeperV3Abi } from './poolQuotaKeeperV3.js';
5
+ export { GearboxDataCompressorV3Abi } from './dataCompressorV3.js';
6
+ export { GearboxPriceOracleV3Abi } from './priceOracleV3.js';
7
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/gearbox/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,gBAAgB,EAAE,MAAM,aAAa,CAAA;AAC9C,OAAO,EAAE,yBAAyB,EAAE,MAAM,sBAAsB,CAAA;AAChE,OAAO,EAAE,wBAAwB,EAAE,MAAM,qBAAqB,CAAA;AAC9D,OAAO,EAAE,2BAA2B,EAAE,MAAM,wBAAwB,CAAA;AACpE,OAAO,EAAE,0BAA0B,EAAE,MAAM,uBAAuB,CAAA;AAClE,OAAO,EAAE,uBAAuB,EAAE,MAAM,oBAAoB,CAAA"}
@@ -0,0 +1,6 @@
1
+ export { GearboxPoolV3Abi } from './poolV3.js';
2
+ export { GearboxCreditManagerV3Abi } from './creditManagerV3.js';
3
+ export { GearboxCreditFacadeV3Abi } from './creditFacadeV3.js';
4
+ export { GearboxPoolQuotaKeeperV3Abi } from './poolQuotaKeeperV3.js';
5
+ export { GearboxDataCompressorV3Abi } from './dataCompressorV3.js';
6
+ export { GearboxPriceOracleV3Abi } from './priceOracleV3.js';
@@ -0,0 +1,65 @@
1
+ export declare const GearboxPoolQuotaKeeperV3Abi: readonly [{
2
+ readonly inputs: readonly [];
3
+ readonly name: "quotedTokens";
4
+ readonly outputs: readonly [{
5
+ readonly name: "";
6
+ readonly type: "address[]";
7
+ }];
8
+ readonly stateMutability: "view";
9
+ readonly type: "function";
10
+ }, {
11
+ readonly inputs: readonly [{
12
+ readonly name: "creditAccount";
13
+ readonly type: "address";
14
+ }, {
15
+ readonly name: "token";
16
+ readonly type: "address";
17
+ }];
18
+ readonly name: "getQuota";
19
+ readonly outputs: readonly [{
20
+ readonly name: "quota";
21
+ readonly type: "uint96";
22
+ }, {
23
+ readonly name: "cumulativeIndexLU";
24
+ readonly type: "uint192";
25
+ }];
26
+ readonly stateMutability: "view";
27
+ readonly type: "function";
28
+ }, {
29
+ readonly inputs: readonly [{
30
+ readonly name: "token";
31
+ readonly type: "address";
32
+ }];
33
+ readonly name: "getTokenQuotaParams";
34
+ readonly outputs: readonly [{
35
+ readonly name: "rate";
36
+ readonly type: "uint16";
37
+ }, {
38
+ readonly name: "cumulativeIndexLU";
39
+ readonly type: "uint192";
40
+ }, {
41
+ readonly name: "quotaIncreaseFee";
42
+ readonly type: "uint96";
43
+ }, {
44
+ readonly name: "totalQuoted";
45
+ readonly type: "uint96";
46
+ }, {
47
+ readonly name: "limit";
48
+ readonly type: "uint96";
49
+ }, {
50
+ readonly name: "isActive";
51
+ readonly type: "bool";
52
+ }];
53
+ readonly stateMutability: "view";
54
+ readonly type: "function";
55
+ }, {
56
+ readonly inputs: readonly [];
57
+ readonly name: "pool";
58
+ readonly outputs: readonly [{
59
+ readonly name: "";
60
+ readonly type: "address";
61
+ }];
62
+ readonly stateMutability: "view";
63
+ readonly type: "function";
64
+ }];
65
+ //# sourceMappingURL=poolQuotaKeeperV3.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"poolQuotaKeeperV3.d.ts","sourceRoot":"","sources":["../../src/gearbox/poolQuotaKeeperV3.ts"],"names":[],"mappings":"AASA,eAAO,MAAM,2BAA2B;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EA0C9B,CAAA"}
@@ -0,0 +1,52 @@
1
+ // Gearbox PoolQuotaKeeperV3 ABI — per-pool debt ceilings and quota management.
2
+ //
3
+ // Functions kept:
4
+ // - quotedTokens() -> address[]
5
+ // - getQuota(address, address) -> (uint96 quota, uint192 cumulativeIndexLU)
6
+ // - getTokenQuotaParams(address) -> (uint16 rate, uint192 cumulativeIndexLU, uint96 quotaIncreaseFee, uint96 totalQuoted, uint96 limit, bool isActive)
7
+ // - pool() -> address
8
+ //
9
+ // Source: Etherscan verified PoolQuotaKeeperV3 on Ethereum mainnet.
10
+ export const GearboxPoolQuotaKeeperV3Abi = [
11
+ {
12
+ inputs: [],
13
+ name: 'quotedTokens',
14
+ outputs: [{ name: '', type: 'address[]' }],
15
+ stateMutability: 'view',
16
+ type: 'function',
17
+ },
18
+ {
19
+ inputs: [
20
+ { name: 'creditAccount', type: 'address' },
21
+ { name: 'token', type: 'address' },
22
+ ],
23
+ name: 'getQuota',
24
+ outputs: [
25
+ { name: 'quota', type: 'uint96' },
26
+ { name: 'cumulativeIndexLU', type: 'uint192' },
27
+ ],
28
+ stateMutability: 'view',
29
+ type: 'function',
30
+ },
31
+ {
32
+ inputs: [{ name: 'token', type: 'address' }],
33
+ name: 'getTokenQuotaParams',
34
+ outputs: [
35
+ { name: 'rate', type: 'uint16' },
36
+ { name: 'cumulativeIndexLU', type: 'uint192' },
37
+ { name: 'quotaIncreaseFee', type: 'uint96' },
38
+ { name: 'totalQuoted', type: 'uint96' },
39
+ { name: 'limit', type: 'uint96' },
40
+ { name: 'isActive', type: 'bool' },
41
+ ],
42
+ stateMutability: 'view',
43
+ type: 'function',
44
+ },
45
+ {
46
+ inputs: [],
47
+ name: 'pool',
48
+ outputs: [{ name: '', type: 'address' }],
49
+ stateMutability: 'view',
50
+ type: 'function',
51
+ },
52
+ ];
@@ -0,0 +1,152 @@
1
+ export declare const GearboxPoolV3Abi: readonly [{
2
+ readonly inputs: readonly [];
3
+ readonly name: "totalAssets";
4
+ readonly outputs: readonly [{
5
+ readonly name: "";
6
+ readonly type: "uint256";
7
+ }];
8
+ readonly stateMutability: "view";
9
+ readonly type: "function";
10
+ }, {
11
+ readonly inputs: readonly [];
12
+ readonly name: "totalBorrowed";
13
+ readonly outputs: readonly [{
14
+ readonly name: "";
15
+ readonly type: "uint256";
16
+ }];
17
+ readonly stateMutability: "view";
18
+ readonly type: "function";
19
+ }, {
20
+ readonly inputs: readonly [];
21
+ readonly name: "availableLiquidity";
22
+ readonly outputs: readonly [{
23
+ readonly name: "";
24
+ readonly type: "uint256";
25
+ }];
26
+ readonly stateMutability: "view";
27
+ readonly type: "function";
28
+ }, {
29
+ readonly inputs: readonly [];
30
+ readonly name: "expectedLiquidity";
31
+ readonly outputs: readonly [{
32
+ readonly name: "";
33
+ readonly type: "uint256";
34
+ }];
35
+ readonly stateMutability: "view";
36
+ readonly type: "function";
37
+ }, {
38
+ readonly inputs: readonly [];
39
+ readonly name: "supplyRate";
40
+ readonly outputs: readonly [{
41
+ readonly name: "";
42
+ readonly type: "uint256";
43
+ }];
44
+ readonly stateMutability: "view";
45
+ readonly type: "function";
46
+ }, {
47
+ readonly inputs: readonly [];
48
+ readonly name: "baseInterestRate";
49
+ readonly outputs: readonly [{
50
+ readonly name: "";
51
+ readonly type: "uint256";
52
+ }];
53
+ readonly stateMutability: "view";
54
+ readonly type: "function";
55
+ }, {
56
+ readonly inputs: readonly [];
57
+ readonly name: "underlyingToken";
58
+ readonly outputs: readonly [{
59
+ readonly name: "";
60
+ readonly type: "address";
61
+ }];
62
+ readonly stateMutability: "view";
63
+ readonly type: "function";
64
+ }, {
65
+ readonly inputs: readonly [];
66
+ readonly name: "creditManagers";
67
+ readonly outputs: readonly [{
68
+ readonly name: "";
69
+ readonly type: "address[]";
70
+ }];
71
+ readonly stateMutability: "view";
72
+ readonly type: "function";
73
+ }, {
74
+ readonly inputs: readonly [];
75
+ readonly name: "poolQuotaKeeper";
76
+ readonly outputs: readonly [{
77
+ readonly name: "";
78
+ readonly type: "address";
79
+ }];
80
+ readonly stateMutability: "view";
81
+ readonly type: "function";
82
+ }, {
83
+ readonly inputs: readonly [];
84
+ readonly name: "withdrawFee";
85
+ readonly outputs: readonly [{
86
+ readonly name: "";
87
+ readonly type: "uint256";
88
+ }];
89
+ readonly stateMutability: "view";
90
+ readonly type: "function";
91
+ }, {
92
+ readonly inputs: readonly [];
93
+ readonly name: "symbol";
94
+ readonly outputs: readonly [{
95
+ readonly name: "";
96
+ readonly type: "string";
97
+ }];
98
+ readonly stateMutability: "view";
99
+ readonly type: "function";
100
+ }, {
101
+ readonly inputs: readonly [];
102
+ readonly name: "name";
103
+ readonly outputs: readonly [{
104
+ readonly name: "";
105
+ readonly type: "string";
106
+ }];
107
+ readonly stateMutability: "view";
108
+ readonly type: "function";
109
+ }, {
110
+ readonly inputs: readonly [];
111
+ readonly name: "decimals";
112
+ readonly outputs: readonly [{
113
+ readonly name: "";
114
+ readonly type: "uint8";
115
+ }];
116
+ readonly stateMutability: "view";
117
+ readonly type: "function";
118
+ }, {
119
+ readonly inputs: readonly [];
120
+ readonly name: "totalSupply";
121
+ readonly outputs: readonly [{
122
+ readonly name: "";
123
+ readonly type: "uint256";
124
+ }];
125
+ readonly stateMutability: "view";
126
+ readonly type: "function";
127
+ }, {
128
+ readonly inputs: readonly [{
129
+ readonly name: "owner";
130
+ readonly type: "address";
131
+ }];
132
+ readonly name: "maxWithdraw";
133
+ readonly outputs: readonly [{
134
+ readonly name: "";
135
+ readonly type: "uint256";
136
+ }];
137
+ readonly stateMutability: "view";
138
+ readonly type: "function";
139
+ }, {
140
+ readonly inputs: readonly [{
141
+ readonly name: "owner";
142
+ readonly type: "address";
143
+ }];
144
+ readonly name: "maxRedeem";
145
+ readonly outputs: readonly [{
146
+ readonly name: "";
147
+ readonly type: "uint256";
148
+ }];
149
+ readonly stateMutability: "view";
150
+ readonly type: "function";
151
+ }];
152
+ //# sourceMappingURL=poolV3.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"poolV3.d.ts","sourceRoot":"","sources":["../../src/gearbox/poolV3.ts"],"names":[],"mappings":"AAmBA,eAAO,MAAM,gBAAgB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAiHnB,CAAA"}
@@ -0,0 +1,133 @@
1
+ // Gearbox PoolV3 ABI — ERC-4626 vault for passive lenders.
2
+ //
3
+ // Functions kept:
4
+ // - totalAssets() -> uint256
5
+ // - totalBorrowed() -> uint256
6
+ // - availableLiquidity() -> uint256
7
+ // - expectedLiquidity() -> uint256
8
+ // - supplyRate() -> uint256 (RAY, 1e27)
9
+ // - baseInterestRate() -> uint256 (RAY, 1e27)
10
+ // - underlyingToken() -> address
11
+ // - creditManagers() -> address[]
12
+ // - poolQuotaKeeper() -> address
13
+ // - withdrawFee() -> uint256
14
+ // - symbol() -> string
15
+ // - name() -> string
16
+ // - decimals() -> uint8
17
+ // - totalSupply() -> uint256
18
+ //
19
+ // Source: Etherscan verified PoolV3 on Ethereum mainnet.
20
+ export const GearboxPoolV3Abi = [
21
+ {
22
+ inputs: [],
23
+ name: 'totalAssets',
24
+ outputs: [{ name: '', type: 'uint256' }],
25
+ stateMutability: 'view',
26
+ type: 'function',
27
+ },
28
+ {
29
+ inputs: [],
30
+ name: 'totalBorrowed',
31
+ outputs: [{ name: '', type: 'uint256' }],
32
+ stateMutability: 'view',
33
+ type: 'function',
34
+ },
35
+ {
36
+ inputs: [],
37
+ name: 'availableLiquidity',
38
+ outputs: [{ name: '', type: 'uint256' }],
39
+ stateMutability: 'view',
40
+ type: 'function',
41
+ },
42
+ {
43
+ inputs: [],
44
+ name: 'expectedLiquidity',
45
+ outputs: [{ name: '', type: 'uint256' }],
46
+ stateMutability: 'view',
47
+ type: 'function',
48
+ },
49
+ {
50
+ inputs: [],
51
+ name: 'supplyRate',
52
+ outputs: [{ name: '', type: 'uint256' }],
53
+ stateMutability: 'view',
54
+ type: 'function',
55
+ },
56
+ {
57
+ inputs: [],
58
+ name: 'baseInterestRate',
59
+ outputs: [{ name: '', type: 'uint256' }],
60
+ stateMutability: 'view',
61
+ type: 'function',
62
+ },
63
+ {
64
+ inputs: [],
65
+ name: 'underlyingToken',
66
+ outputs: [{ name: '', type: 'address' }],
67
+ stateMutability: 'view',
68
+ type: 'function',
69
+ },
70
+ {
71
+ inputs: [],
72
+ name: 'creditManagers',
73
+ outputs: [{ name: '', type: 'address[]' }],
74
+ stateMutability: 'view',
75
+ type: 'function',
76
+ },
77
+ {
78
+ inputs: [],
79
+ name: 'poolQuotaKeeper',
80
+ outputs: [{ name: '', type: 'address' }],
81
+ stateMutability: 'view',
82
+ type: 'function',
83
+ },
84
+ {
85
+ inputs: [],
86
+ name: 'withdrawFee',
87
+ outputs: [{ name: '', type: 'uint256' }],
88
+ stateMutability: 'view',
89
+ type: 'function',
90
+ },
91
+ {
92
+ inputs: [],
93
+ name: 'symbol',
94
+ outputs: [{ name: '', type: 'string' }],
95
+ stateMutability: 'view',
96
+ type: 'function',
97
+ },
98
+ {
99
+ inputs: [],
100
+ name: 'name',
101
+ outputs: [{ name: '', type: 'string' }],
102
+ stateMutability: 'view',
103
+ type: 'function',
104
+ },
105
+ {
106
+ inputs: [],
107
+ name: 'decimals',
108
+ outputs: [{ name: '', type: 'uint8' }],
109
+ stateMutability: 'view',
110
+ type: 'function',
111
+ },
112
+ {
113
+ inputs: [],
114
+ name: 'totalSupply',
115
+ outputs: [{ name: '', type: 'uint256' }],
116
+ stateMutability: 'view',
117
+ type: 'function',
118
+ },
119
+ {
120
+ inputs: [{ name: 'owner', type: 'address' }],
121
+ name: 'maxWithdraw',
122
+ outputs: [{ name: '', type: 'uint256' }],
123
+ stateMutability: 'view',
124
+ type: 'function',
125
+ },
126
+ {
127
+ inputs: [{ name: 'owner', type: 'address' }],
128
+ name: 'maxRedeem',
129
+ outputs: [{ name: '', type: 'uint256' }],
130
+ stateMutability: 'view',
131
+ type: 'function',
132
+ },
133
+ ];