@7kprotocol/sdk-ts 2.4.1 → 2.4.2-beta.1
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/README.md +30 -3
- package/lib/cjs/config/fetchClient.js +11 -19
- package/lib/cjs/config/index.js +22 -0
- package/lib/cjs/constants/_7k.js +6 -3
- package/lib/cjs/features/limitDca/cancelDcaOrder.js +7 -18
- package/lib/cjs/features/limitDca/cancelLimitOrder.js +7 -18
- package/lib/cjs/features/limitDca/claimExpiredLimitOrder.js +7 -18
- package/lib/cjs/features/limitDca/constants.js +1 -5
- package/lib/cjs/features/limitDca/getClosedDcaOrders.js +16 -27
- package/lib/cjs/features/limitDca/getClosedLimitOrders.js +15 -26
- package/lib/cjs/features/limitDca/getDcaOrderExecutions.js +16 -27
- package/lib/cjs/features/limitDca/getOpenDcaOrders.js +15 -26
- package/lib/cjs/features/limitDca/getOpenLimitOrders.js +15 -26
- package/lib/cjs/features/limitDca/placeDcaOrder.js +25 -36
- package/lib/cjs/features/limitDca/placeLimitOrder.js +14 -25
- package/lib/cjs/features/prices/index.js +47 -64
- package/lib/cjs/features/swap/buildTx.js +88 -39
- package/lib/cjs/features/swap/config.js +32 -32
- package/lib/cjs/features/swap/estimateGasFee.js +36 -46
- package/lib/cjs/features/swap/executeTx.js +52 -0
- package/lib/cjs/features/swap/getQuote.js +41 -31
- package/lib/cjs/features/swap/getSwapHistory.js +14 -25
- package/lib/cjs/features/swap/index.js +1 -0
- package/lib/cjs/index.js +16 -9
- package/lib/cjs/libs/getCoinOjectIdsByAmount.js +15 -24
- package/lib/cjs/libs/getSplitCoinForTx.js +8 -15
- package/lib/cjs/libs/groupSwapRoutes.js +10 -12
- package/lib/cjs/libs/protocols/aftermath/index.js +25 -36
- package/lib/cjs/libs/protocols/base.js +10 -3
- package/lib/cjs/libs/protocols/bluefin/index.js +26 -43
- package/lib/cjs/libs/protocols/bluefinx/client.js +35 -0
- package/lib/cjs/libs/protocols/bluefinx/index.js +48 -0
- package/lib/cjs/libs/protocols/bluefinx/types.js +10 -0
- package/lib/cjs/libs/protocols/bluemove/index.js +14 -25
- package/lib/cjs/libs/protocols/cetus/index.js +32 -43
- package/lib/cjs/libs/protocols/deepbookV3/sponsored.js +19 -30
- package/lib/cjs/libs/protocols/flowx/index.js +9 -20
- package/lib/cjs/libs/protocols/flowxV3/index.js +25 -39
- package/lib/cjs/libs/protocols/haedal_pmm/index.js +33 -0
- package/lib/cjs/libs/protocols/index.js +7 -2
- package/lib/cjs/libs/protocols/kriya/index.js +20 -31
- package/lib/cjs/libs/protocols/kriyaV3/index.js +54 -65
- package/lib/cjs/libs/protocols/magma/index.js +28 -40
- package/lib/cjs/libs/protocols/momentum/index.js +49 -0
- package/lib/cjs/libs/protocols/obric/index.js +20 -31
- package/lib/cjs/libs/protocols/springsui/index.js +14 -25
- package/lib/cjs/libs/protocols/steamm/index.js +57 -58
- package/lib/cjs/libs/protocols/stsui/index.js +14 -25
- package/lib/cjs/libs/protocols/suiswap/index.js +23 -34
- package/lib/cjs/libs/protocols/turbos/index.js +23 -38
- package/lib/cjs/libs/protocols/utils.js +1 -5
- package/lib/cjs/libs/swapWithRoute.js +17 -27
- package/lib/cjs/types/aggregator.js +17 -0
- package/lib/cjs/types/config/index.d.ts +9 -0
- package/lib/cjs/types/config/index.d.ts.map +1 -1
- package/lib/cjs/types/constants/_7k.d.ts +3 -3
- package/lib/cjs/types/constants/_7k.d.ts.map +1 -1
- package/lib/cjs/types/features/limitDca/constants.d.ts +1 -2
- package/lib/cjs/types/features/limitDca/constants.d.ts.map +1 -1
- package/lib/cjs/types/features/swap/buildTx.d.ts +2 -5
- package/lib/cjs/types/features/swap/buildTx.d.ts.map +1 -1
- package/lib/cjs/types/features/swap/config.d.ts.map +1 -1
- package/lib/cjs/types/features/swap/estimateGasFee.d.ts.map +1 -1
- package/lib/cjs/types/features/swap/executeTx.d.ts +24 -0
- package/lib/cjs/types/features/swap/executeTx.d.ts.map +1 -0
- package/lib/cjs/types/features/swap/getQuote.d.ts +8 -1
- package/lib/cjs/types/features/swap/getQuote.d.ts.map +1 -1
- package/lib/cjs/types/features/swap/index.d.ts +1 -0
- package/lib/cjs/types/features/swap/index.d.ts.map +1 -1
- package/lib/cjs/types/index.d.ts +13 -8
- package/lib/cjs/types/index.d.ts.map +1 -1
- package/lib/cjs/types/libs/getCoinOjectIdsByAmount.d.ts.map +1 -1
- package/lib/cjs/types/libs/getSplitCoinForTx.d.ts.map +1 -1
- package/lib/cjs/types/libs/groupSwapRoutes.d.ts.map +1 -1
- package/lib/cjs/types/libs/protocols/base.d.ts +6 -2
- package/lib/cjs/types/libs/protocols/base.d.ts.map +1 -1
- package/lib/cjs/types/libs/protocols/bluefin/index.d.ts.map +1 -1
- package/lib/cjs/types/libs/protocols/bluefinx/client.d.ts +13 -0
- package/lib/cjs/types/libs/protocols/bluefinx/client.d.ts.map +1 -0
- package/lib/cjs/types/libs/protocols/bluefinx/index.d.ts +17 -0
- package/lib/cjs/types/libs/protocols/bluefinx/index.d.ts.map +1 -0
- package/lib/cjs/types/libs/protocols/bluefinx/types.d.ts +34 -0
- package/lib/cjs/types/libs/protocols/bluefinx/types.d.ts.map +1 -0
- package/lib/cjs/types/libs/protocols/cetus/index.d.ts.map +1 -1
- package/lib/cjs/types/libs/protocols/deepbookV3/sponsored.d.ts.map +1 -1
- package/lib/cjs/types/libs/protocols/flowxV3/index.d.ts.map +1 -1
- package/lib/{esm/types/libs/protocols/deepbook → cjs/types/libs/protocols/haedal_pmm}/index.d.ts +1 -3
- package/lib/cjs/types/libs/protocols/haedal_pmm/index.d.ts.map +1 -0
- package/lib/cjs/types/libs/protocols/index.d.ts +7 -2
- package/lib/cjs/types/libs/protocols/index.d.ts.map +1 -1
- package/lib/cjs/types/libs/protocols/magma/index.d.ts.map +1 -1
- package/lib/cjs/types/libs/protocols/{deepbook → momentum}/index.d.ts +1 -3
- package/lib/cjs/types/libs/protocols/momentum/index.d.ts.map +1 -0
- package/lib/cjs/types/libs/protocols/steamm/index.d.ts +13 -2
- package/lib/cjs/types/libs/protocols/steamm/index.d.ts.map +1 -1
- package/lib/cjs/types/libs/protocols/suiswap/index.d.ts.map +1 -1
- package/lib/cjs/types/libs/protocols/turbos/index.d.ts.map +1 -1
- package/lib/cjs/types/libs/protocols/utils.d.ts +1 -2
- package/lib/cjs/types/libs/protocols/utils.d.ts.map +1 -1
- package/lib/cjs/types/libs/swapWithRoute.d.ts +3 -1
- package/lib/cjs/types/libs/swapWithRoute.d.ts.map +1 -1
- package/lib/cjs/types/types/aggregator.d.ts +36 -2
- package/lib/cjs/types/types/aggregator.d.ts.map +1 -1
- package/lib/cjs/types/types/tx.d.ts +1 -2
- package/lib/cjs/types/types/tx.d.ts.map +1 -1
- package/lib/cjs/types/utils/number.d.ts +1 -3
- package/lib/cjs/types/utils/number.d.ts.map +1 -1
- package/lib/cjs/types/utils/sui.d.ts +1 -1
- package/lib/cjs/types/utils/sui.d.ts.map +1 -1
- package/lib/cjs/utils/number.js +4 -10
- package/lib/cjs/utils/sui.js +71 -80
- package/lib/esm/config/index.js +22 -0
- package/lib/esm/constants/_7k.js +6 -3
- package/lib/esm/features/limitDca/constants.js +1 -2
- package/lib/esm/features/swap/buildTx.js +81 -20
- package/lib/esm/features/swap/config.js +19 -8
- package/lib/esm/features/swap/estimateGasFee.js +13 -9
- package/lib/esm/features/swap/executeTx.js +48 -0
- package/lib/esm/features/swap/getQuote.js +24 -3
- package/lib/esm/features/swap/index.js +1 -0
- package/lib/esm/index.mjs +8 -4
- package/lib/esm/libs/getCoinOjectIdsByAmount.js +7 -7
- package/lib/esm/libs/getSplitCoinForTx.js +4 -2
- package/lib/esm/libs/groupSwapRoutes.js +1 -2
- package/lib/esm/libs/protocols/base.js +10 -1
- package/lib/esm/libs/protocols/bluefin/index.js +2 -5
- package/lib/esm/libs/protocols/bluefinx/client.js +30 -0
- package/lib/esm/libs/protocols/bluefinx/index.js +44 -0
- package/lib/esm/libs/protocols/bluefinx/types.js +8 -0
- package/lib/esm/libs/protocols/cetus/index.js +1 -1
- package/lib/esm/libs/protocols/deepbookV3/sponsored.js +1 -1
- package/lib/esm/libs/protocols/flowxV3/index.js +1 -4
- package/lib/esm/libs/protocols/haedal_pmm/index.js +29 -0
- package/lib/esm/libs/protocols/index.js +7 -2
- package/lib/esm/libs/protocols/magma/index.js +1 -2
- package/lib/esm/libs/protocols/momentum/index.js +45 -0
- package/lib/esm/libs/protocols/steamm/index.js +58 -48
- package/lib/esm/libs/protocols/suiswap/index.js +1 -1
- package/lib/esm/libs/protocols/turbos/index.js +2 -6
- package/lib/esm/libs/protocols/utils.js +1 -2
- package/lib/esm/libs/swapWithRoute.js +2 -1
- package/lib/esm/types/aggregator.js +14 -1
- package/lib/esm/types/config/index.d.ts +9 -0
- package/lib/esm/types/config/index.d.ts.map +1 -1
- package/lib/esm/types/constants/_7k.d.ts +3 -3
- package/lib/esm/types/constants/_7k.d.ts.map +1 -1
- package/lib/esm/types/features/limitDca/constants.d.ts +1 -2
- package/lib/esm/types/features/limitDca/constants.d.ts.map +1 -1
- package/lib/esm/types/features/swap/buildTx.d.ts +2 -5
- package/lib/esm/types/features/swap/buildTx.d.ts.map +1 -1
- package/lib/esm/types/features/swap/config.d.ts.map +1 -1
- package/lib/esm/types/features/swap/estimateGasFee.d.ts.map +1 -1
- package/lib/esm/types/features/swap/executeTx.d.ts +24 -0
- package/lib/esm/types/features/swap/executeTx.d.ts.map +1 -0
- package/lib/esm/types/features/swap/getQuote.d.ts +8 -1
- package/lib/esm/types/features/swap/getQuote.d.ts.map +1 -1
- package/lib/esm/types/features/swap/index.d.ts +1 -0
- package/lib/esm/types/features/swap/index.d.ts.map +1 -1
- package/lib/esm/types/index.d.ts +13 -8
- package/lib/esm/types/index.d.ts.map +1 -1
- package/lib/esm/types/libs/getCoinOjectIdsByAmount.d.ts.map +1 -1
- package/lib/esm/types/libs/getSplitCoinForTx.d.ts.map +1 -1
- package/lib/esm/types/libs/groupSwapRoutes.d.ts.map +1 -1
- package/lib/esm/types/libs/protocols/base.d.ts +6 -2
- package/lib/esm/types/libs/protocols/base.d.ts.map +1 -1
- package/lib/esm/types/libs/protocols/bluefin/index.d.ts.map +1 -1
- package/lib/esm/types/libs/protocols/bluefinx/client.d.ts +13 -0
- package/lib/esm/types/libs/protocols/bluefinx/client.d.ts.map +1 -0
- package/lib/esm/types/libs/protocols/bluefinx/index.d.ts +17 -0
- package/lib/esm/types/libs/protocols/bluefinx/index.d.ts.map +1 -0
- package/lib/esm/types/libs/protocols/bluefinx/types.d.ts +34 -0
- package/lib/esm/types/libs/protocols/bluefinx/types.d.ts.map +1 -0
- package/lib/esm/types/libs/protocols/cetus/index.d.ts.map +1 -1
- package/lib/esm/types/libs/protocols/deepbookV3/sponsored.d.ts.map +1 -1
- package/lib/esm/types/libs/protocols/flowxV3/index.d.ts.map +1 -1
- package/lib/esm/types/libs/protocols/haedal_pmm/index.d.ts +9 -0
- package/lib/esm/types/libs/protocols/haedal_pmm/index.d.ts.map +1 -0
- package/lib/esm/types/libs/protocols/index.d.ts +7 -2
- package/lib/esm/types/libs/protocols/index.d.ts.map +1 -1
- package/lib/esm/types/libs/protocols/magma/index.d.ts.map +1 -1
- package/lib/esm/types/libs/protocols/momentum/index.d.ts +9 -0
- package/lib/esm/types/libs/protocols/momentum/index.d.ts.map +1 -0
- package/lib/esm/types/libs/protocols/steamm/index.d.ts +13 -2
- package/lib/esm/types/libs/protocols/steamm/index.d.ts.map +1 -1
- package/lib/esm/types/libs/protocols/suiswap/index.d.ts.map +1 -1
- package/lib/esm/types/libs/protocols/turbos/index.d.ts.map +1 -1
- package/lib/esm/types/libs/protocols/utils.d.ts +1 -2
- package/lib/esm/types/libs/protocols/utils.d.ts.map +1 -1
- package/lib/esm/types/libs/swapWithRoute.d.ts +3 -1
- package/lib/esm/types/libs/swapWithRoute.d.ts.map +1 -1
- package/lib/esm/types/types/aggregator.d.ts +36 -2
- package/lib/esm/types/types/aggregator.d.ts.map +1 -1
- package/lib/esm/types/types/tx.d.ts +1 -2
- package/lib/esm/types/types/tx.d.ts.map +1 -1
- package/lib/esm/types/utils/number.d.ts +1 -3
- package/lib/esm/types/utils/number.d.ts.map +1 -1
- package/lib/esm/types/utils/sui.d.ts +1 -1
- package/lib/esm/types/utils/sui.d.ts.map +1 -1
- package/lib/esm/utils/number.js +4 -6
- package/lib/esm/utils/sui.js +4 -3
- package/package.json +14 -15
- package/lib/cjs/libs/protocols/deepbook/index.js +0 -96
- package/lib/cjs/types/libs/protocols/deepbook/index.d.ts.map +0 -1
- package/lib/esm/libs/protocols/deepbook/index.js +0 -80
- package/lib/esm/types/libs/protocols/deepbook/index.d.ts.map +0 -1
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { Transaction } from "@mysten/sui/transactions";
|
|
2
|
+
import { BaseContract } from "../base";
|
|
3
|
+
export declare class HaedalPMMContract extends BaseContract {
|
|
4
|
+
swap(tx: Transaction): Promise<{
|
|
5
|
+
$kind: "NestedResult";
|
|
6
|
+
NestedResult: [number, number];
|
|
7
|
+
}>;
|
|
8
|
+
}
|
|
9
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../../src/libs/protocols/haedal_pmm/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAE,MAAM,0BAA0B,CAAC;AAEvD,OAAO,EAAE,YAAY,EAAE,MAAM,SAAS,CAAC;AAOvC,qBAAa,iBAAkB,SAAQ,YAAY;IAC3C,IAAI,CAAC,EAAE,EAAE,WAAW;;;;CA4B3B"}
|
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
import { FlowXContract } from "./flowx";
|
|
2
2
|
import { AfterMathContract } from "./aftermath";
|
|
3
3
|
import { CetusContract } from "./cetus";
|
|
4
|
-
import { DeepBookContract } from "./deepbook";
|
|
5
4
|
import { KriyaContract } from "./kriya";
|
|
6
5
|
import { TurbosContract } from "./turbos";
|
|
7
6
|
import { SuiswapContract } from "./suiswap";
|
|
@@ -15,6 +14,9 @@ import { StSuiContract } from "./stsui";
|
|
|
15
14
|
import { FlowxV3Contract } from "./flowxV3";
|
|
16
15
|
import { SteammContract } from "./steamm";
|
|
17
16
|
import { MagmaContract } from "./magma";
|
|
17
|
+
import { HaedalPMMContract } from "./haedal_pmm";
|
|
18
|
+
import { MomentumContract } from "./momentum";
|
|
19
|
+
import { BluefinXContract } from "./bluefinx";
|
|
18
20
|
export declare const ProtocolContract: {
|
|
19
21
|
cetus: typeof CetusContract;
|
|
20
22
|
turbos: typeof TurbosContract;
|
|
@@ -22,7 +24,6 @@ export declare const ProtocolContract: {
|
|
|
22
24
|
kriya: typeof KriyaContract;
|
|
23
25
|
suiswap: typeof SuiswapContract;
|
|
24
26
|
aftermath: typeof AfterMathContract;
|
|
25
|
-
deepbook: typeof DeepBookContract;
|
|
26
27
|
deepbook_v3: typeof SponsoredDeepBookV3Contract;
|
|
27
28
|
flowx: typeof FlowXContract;
|
|
28
29
|
flowx_v3: typeof FlowxV3Contract;
|
|
@@ -32,6 +33,10 @@ export declare const ProtocolContract: {
|
|
|
32
33
|
obric: typeof ObricContract;
|
|
33
34
|
stsui: typeof StSuiContract;
|
|
34
35
|
steamm: typeof SteammContract;
|
|
36
|
+
steamm_oracle_quoter: typeof SteammContract;
|
|
35
37
|
magma: typeof MagmaContract;
|
|
38
|
+
haedal_pmm: typeof HaedalPMMContract;
|
|
39
|
+
momentum: typeof MomentumContract;
|
|
40
|
+
bluefinx: typeof BluefinXContract;
|
|
36
41
|
};
|
|
37
42
|
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/libs/protocols/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,aAAa,EAAE,MAAM,SAAS,CAAC;AACxC,OAAO,EAAE,iBAAiB,EAAE,MAAM,aAAa,C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"","sources":["../../../../../../src/libs/protocols/magma/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAE,MAAM,0BAA0B,CAAC;AACvD,OAAO,EAAE,YAAY,EAAE,MAAM,SAAS,CAAC;AAMvC,qBAAa,aAAc,SAAQ,YAAY;IACvC,IAAI,CAAC,EAAE,EAAE,WAAW;;;;
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../../src/libs/protocols/magma/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAE,MAAM,0BAA0B,CAAC;AACvD,OAAO,EAAE,YAAY,EAAE,MAAM,SAAS,CAAC;AAMvC,qBAAa,aAAc,SAAQ,YAAY;IACvC,IAAI,CAAC,EAAE,EAAE,WAAW;;;;CAuC3B"}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { Transaction } from "@mysten/sui/transactions";
|
|
2
|
+
import { BaseContract } from "../base";
|
|
3
|
+
export declare class MomentumContract extends BaseContract {
|
|
4
|
+
swap(tx: Transaction): Promise<{
|
|
5
|
+
$kind: "NestedResult";
|
|
6
|
+
NestedResult: [number, number];
|
|
7
|
+
}>;
|
|
8
|
+
}
|
|
9
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../../src/libs/protocols/momentum/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAE,MAAM,0BAA0B,CAAC;AACvD,OAAO,EAAE,YAAY,EAAE,MAAM,SAAS,CAAC;AAMvC,qBAAa,gBAAiB,SAAQ,YAAY;IAC1C,IAAI,CAAC,EAAE,EAAE,WAAW;;;;CA4C3B"}
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { Transaction } from "@mysten/sui/transactions";
|
|
2
2
|
import { BaseContract } from "../base";
|
|
3
|
+
import { ExtraOracle } from "../../../types/aggregator";
|
|
3
4
|
export type SteamExtra = {
|
|
4
5
|
bankAStructTag: string;
|
|
5
6
|
bankBStructTag: string;
|
|
@@ -8,8 +9,11 @@ export type SteamExtra = {
|
|
|
8
9
|
bankB: string;
|
|
9
10
|
lendingMarketA: string;
|
|
10
11
|
lendingMarketB: string;
|
|
12
|
+
oracleRegistry?: string;
|
|
13
|
+
oracles?: ExtraOracle[];
|
|
14
|
+
oracleIndexes?: number[];
|
|
11
15
|
};
|
|
12
|
-
export declare class SteammContract extends BaseContract {
|
|
16
|
+
export declare class SteammContract extends BaseContract<SteamExtra> {
|
|
13
17
|
swap(tx: Transaction): Promise<{
|
|
14
18
|
$kind: "NestedResult";
|
|
15
19
|
NestedResult: [number, number];
|
|
@@ -18,9 +22,16 @@ export declare class SteammContract extends BaseContract {
|
|
|
18
22
|
$kind: "NestedResult";
|
|
19
23
|
NestedResult: [number, number];
|
|
20
24
|
};
|
|
21
|
-
|
|
25
|
+
ommSwap(tx: Transaction): {
|
|
22
26
|
$kind: "NestedResult";
|
|
23
27
|
NestedResult: [number, number];
|
|
24
28
|
};
|
|
29
|
+
getOraclePriceUpdate(tx: Transaction): readonly [{
|
|
30
|
+
$kind: "NestedResult";
|
|
31
|
+
NestedResult: [number, number];
|
|
32
|
+
}, {
|
|
33
|
+
$kind: "NestedResult";
|
|
34
|
+
NestedResult: [number, number];
|
|
35
|
+
}];
|
|
25
36
|
}
|
|
26
37
|
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../../src/libs/protocols/steamm/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAE,MAAM,0BAA0B,CAAC;AACvD,OAAO,EAAE,YAAY,EAAE,MAAM,SAAS,CAAC;AAQvC,MAAM,MAAM,UAAU,GAAG;IACvB,cAAc,EAAE,MAAM,CAAC;IACvB,cAAc,EAAE,MAAM,CAAC;IACvB,aAAa,EAAE,MAAM,CAAC;IACtB,KAAK,EAAE,MAAM,CAAC;IACd,KAAK,EAAE,MAAM,CAAC;IACd,cAAc,EAAE,MAAM,CAAC;IACvB,cAAc,EAAE,MAAM,CAAC;
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../../src/libs/protocols/steamm/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAE,MAAM,0BAA0B,CAAC;AACvD,OAAO,EAAE,YAAY,EAAE,MAAM,SAAS,CAAC;AAQvC,OAAO,EAAE,WAAW,EAAE,MAAM,2BAA2B,CAAC;AAExD,MAAM,MAAM,UAAU,GAAG;IACvB,cAAc,EAAE,MAAM,CAAC;IACvB,cAAc,EAAE,MAAM,CAAC;IACvB,aAAa,EAAE,MAAM,CAAC;IACtB,KAAK,EAAE,MAAM,CAAC;IACd,KAAK,EAAE,MAAM,CAAC;IACd,cAAc,EAAE,MAAM,CAAC;IACvB,cAAc,EAAE,MAAM,CAAC;IACvB,cAAc,CAAC,EAAE,MAAM,CAAC;IACxB,OAAO,CAAC,EAAE,WAAW,EAAE,CAAC;IACxB,aAAa,CAAC,EAAE,MAAM,EAAE,CAAC;CAC1B,CAAC;AACF,qBAAa,cAAe,SAAQ,YAAY,CAAC,UAAU,CAAC;IACpD,IAAI,CAAC,EAAE,EAAE,WAAW;;;;IAS1B,QAAQ,CAAC,EAAE,EAAE,WAAW;;;;IAmExB,OAAO,CAAC,EAAE,EAAE,WAAW;;;;IAqEvB,oBAAoB,CAAC,EAAE,EAAE,WAAW;;;;;;;CA8BrC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../../src/libs/protocols/suiswap/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAE,MAAM,0BAA0B,CAAC;AAGvD,OAAO,EAAE,YAAY,EAAE,MAAM,SAAS,CAAC;AAGvC,qBAAa,eAAgB,SAAQ,YAAY;IACzC,IAAI,CAAC,EAAE,EAAE,WAAW;;;;
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../../src/libs/protocols/suiswap/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAE,MAAM,0BAA0B,CAAC;AAGvD,OAAO,EAAE,YAAY,EAAE,MAAM,SAAS,CAAC;AAGvC,qBAAa,eAAgB,SAAQ,YAAY;IACzC,IAAI,CAAC,EAAE,EAAE,WAAW;;;;CA2B3B"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../../src/libs/protocols/turbos/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAE,MAAM,0BAA0B,CAAC;AAGvD,OAAO,EAAE,YAAY,EAAE,MAAM,SAAS,CAAC;AAMvC,qBAAa,cAAe,SAAQ,YAAY;IACxC,IAAI,CAAC,EAAE,EAAE,WAAW;;;;
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../../src/libs/protocols/turbos/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAE,MAAM,0BAA0B,CAAC;AAGvD,OAAO,EAAE,YAAY,EAAE,MAAM,SAAS,CAAC;AAMvC,qBAAa,cAAe,SAAQ,YAAY;IACxC,IAAI,CAAC,EAAE,EAAE,WAAW;;;;CA+B3B"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"utils.d.ts","sourceRoot":"","sources":["../../../../../src/libs/protocols/utils.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"utils.d.ts","sourceRoot":"","sources":["../../../../../src/libs/protocols/utils.ts"],"names":[],"mappings":"AAEA,wBAAgB,wBAAwB,CAAC,GAAG,EAAE,OAAO,GAAG,MAAM,CAE7D"}
|
|
@@ -1,11 +1,13 @@
|
|
|
1
1
|
import { Transaction } from "@mysten/sui/transactions";
|
|
2
2
|
import { Config, TxSorSwap } from "../types/aggregator";
|
|
3
3
|
import { TransactionResultItem } from "../types/sui";
|
|
4
|
-
export declare function swapWithRoute({ route, inputCoinObject, currentAccount, config, tx, }: {
|
|
4
|
+
export declare function swapWithRoute({ route, inputCoinObject, currentAccount, config, pythMap, tx, }: {
|
|
5
5
|
route: TxSorSwap[];
|
|
6
6
|
inputCoinObject: TransactionResultItem;
|
|
7
7
|
currentAccount: string;
|
|
8
8
|
config: Config;
|
|
9
|
+
/** map price feed id to onchain priceInfoObject id */
|
|
10
|
+
pythMap: Record<string, string>;
|
|
9
11
|
tx: Transaction;
|
|
10
12
|
}): Promise<TransactionResultItem | undefined>;
|
|
11
13
|
//# sourceMappingURL=swapWithRoute.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"swapWithRoute.d.ts","sourceRoot":"","sources":["../../../../src/libs/swapWithRoute.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAE,MAAM,0BAA0B,CAAC;AAEvD,OAAO,EAAE,MAAM,EAAE,SAAS,EAAE,MAAM,qBAAqB,CAAC;AACxD,OAAO,EAAE,qBAAqB,EAAE,MAAM,cAAc,CAAC;AAErD,wBAAsB,aAAa,CAAC,EAClC,KAAK,EACL,eAAe,EACf,cAAc,EACd,MAAM,EACN,EAAE,GACH,EAAE;IACD,KAAK,EAAE,SAAS,EAAE,CAAC;IACnB,eAAe,EAAE,qBAAqB,CAAC;IACvC,cAAc,EAAE,MAAM,CAAC;IACvB,MAAM,EAAE,MAAM,CAAC;IACf,EAAE,EAAE,WAAW,CAAC;CACjB,GAAG,OAAO,CAAC,qBAAqB,GAAG,SAAS,CAAC,
|
|
1
|
+
{"version":3,"file":"swapWithRoute.d.ts","sourceRoot":"","sources":["../../../../src/libs/swapWithRoute.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAE,MAAM,0BAA0B,CAAC;AAEvD,OAAO,EAAE,MAAM,EAAE,SAAS,EAAE,MAAM,qBAAqB,CAAC;AACxD,OAAO,EAAE,qBAAqB,EAAE,MAAM,cAAc,CAAC;AAErD,wBAAsB,aAAa,CAAC,EAClC,KAAK,EACL,eAAe,EACf,cAAc,EACd,MAAM,EACN,OAAO,EACP,EAAE,GACH,EAAE;IACD,KAAK,EAAE,SAAS,EAAE,CAAC;IACnB,eAAe,EAAE,qBAAqB,CAAC;IACvC,cAAc,EAAE,MAAM,CAAC;IACvB,MAAM,EAAE,MAAM,CAAC;IACf,sDAAsD;IACtD,OAAO,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC;IAChC,EAAE,EAAE,WAAW,CAAC;CACjB,GAAG,OAAO,CAAC,qBAAqB,GAAG,SAAS,CAAC,CAmB7C"}
|
|
@@ -1,4 +1,7 @@
|
|
|
1
|
-
|
|
1
|
+
import { Transaction, TransactionObjectArgument } from "@mysten/sui/transactions";
|
|
2
|
+
import { BluefinXTx } from "../libs/protocols/bluefinx/types";
|
|
3
|
+
export { BluefinXTx };
|
|
4
|
+
export type SourceDex = "suiswap" | "turbos" | "cetus" | "bluemove" | "kriya" | "kriya_v3" | "aftermath" | "deepbook_v3" | "flowx" | "flowx_v3" | "bluefin" | "bluefinx" | "springsui" | "obric" | "stsui" | "steamm" | "steamm_oracle_quoter" | "magma" | "haedal_pmm" | "momentum";
|
|
2
5
|
export type SorSwap = {
|
|
3
6
|
poolId: string;
|
|
4
7
|
assetInIndex: number;
|
|
@@ -41,6 +44,8 @@ export type QuoteResponse = {
|
|
|
41
44
|
swapAmount: string;
|
|
42
45
|
returnAmount: string;
|
|
43
46
|
returnAmountWithDecimal: string;
|
|
47
|
+
returnAmountAfterCommission: string;
|
|
48
|
+
returnAmountAfterCommissionWithDecimal: string;
|
|
44
49
|
returnAmountConsiderGasFees?: string;
|
|
45
50
|
returnAmountWithoutSwapFees?: string;
|
|
46
51
|
swapAmountWithDecimal: string;
|
|
@@ -83,13 +88,15 @@ export interface Config {
|
|
|
83
88
|
bluefin: DexConfig & {
|
|
84
89
|
globalConfig: string;
|
|
85
90
|
};
|
|
91
|
+
bluefinx: DexConfig & {
|
|
92
|
+
globalConfig: string;
|
|
93
|
+
};
|
|
86
94
|
bluemove: DexConfig & {
|
|
87
95
|
dexInfo: string;
|
|
88
96
|
};
|
|
89
97
|
cetus: DexConfig & {
|
|
90
98
|
globalConfig: string;
|
|
91
99
|
};
|
|
92
|
-
deepbook: DexConfig;
|
|
93
100
|
deepbook_v3: DexConfig & {
|
|
94
101
|
sponsor: string;
|
|
95
102
|
sponsorFund: string;
|
|
@@ -116,9 +123,36 @@ export interface Config {
|
|
|
116
123
|
};
|
|
117
124
|
steamm: DexConfig & {
|
|
118
125
|
script: string;
|
|
126
|
+
oracle: string;
|
|
119
127
|
};
|
|
120
128
|
magma: DexConfig & {
|
|
121
129
|
globalConfig: string;
|
|
122
130
|
};
|
|
131
|
+
haedal_pmm: DexConfig;
|
|
132
|
+
momentum: DexConfig & {
|
|
133
|
+
version: string;
|
|
134
|
+
};
|
|
123
135
|
}
|
|
136
|
+
export type ExtraOracle = {
|
|
137
|
+
Pyth?: {
|
|
138
|
+
price_identifier: {
|
|
139
|
+
bytes: number[];
|
|
140
|
+
};
|
|
141
|
+
};
|
|
142
|
+
Switchboard?: {
|
|
143
|
+
object_id: string;
|
|
144
|
+
};
|
|
145
|
+
};
|
|
146
|
+
export type AggregatorTx = Transaction | BluefinXTx;
|
|
147
|
+
export declare const isSuiTransaction: (tx: AggregatorTx) => tx is Transaction;
|
|
148
|
+
/**
|
|
149
|
+
* Check if the sor response is a bluefinx routing
|
|
150
|
+
* @param sor
|
|
151
|
+
* @returns boolean
|
|
152
|
+
*/
|
|
153
|
+
export declare const isBluefinXRouting: (sor: QuoteResponse) => boolean;
|
|
154
|
+
export type BuildTxResult = {
|
|
155
|
+
tx: AggregatorTx;
|
|
156
|
+
coinOut?: TransactionObjectArgument;
|
|
157
|
+
};
|
|
124
158
|
//# sourceMappingURL=aggregator.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"aggregator.d.ts","sourceRoot":"","sources":["../../../../src/types/aggregator.ts"],"names":[],"mappings":"AAAA,MAAM,MAAM,SAAS,GACjB,SAAS,GACT,QAAQ,GACR,OAAO,GACP,UAAU,GACV,OAAO,GACP,UAAU,GACV,WAAW,GACX,
|
|
1
|
+
{"version":3,"file":"aggregator.d.ts","sourceRoot":"","sources":["../../../../src/types/aggregator.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,WAAW,EACX,yBAAyB,EAC1B,MAAM,0BAA0B,CAAC;AAClC,OAAO,EAAE,UAAU,EAAE,MAAM,kCAAkC,CAAC;AAC9D,OAAO,EAAE,UAAU,EAAE,CAAC;AAEtB,MAAM,MAAM,SAAS,GACjB,SAAS,GACT,QAAQ,GACR,OAAO,GACP,UAAU,GACV,OAAO,GACP,UAAU,GACV,WAAW,GACX,aAAa,GACb,OAAO,GACP,UAAU,GACV,SAAS,GACT,UAAU,GACV,WAAW,GACX,OAAO,GACP,OAAO,GACP,QAAQ,GACR,sBAAsB,GACtB,OAAO,GACP,YAAY,GACZ,UAAU,CAAC;AAEf,MAAM,MAAM,OAAO,GAAG;IACpB,MAAM,EAAE,MAAM,CAAC;IACf,YAAY,EAAE,MAAM,CAAC;IACrB,aAAa,EAAE,MAAM,CAAC;IACtB,MAAM,EAAE,MAAM,CAAC;IACf,YAAY,EAAE,MAAM,CAAC;IACrB,OAAO,EAAE,MAAM,CAAC;IAChB,QAAQ,EAAE,MAAM,CAAC;IACjB,YAAY,EAAE,MAAM,CAAC;IACrB,SAAS,EAAE,MAAM,EAAE,CAAC;IACpB,KAAK,CAAC,EAAE,GAAG,CAAC;CACb,CAAC;AAEF,MAAM,MAAM,OAAO,GAAG;IACpB,SAAS,EAAE,KAAK,CAAC;QAAE,OAAO,EAAE,MAAM,CAAC;QAAC,OAAO,EAAE,MAAM,CAAA;KAAE,CAAC,CAAC;IACvD,IAAI,EAAE,SAAS,CAAC;CACjB,CAAC;AAEF,MAAM,MAAM,MAAM,GAAG;IACnB,MAA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O,EAAE,MAAM,CAAA;KAAE,CAAC;IAC1C,KAAK,EAAE,SAAS,GAAG;QAAE,SAAS,EAAE,MAAM,CAAA;KAAE,CAAC;IACzC,SAAS,EAAE,SAAS,CAAC;IACrB,KAAK,EAAE,SAAS,CAAC;IACjB,OAAO,EAAE,SAAS,CAAC;IACnB,MAAM,EAAE,SAAS,GAAG;QAAE,OAAO,EAAE,MAAM,CAAA;KAAE,CAAC;IACxC,MAAM,EAAE,SAAS,GAAG;QAAE,MAAM,EAAE,MAAM,CAAC;QAAC,MAAM,EAAE,MAAM,CAAA;KAAE,CAAC;IACvD,KAAK,EAAE,SAAS,GAAG;QAAE,YAAY,EAAE,MAAM,CAAA;KAAE,CAAC;IAC5C,UAAU,EAAE,SAAS,CAAC;IACtB,QAAQ,EAAE,SAAS,GAAG;QAAE,OAAO,EAAE,MAAM,CAAA;KAAE,CAAC;CAC3C;AAED,MAAM,MAAM,WAAW,GAAG;IACxB,IAAI,CAAC,EAAE;QAAE,gBAAgB,EAAE;YAAE,KAAK,EAAE,MAAM,EAAE,CAAA;SAAE,CAAA;KAAE,CAAC;IACjD,WAAW,CAAC,EAAE;QAAE,SAAS,EAAE,MAAM,CAAA;KAAE,CAAC;CACrC,CAAC;AAEF,MAAM,MAAM,YAAY,GAAG,WAAW,GAAG,UAAU,CAAC;AAEpD,eAAO,MAAM,gBAAgB,GAAI,IAAI,YAAY,KAAG,EAAE,IAAI,WAC/B,CAAC;AAE5B;;;;GAIG;AACH,eAAO,MAAM,iBAAiB,GAAI,KAAK,aAAa,YAMnD,CAAC;AAEF,MAAM,MAAM,aAAa,GAAG;IAC1B,EAAE,EAAE,YAAY,CAAC;IACjB,OAAO,CAAC,EAAE,yBAAyB,CAAC;CACrC,CAAC"}
|
|
@@ -1,13 +1,12 @@
|
|
|
1
1
|
import { Transaction, TransactionObjectArgument } from "@mysten/sui/transactions";
|
|
2
2
|
import { Commission, QuoteResponse } from "./aggregator";
|
|
3
|
-
import BigNumber from "bignumber.js";
|
|
4
3
|
export interface CommonParams {
|
|
5
4
|
/** Quote response from 7k api */
|
|
6
5
|
quoteResponse: QuoteResponse;
|
|
7
6
|
/** User address */
|
|
8
7
|
accountAddress: string;
|
|
9
8
|
/** Slippage tolerance, ex: 0.01 (1%) */
|
|
10
|
-
slippage:
|
|
9
|
+
slippage: number | string;
|
|
11
10
|
/** Commission for partner */
|
|
12
11
|
commission: Commission;
|
|
13
12
|
/**
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"tx.d.ts","sourceRoot":"","sources":["../../../../src/types/tx.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,WAAW,EACX,yBAAyB,EAC1B,MAAM,0BAA0B,CAAC;AAClC,OAAO,EAAE,UAAU,EAAE,aAAa,EAAE,MAAM,cAAc,CAAC;
|
|
1
|
+
{"version":3,"file":"tx.d.ts","sourceRoot":"","sources":["../../../../src/types/tx.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,WAAW,EACX,yBAAyB,EAC1B,MAAM,0BAA0B,CAAC;AAClC,OAAO,EAAE,UAAU,EAAE,aAAa,EAAE,MAAM,cAAc,CAAC;AAEzD,MAAM,WAAW,YAAY;IAC3B,iCAAiC;IACjC,aAAa,EAAE,aAAa,CAAC;IAC7B,mBAAmB;IACnB,cAAc,EAAE,MAAM,CAAC;IACvB,wCAAwC;IACxC,QAAQ,EAAE,MAAM,GAAG,MAAM,CAAC;IAC1B,6BAA6B;IAC7B,UAAU,EAAE,UAAU,CAAC;IACvB;;;;;;;;;;;;;;;;;;;;;;;OAuBG;IACH,QAAQ,CAAC,EAAE;QACT,EAAE,EAAE,WAAW,CAAC;QAChB,MAAM,CAAC,EAAE,yBAAyB,CAAC;KACpC,CAAC;IACF;;;OAGG;IACH,WAAW,CAAC,EAAE,OAAO,CAAC;CACvB;AAED,MAAM,WAAW,aAAc,SAAQ,YAAY;IACjD,gCAAgC;IAChC,UAAU,CAAC,EAAE,OAAO,CAAC;CACtB;AAED,MAAM,WAAW,oBAAqB,SAAQ,YAAY;IACxD,0CAA0C;IAC1C,QAAQ,CAAC,EAAE,MAAM,CAAC;CACnB"}
|
|
@@ -1,4 +1,2 @@
|
|
|
1
|
-
|
|
2
|
-
export declare function formatBalance(balance: BigNumber.Value, decimals: number): BigNumber;
|
|
3
|
-
export declare function formatRawBalance(balance: BigNumber.Value, decimals: number): BigNumber;
|
|
1
|
+
export declare function formatBalance(balance: bigint, decimals: number): number;
|
|
4
2
|
//# sourceMappingURL=number.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"number.d.ts","sourceRoot":"","sources":["../../../../src/utils/number.ts"],"names":[],"mappings":"AAAA,
|
|
1
|
+
{"version":3,"file":"number.d.ts","sourceRoot":"","sources":["../../../../src/utils/number.ts"],"names":[],"mappings":"AAAA,wBAAgB,aAAa,CAAC,OAAO,EAAE,MAAM,EAAE,QAAQ,EAAE,MAAM,UAK9D"}
|
|
@@ -49,7 +49,7 @@ export declare const SuiUtils: {
|
|
|
49
49
|
$kind: "NestedResult";
|
|
50
50
|
NestedResult: [number, number];
|
|
51
51
|
};
|
|
52
|
-
|
|
52
|
+
collectDust(tx: Transaction, coinType: string, coin: TransactionArgument): void;
|
|
53
53
|
};
|
|
54
54
|
export {};
|
|
55
55
|
//# sourceMappingURL=sui.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"sui.d.ts","sourceRoot":"","sources":["../../../../src/utils/sui.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,mBAAmB,EAAE,WAAW,EAAE,MAAM,0BAA0B,CAAC;AAC5E,OAAO,EACL,UAAU,EAEV,sBAAsB,EACvB,MAAM,oBAAoB,CAAC;
|
|
1
|
+
{"version":3,"file":"sui.d.ts","sourceRoot":"","sources":["../../../../src/utils/sui.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,mBAAmB,EAAE,WAAW,EAAE,MAAM,0BAA0B,CAAC;AAC5E,OAAO,EACL,UAAU,EAEV,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CAOzE,CAAC"}
|
package/lib/esm/utils/number.js
CHANGED
|
@@ -1,8 +1,6 @@
|
|
|
1
|
-
import BigNumber from "bignumber.js";
|
|
2
1
|
export function formatBalance(balance, decimals) {
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
return new BigNumber(rawBalance.toFixed(0));
|
|
2
|
+
const exp = BigInt(Math.pow(10, decimals));
|
|
3
|
+
const whole = balance / exp;
|
|
4
|
+
const remain = balance % exp;
|
|
5
|
+
return Number(whole) + Number(remain) / Number(exp);
|
|
8
6
|
}
|
package/lib/esm/utils/sui.js
CHANGED
|
@@ -2,6 +2,7 @@ import { Transaction } from "@mysten/sui/transactions";
|
|
|
2
2
|
import { parseStructTag } from "@mysten/sui/utils";
|
|
3
3
|
import { checkIsSui } from "./token";
|
|
4
4
|
import { Config } from "../config";
|
|
5
|
+
import { _7K_CONFIG, _7K_PACKAGE_ID, _7K_VAULT } from "../constants/_7k";
|
|
5
6
|
export const SuiUtils = {
|
|
6
7
|
getSuiCoin(amount, txb) {
|
|
7
8
|
const [coin] = txb.splitCoins(txb.gas, [amount]);
|
|
@@ -191,11 +192,11 @@ export const SuiUtils = {
|
|
|
191
192
|
arguments: [balance],
|
|
192
193
|
})[0];
|
|
193
194
|
},
|
|
194
|
-
|
|
195
|
+
collectDust(tx, coinType, coin) {
|
|
195
196
|
tx.moveCall({
|
|
196
|
-
target:
|
|
197
|
+
target: `${_7K_PACKAGE_ID}::vault::collect_dust`,
|
|
197
198
|
typeArguments: [coinType],
|
|
198
|
-
arguments: [
|
|
199
|
+
arguments: [tx.object(_7K_VAULT), tx.object(_7K_CONFIG), coin],
|
|
199
200
|
});
|
|
200
201
|
},
|
|
201
202
|
};
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@7kprotocol/sdk-ts",
|
|
3
|
-
"version": "2.4.1",
|
|
3
|
+
"version": "2.4.2-beta.1",
|
|
4
4
|
"description": "",
|
|
5
5
|
"exports": {
|
|
6
6
|
".": {
|
|
@@ -43,7 +43,8 @@
|
|
|
43
43
|
"test": "mocha --timeout 5000",
|
|
44
44
|
"publish:patch": "npm version patch --no-git-tag-version && npm publish --access public",
|
|
45
45
|
"publish:minor": "npm version minor --no-git-tag-version && npm publish --access public",
|
|
46
|
-
"publish:major": "npm version major --no-git-tag-version && npm publish --access public"
|
|
46
|
+
"publish:major": "npm version major --no-git-tag-version && npm publish --access public",
|
|
47
|
+
"publish:beta": "npm version prerelease --preid=beta --no-git-tag-version && npm publish --tag beta --access public"
|
|
47
48
|
},
|
|
48
49
|
"keywords": [
|
|
49
50
|
"7k Protocol",
|
|
@@ -57,22 +58,20 @@
|
|
|
57
58
|
"author": "7k Protocol",
|
|
58
59
|
"license": "MIT",
|
|
59
60
|
"devDependencies": {
|
|
60
|
-
"@eslint/js": "^9.
|
|
61
|
-
"@types/
|
|
62
|
-
"@types/chai": "^4.3.3",
|
|
61
|
+
"@eslint/js": "^9.26.0",
|
|
62
|
+
"@types/chai": "^5.2.2",
|
|
63
63
|
"@types/eslint__js": "^8.42.3",
|
|
64
|
-
"@types/mocha": "^
|
|
65
|
-
"chai": "^
|
|
66
|
-
"eslint": "^
|
|
67
|
-
"husky": "^9.
|
|
68
|
-
"mocha": "^
|
|
64
|
+
"@types/mocha": "^10.0.10",
|
|
65
|
+
"chai": "^5.2.0",
|
|
66
|
+
"eslint": "^9.26.0",
|
|
67
|
+
"husky": "^9.1.7",
|
|
68
|
+
"mocha": "^11.2.2",
|
|
69
69
|
"ts-node": "^10.9.2",
|
|
70
|
-
"typescript": "^5.
|
|
71
|
-
"typescript-eslint": "^
|
|
70
|
+
"typescript": "^5.8.3",
|
|
71
|
+
"typescript-eslint": "^8.32.0"
|
|
72
72
|
},
|
|
73
73
|
"peerDependencies": {
|
|
74
|
-
"@mysten/sui": "^1.
|
|
75
|
-
"
|
|
76
|
-
"bn.js": "^5.2.1"
|
|
74
|
+
"@mysten/sui": "^1.29.1",
|
|
75
|
+
"@pythnetwork/pyth-sui-js": "^2.1.0"
|
|
77
76
|
}
|
|
78
77
|
}
|
|
@@ -1,96 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
3
|
-
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
4
|
-
return new (P || (P = Promise))(function (resolve, reject) {
|
|
5
|
-
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
|
6
|
-
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
|
7
|
-
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
|
8
|
-
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
9
|
-
});
|
|
10
|
-
};
|
|
11
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
|
-
exports.DeepBookContract = void 0;
|
|
13
|
-
const utils_1 = require("@mysten/sui/utils");
|
|
14
|
-
const base_1 = require("../base");
|
|
15
|
-
const _7k_1 = require("../../../constants/_7k");
|
|
16
|
-
const sui_1 = require("../../../utils/sui");
|
|
17
|
-
const MODULE_NAME = "clob_v2";
|
|
18
|
-
class DeepBookContract extends base_1.BaseContract {
|
|
19
|
-
swap(tx) {
|
|
20
|
-
return __awaiter(this, void 0, void 0, function* () {
|
|
21
|
-
var _a;
|
|
22
|
-
const swapXtoY = this.swapInfo.swapXtoY;
|
|
23
|
-
const poolId = this.swapInfo.poolId;
|
|
24
|
-
const clientOrderId = Date.now();
|
|
25
|
-
const typeArgs = this.getTypeParams();
|
|
26
|
-
const lotSize = (_a = this.swapInfo.extra) === null || _a === void 0 ? void 0 : _a.lotSize;
|
|
27
|
-
const [baseAsset, quoteAsset] = typeArgs;
|
|
28
|
-
const accountCap = this.createAccountCap(tx);
|
|
29
|
-
const amountIn = this.getInputCoinValue(tx);
|
|
30
|
-
const config = this.config.deepbook;
|
|
31
|
-
let result;
|
|
32
|
-
if (swapXtoY) {
|
|
33
|
-
const amountInRound = tx.moveCall({
|
|
34
|
-
target: `${_7k_1._7K_PACKAGE_ID}::math::m_round_down`,
|
|
35
|
-
arguments: [
|
|
36
|
-
amountIn, // input coin value
|
|
37
|
-
tx.pure.u64(lotSize), // lot size
|
|
38
|
-
],
|
|
39
|
-
});
|
|
40
|
-
const [base_coin_ret, quote_coin_ret] = tx.moveCall({
|
|
41
|
-
target: `${config.package}::${MODULE_NAME}::swap_exact_base_for_quote`,
|
|
42
|
-
typeArguments: [baseAsset, quoteAsset],
|
|
43
|
-
arguments: [
|
|
44
|
-
tx.object(poolId),
|
|
45
|
-
tx.pure.u64(clientOrderId),
|
|
46
|
-
accountCap,
|
|
47
|
-
amountInRound,
|
|
48
|
-
this.inputCoinObject, // coin 0 ~ base
|
|
49
|
-
tx.moveCall({
|
|
50
|
-
typeArguments: [quoteAsset],
|
|
51
|
-
target: `0x2::coin::zero`,
|
|
52
|
-
arguments: [],
|
|
53
|
-
}), // coin 1 ~ quote
|
|
54
|
-
tx.object(utils_1.SUI_CLOCK_OBJECT_ID),
|
|
55
|
-
],
|
|
56
|
-
});
|
|
57
|
-
this.deleteAccountCap(tx, accountCap);
|
|
58
|
-
sui_1.SuiUtils.transferOrDestroyZeroCoin(tx, this.swapInfo.assetIn, base_coin_ret, this.currentAccount);
|
|
59
|
-
result = quote_coin_ret;
|
|
60
|
-
}
|
|
61
|
-
else {
|
|
62
|
-
const [base_coin_ret, quote_coin_ret] = tx.moveCall({
|
|
63
|
-
target: `${config.package}::${MODULE_NAME}::swap_exact_quote_for_base`,
|
|
64
|
-
typeArguments: [baseAsset, quoteAsset],
|
|
65
|
-
arguments: [
|
|
66
|
-
tx.object(poolId),
|
|
67
|
-
tx.pure.u64(clientOrderId),
|
|
68
|
-
accountCap,
|
|
69
|
-
amountIn,
|
|
70
|
-
tx.object(utils_1.SUI_CLOCK_OBJECT_ID),
|
|
71
|
-
this.inputCoinObject, // coin 1 ~ quote
|
|
72
|
-
],
|
|
73
|
-
});
|
|
74
|
-
this.deleteAccountCap(tx, accountCap);
|
|
75
|
-
sui_1.SuiUtils.transferOrDestroyZeroCoin(tx, this.swapInfo.assetIn, quote_coin_ret, this.currentAccount);
|
|
76
|
-
result = base_coin_ret;
|
|
77
|
-
}
|
|
78
|
-
return result;
|
|
79
|
-
});
|
|
80
|
-
}
|
|
81
|
-
createAccountCap(tx) {
|
|
82
|
-
const [cap] = tx.moveCall({
|
|
83
|
-
typeArguments: [],
|
|
84
|
-
target: `${this.config.deepbook.package}::${MODULE_NAME}::create_account`,
|
|
85
|
-
arguments: [],
|
|
86
|
-
});
|
|
87
|
-
return cap;
|
|
88
|
-
}
|
|
89
|
-
deleteAccountCap(tx, accountCap) {
|
|
90
|
-
tx.moveCall({
|
|
91
|
-
target: `${this.config.deepbook.package}::custodian_v2::delete_account_cap`,
|
|
92
|
-
arguments: [accountCap],
|
|
93
|
-
});
|
|
94
|
-
}
|
|
95
|
-
}
|
|
96
|
-
exports.DeepBookContract = DeepBookContract;
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../../src/libs/protocols/deepbook/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAE,MAAM,0BAA0B,CAAC;AAGvD,OAAO,EAAE,YAAY,EAAE,MAAM,SAAS,CAAC;AAMvC,qBAAa,gBAAiB,SAAQ,YAAY;IAC1C,IAAI,CAAC,EAAE,EAAE,WAAW;;;;IAyE1B,OAAO,CAAC,gBAAgB;IASxB,OAAO,CAAC,gBAAgB;CAMzB"}
|
|
@@ -1,80 +0,0 @@
|
|
|
1
|
-
import { SUI_CLOCK_OBJECT_ID } from "@mysten/sui/utils";
|
|
2
|
-
import { BaseContract } from "../base";
|
|
3
|
-
import { _7K_PACKAGE_ID } from "../../../constants/_7k";
|
|
4
|
-
import { SuiUtils } from "../../../utils/sui";
|
|
5
|
-
const MODULE_NAME = "clob_v2";
|
|
6
|
-
export class DeepBookContract extends BaseContract {
|
|
7
|
-
async swap(tx) {
|
|
8
|
-
const swapXtoY = this.swapInfo.swapXtoY;
|
|
9
|
-
const poolId = this.swapInfo.poolId;
|
|
10
|
-
const clientOrderId = Date.now();
|
|
11
|
-
const typeArgs = this.getTypeParams();
|
|
12
|
-
const lotSize = this.swapInfo.extra?.lotSize;
|
|
13
|
-
const [baseAsset, quoteAsset] = typeArgs;
|
|
14
|
-
const accountCap = this.createAccountCap(tx);
|
|
15
|
-
const amountIn = this.getInputCoinValue(tx);
|
|
16
|
-
const config = this.config.deepbook;
|
|
17
|
-
let result;
|
|
18
|
-
if (swapXtoY) {
|
|
19
|
-
const amountInRound = tx.moveCall({
|
|
20
|
-
target: `${_7K_PACKAGE_ID}::math::m_round_down`,
|
|
21
|
-
arguments: [
|
|
22
|
-
amountIn, // input coin value
|
|
23
|
-
tx.pure.u64(lotSize), // lot size
|
|
24
|
-
],
|
|
25
|
-
});
|
|
26
|
-
const [base_coin_ret, quote_coin_ret] = tx.moveCall({
|
|
27
|
-
target: `${config.package}::${MODULE_NAME}::swap_exact_base_for_quote`,
|
|
28
|
-
typeArguments: [baseAsset, quoteAsset],
|
|
29
|
-
arguments: [
|
|
30
|
-
tx.object(poolId),
|
|
31
|
-
tx.pure.u64(clientOrderId),
|
|
32
|
-
accountCap,
|
|
33
|
-
amountInRound,
|
|
34
|
-
this.inputCoinObject, // coin 0 ~ base
|
|
35
|
-
tx.moveCall({
|
|
36
|
-
typeArguments: [quoteAsset],
|
|
37
|
-
target: `0x2::coin::zero`,
|
|
38
|
-
arguments: [],
|
|
39
|
-
}), // coin 1 ~ quote
|
|
40
|
-
tx.object(SUI_CLOCK_OBJECT_ID),
|
|
41
|
-
],
|
|
42
|
-
});
|
|
43
|
-
this.deleteAccountCap(tx, accountCap);
|
|
44
|
-
SuiUtils.transferOrDestroyZeroCoin(tx, this.swapInfo.assetIn, base_coin_ret, this.currentAccount);
|
|
45
|
-
result = quote_coin_ret;
|
|
46
|
-
}
|
|
47
|
-
else {
|
|
48
|
-
const [base_coin_ret, quote_coin_ret] = tx.moveCall({
|
|
49
|
-
target: `${config.package}::${MODULE_NAME}::swap_exact_quote_for_base`,
|
|
50
|
-
typeArguments: [baseAsset, quoteAsset],
|
|
51
|
-
arguments: [
|
|
52
|
-
tx.object(poolId),
|
|
53
|
-
tx.pure.u64(clientOrderId),
|
|
54
|
-
accountCap,
|
|
55
|
-
amountIn,
|
|
56
|
-
tx.object(SUI_CLOCK_OBJECT_ID),
|
|
57
|
-
this.inputCoinObject, // coin 1 ~ quote
|
|
58
|
-
],
|
|
59
|
-
});
|
|
60
|
-
this.deleteAccountCap(tx, accountCap);
|
|
61
|
-
SuiUtils.transferOrDestroyZeroCoin(tx, this.swapInfo.assetIn, quote_coin_ret, this.currentAccount);
|
|
62
|
-
result = base_coin_ret;
|
|
63
|
-
}
|
|
64
|
-
return result;
|
|
65
|
-
}
|
|
66
|
-
createAccountCap(tx) {
|
|
67
|
-
const [cap] = tx.moveCall({
|
|
68
|
-
typeArguments: [],
|
|
69
|
-
target: `${this.config.deepbook.package}::${MODULE_NAME}::create_account`,
|
|
70
|
-
arguments: [],
|
|
71
|
-
});
|
|
72
|
-
return cap;
|
|
73
|
-
}
|
|
74
|
-
deleteAccountCap(tx, accountCap) {
|
|
75
|
-
tx.moveCall({
|
|
76
|
-
target: `${this.config.deepbook.package}::custodian_v2::delete_account_cap`,
|
|
77
|
-
arguments: [accountCap],
|
|
78
|
-
});
|
|
79
|
-
}
|
|
80
|
-
}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../../src/libs/protocols/deepbook/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAE,MAAM,0BAA0B,CAAC;AAGvD,OAAO,EAAE,YAAY,EAAE,MAAM,SAAS,CAAC;AAMvC,qBAAa,gBAAiB,SAAQ,YAAY;IAC1C,IAAI,CAAC,EAAE,EAAE,WAAW;;;;IAyE1B,OAAO,CAAC,gBAAgB;IASxB,OAAO,CAAC,gBAAgB;CAMzB"}
|