@paraswap/dex-lib 3.11.5-cables.0 → 3.11.5-fluid-dex-changes.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/build/abi/fluid-dex/resolver.abi.json +731 -4
- package/build/dex/balancer-v2/balancer-v2.js +0 -1
- package/build/dex/balancer-v2/balancer-v2.js.map +1 -1
- package/build/dex/bebop/bebop.js +1 -1
- package/build/dex/bebop/bebop.js.map +1 -1
- package/build/dex/cables/cables.js +10 -2
- package/build/dex/cables/cables.js.map +1 -1
- package/build/dex/fluid-dex/config.js +1 -1
- package/build/dex/fluid-dex/fluid-dex-liquidity-proxy.js +28 -1
- package/build/dex/fluid-dex/fluid-dex-liquidity-proxy.js.map +1 -1
- package/build/dex/fluid-dex/fluid-dex.d.ts +17 -10
- package/build/dex/fluid-dex/fluid-dex.js +218 -67
- package/build/dex/fluid-dex/fluid-dex.js.map +1 -1
- package/build/dex/fluid-dex/types.d.ts +22 -2
- package/build/dex/index.js +0 -2
- package/build/dex/index.js.map +1 -1
- package/package.json +1 -1
- package/src/abi/fluid-dex/resolver.abi.json +731 -4
- package/src/dex/balancer-v2/balancer-v2-e2e.test.ts +0 -78
- package/src/dex/balancer-v2/balancer-v2.ts +0 -2
- package/src/dex/bebop/bebop.ts +1 -1
- package/src/dex/fluid-dex/config.ts +1 -1
- package/src/dex/fluid-dex/fluid-dex-e2e.test.ts +151 -3
- package/src/dex/fluid-dex/fluid-dex-events.test.ts +2 -4
- package/src/dex/fluid-dex/fluid-dex-integration.test.ts +79 -11
- package/src/dex/fluid-dex/fluid-dex-liquidity-proxy.ts +33 -0
- package/src/dex/fluid-dex/fluid-dex.ts +302 -104
- package/src/dex/fluid-dex/types.ts +25 -1
- package/src/dex/index.ts +0 -2
- package/tests/constants-e2e.ts +2 -2
- package/.env.example +0 -7
- package/src/abi/cables/CablesMainnetRFQ.json +0 -1083
- package/src/dex/cables/cables-e2e.test.ts +0 -171
- package/src/dex/cables/cables-integration.test.ts +0 -319
- package/src/dex/cables/cables.ts +0 -911
- package/src/dex/cables/config.ts +0 -13
- package/src/dex/cables/constants.ts +0 -35
- package/src/dex/cables/rate-fetcher.ts +0 -212
- package/src/dex/cables/types.ts +0 -128
- package/src/dex/cables/validators.test.ts +0 -151
- package/src/dex/cables/validators.ts +0 -61
|
@@ -5,9 +5,10 @@ export type PoolReserve = {
|
|
|
5
5
|
pool: string;
|
|
6
6
|
token0: string;
|
|
7
7
|
token1: string;
|
|
8
|
+
fee: number;
|
|
8
9
|
collateralReserves: CollateralReserves;
|
|
9
10
|
debtReserves: DebtReserves;
|
|
10
|
-
|
|
11
|
+
dexLimits: DexLimits;
|
|
11
12
|
};
|
|
12
13
|
|
|
13
14
|
export type PoolReserveResponse = [
|
|
@@ -17,8 +18,31 @@ export type PoolReserveResponse = [
|
|
|
17
18
|
BigNumber,
|
|
18
19
|
BigNumber[],
|
|
19
20
|
BigNumber[],
|
|
21
|
+
DexLimitResponse,
|
|
20
22
|
];
|
|
21
23
|
|
|
24
|
+
export type DexLimits = {
|
|
25
|
+
withdrawableToken0: TokenLimit;
|
|
26
|
+
withdrawableToken1: TokenLimit;
|
|
27
|
+
borrowableToken0: TokenLimit;
|
|
28
|
+
borrowableToken1: TokenLimit;
|
|
29
|
+
};
|
|
30
|
+
|
|
31
|
+
export type DexLimitResponse = [
|
|
32
|
+
TokenLimitResponse,
|
|
33
|
+
TokenLimitResponse,
|
|
34
|
+
TokenLimitResponse,
|
|
35
|
+
TokenLimitResponse,
|
|
36
|
+
];
|
|
37
|
+
|
|
38
|
+
export type TokenLimit = {
|
|
39
|
+
available: bigint;
|
|
40
|
+
expandsTo: bigint;
|
|
41
|
+
expandsDuration: bigint;
|
|
42
|
+
};
|
|
43
|
+
|
|
44
|
+
export type TokenLimitResponse = [bigint, bigint, bigint];
|
|
45
|
+
|
|
22
46
|
export type FluidDexLiquidityProxyState = {
|
|
23
47
|
poolsReserves: readonly PoolReserve[];
|
|
24
48
|
};
|
package/src/dex/index.ts
CHANGED
|
@@ -94,7 +94,6 @@ import { LitePsm } from './lite-psm/lite-psm';
|
|
|
94
94
|
import { UsualBond } from './usual-bond/usual-bond';
|
|
95
95
|
import { StkGHO } from './stkgho/stkgho';
|
|
96
96
|
import { SkyConverter } from './sky-converter/sky-converter';
|
|
97
|
-
import { Cables } from './cables/cables';
|
|
98
97
|
|
|
99
98
|
const LegacyDexes = [
|
|
100
99
|
CurveV2,
|
|
@@ -183,7 +182,6 @@ const Dexes = [
|
|
|
183
182
|
UsualBond,
|
|
184
183
|
StkGHO,
|
|
185
184
|
SkyConverter,
|
|
186
|
-
Cables,
|
|
187
185
|
FluidDex,
|
|
188
186
|
];
|
|
189
187
|
|
package/tests/constants-e2e.ts
CHANGED
|
@@ -1844,7 +1844,7 @@ export const Holders: {
|
|
|
1844
1844
|
BETS: '0x8cc2284c90d05578633418f9cde104f402375a65',
|
|
1845
1845
|
HATCHY: '0x14ec295ec8def851ec6e2959df872dd24e422631',
|
|
1846
1846
|
USDCe: '0x3a2434c698f8d79af1f5a9e43013157ca8b11a66',
|
|
1847
|
-
USDC: '
|
|
1847
|
+
USDC: '0xcc2da711D621A4491b338CAC88B9C0954db3e75B',
|
|
1848
1848
|
USDTe: '0x84d34f4f83a87596cd3fb6887cff8f17bf5a7b83',
|
|
1849
1849
|
WETHe: '0x9bdB521a97E95177BF252C253E256A60C3e14447',
|
|
1850
1850
|
POPS: '0x5268c2331658cb0b2858cfa9db27d8f22f5434bc',
|
|
@@ -1860,7 +1860,7 @@ export const Holders: {
|
|
|
1860
1860
|
TSD: '0x691A89db352B72dDb249bFe16503494eC0D920A4',
|
|
1861
1861
|
THO: '0xc40d16c47394a506d451475c8a7c46c1175c1da1',
|
|
1862
1862
|
aAvaUSDT: '0x50B1Ba98Cf117c9682048D56628B294ebbAA4ec2',
|
|
1863
|
-
USDT: '
|
|
1863
|
+
USDT: '0x0d0707963952f2fba59dd06f2b425ace40b492fe',
|
|
1864
1864
|
aAvaWAVAX: '0x1B18Df70863636AEe4BfBAb6F7C70ceBCA9bA404',
|
|
1865
1865
|
oldFRAX: '0x4e3376018add04ebe4c46bf6f924ddec8c67aa7b',
|
|
1866
1866
|
newFRAX: '0x4e3376018add04ebe4c46bf6f924ddec8c67aa7b',
|