@7kprotocol/sdk-ts 3.5.1 → 3.5.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/lib/cjs/config/index.js +9 -0
- package/lib/cjs/features/metaAg/common.js +117 -0
- package/lib/cjs/features/metaAg/index.js +98 -108
- package/lib/cjs/features/metaAg/providers/astro.js +43 -0
- package/lib/cjs/features/metaAg/providers/bluefin.js +6 -6
- package/lib/cjs/features/metaAg/providers/bluefinx.js +87 -0
- package/lib/cjs/features/metaAg/providers/cetus.js +4 -4
- package/lib/cjs/features/metaAg/providers/flowx.js +4 -4
- package/lib/cjs/features/metaAg/providers/okx.js +181 -0
- package/lib/cjs/features/swap/buildTx.js +3 -0
- package/lib/cjs/features/swap/buildTxV2.js +10 -6
- package/lib/cjs/features/swap/config.js +2 -1
- package/lib/cjs/features/swap/getQuote.js +3 -2
- package/lib/cjs/libs/protocols/bluefinx/client.js +1 -1
- package/lib/cjs/types/config/index.d.ts +4 -0
- package/lib/cjs/types/config/index.d.ts.map +1 -1
- package/lib/cjs/types/features/metaAg/common.d.ts +33 -0
- package/lib/cjs/types/features/metaAg/common.d.ts.map +1 -0
- package/lib/cjs/types/features/metaAg/index.d.ts +11 -2
- package/lib/cjs/types/features/metaAg/index.d.ts.map +1 -1
- package/lib/cjs/types/features/metaAg/providers/astro.d.ts +9 -0
- package/lib/cjs/types/features/metaAg/providers/astro.d.ts.map +1 -0
- package/lib/cjs/types/features/metaAg/providers/bluefin.d.ts +3 -3
- package/lib/cjs/types/features/metaAg/providers/bluefin.d.ts.map +1 -1
- package/lib/cjs/types/features/metaAg/providers/bluefinx.d.ts +10 -0
- package/lib/cjs/types/features/metaAg/providers/bluefinx.d.ts.map +1 -0
- package/lib/cjs/types/features/metaAg/providers/cetus.d.ts +4 -5
- package/lib/cjs/types/features/metaAg/providers/cetus.d.ts.map +1 -1
- package/lib/cjs/types/features/metaAg/providers/flowx.d.ts +3 -3
- package/lib/cjs/types/features/metaAg/providers/flowx.d.ts.map +1 -1
- package/lib/cjs/types/features/metaAg/providers/okx.d.ts +21 -0
- package/lib/cjs/types/features/metaAg/providers/okx.d.ts.map +1 -0
- package/lib/cjs/types/features/swap/buildTx.d.ts.map +1 -1
- package/lib/cjs/types/features/swap/buildTxV2.d.ts +3 -3
- package/lib/cjs/types/features/swap/buildTxV2.d.ts.map +1 -1
- package/lib/cjs/types/features/swap/config.d.ts.map +1 -1
- package/lib/cjs/types/features/swap/getQuote.d.ts +1 -3
- package/lib/cjs/types/features/swap/getQuote.d.ts.map +1 -1
- package/lib/cjs/types/index.d.ts +3 -1
- package/lib/cjs/types/index.d.ts.map +1 -1
- package/lib/cjs/types/metaAg.js +11 -4
- package/lib/cjs/types/okx.js +6 -0
- package/lib/cjs/types/types/metaAg.d.ts +60 -8
- package/lib/cjs/types/types/metaAg.d.ts.map +1 -1
- package/lib/cjs/types/types/okx.d.ts +193 -0
- package/lib/cjs/types/types/okx.d.ts.map +1 -0
- package/lib/cjs/types/utils/condition.d.ts +1 -1
- package/lib/cjs/types/utils/condition.d.ts.map +1 -1
- package/lib/esm/config/index.js +9 -0
- package/lib/esm/features/metaAg/common.js +109 -0
- package/lib/esm/features/metaAg/index.js +99 -109
- package/lib/esm/features/metaAg/providers/astro.js +40 -0
- package/lib/esm/features/metaAg/providers/bluefin.js +6 -6
- package/lib/esm/features/metaAg/providers/bluefinx.js +84 -0
- package/lib/esm/features/metaAg/providers/cetus.js +4 -4
- package/lib/esm/features/metaAg/providers/flowx.js +4 -4
- package/lib/esm/features/metaAg/providers/okx.js +146 -0
- package/lib/esm/features/swap/buildTx.js +3 -0
- package/lib/esm/features/swap/buildTxV2.js +6 -2
- package/lib/esm/features/swap/config.js +2 -1
- package/lib/esm/features/swap/getQuote.js +3 -2
- package/lib/esm/libs/protocols/bluefinx/client.js +1 -1
- package/lib/esm/types/config/index.d.ts +4 -0
- package/lib/esm/types/config/index.d.ts.map +1 -1
- package/lib/esm/types/features/metaAg/common.d.ts +33 -0
- package/lib/esm/types/features/metaAg/common.d.ts.map +1 -0
- package/lib/esm/types/features/metaAg/index.d.ts +11 -2
- package/lib/esm/types/features/metaAg/index.d.ts.map +1 -1
- package/lib/esm/types/features/metaAg/providers/astro.d.ts +9 -0
- package/lib/esm/types/features/metaAg/providers/astro.d.ts.map +1 -0
- package/lib/esm/types/features/metaAg/providers/bluefin.d.ts +3 -3
- package/lib/esm/types/features/metaAg/providers/bluefin.d.ts.map +1 -1
- package/lib/esm/types/features/metaAg/providers/bluefinx.d.ts +10 -0
- package/lib/esm/types/features/metaAg/providers/bluefinx.d.ts.map +1 -0
- package/lib/esm/types/features/metaAg/providers/cetus.d.ts +4 -5
- package/lib/esm/types/features/metaAg/providers/cetus.d.ts.map +1 -1
- package/lib/esm/types/features/metaAg/providers/flowx.d.ts +3 -3
- package/lib/esm/types/features/metaAg/providers/flowx.d.ts.map +1 -1
- package/lib/esm/types/features/metaAg/providers/okx.d.ts +21 -0
- package/lib/esm/types/features/metaAg/providers/okx.d.ts.map +1 -0
- package/lib/esm/types/features/swap/buildTx.d.ts.map +1 -1
- package/lib/esm/types/features/swap/buildTxV2.d.ts +3 -3
- package/lib/esm/types/features/swap/buildTxV2.d.ts.map +1 -1
- package/lib/esm/types/features/swap/config.d.ts.map +1 -1
- package/lib/esm/types/features/swap/getQuote.d.ts +1 -3
- package/lib/esm/types/features/swap/getQuote.d.ts.map +1 -1
- package/lib/esm/types/index.d.ts +3 -1
- package/lib/esm/types/index.d.ts.map +1 -1
- package/lib/esm/types/metaAg.js +8 -2
- package/lib/esm/types/okx.js +5 -0
- package/lib/esm/types/types/metaAg.d.ts +60 -8
- package/lib/esm/types/types/metaAg.d.ts.map +1 -1
- package/lib/esm/types/types/okx.d.ts +193 -0
- package/lib/esm/types/types/okx.d.ts.map +1 -0
- package/lib/esm/types/utils/condition.d.ts +1 -1
- package/lib/esm/types/utils/condition.d.ts.map +1 -1
- package/package.json +3 -2
|
@@ -12,7 +12,10 @@ import { getConfig } from "./config";
|
|
|
12
12
|
* 2. Merging redundant swaps to the same pool within each wave
|
|
13
13
|
* 3. Processing waves sequentially, passing intermediate tokens between waves
|
|
14
14
|
*/
|
|
15
|
-
export const buildTxV2 = async (
|
|
15
|
+
export const buildTxV2 = async (params) => {
|
|
16
|
+
return buildTxV2Int(params);
|
|
17
|
+
};
|
|
18
|
+
export const buildTxV2Int = async ({ quoteResponse, accountAddress, slippage, commission: __commission, devInspect, extendTx, isSponsored, }, beforeBuildBluefinXTx) => {
|
|
16
19
|
const isBluefinX = isBluefinXRouting(quoteResponse);
|
|
17
20
|
const _commission = {
|
|
18
21
|
...__commission,
|
|
@@ -58,6 +61,7 @@ export const buildTxV2 = async ({ quoteResponse, accountAddress, slippage, commi
|
|
|
58
61
|
}
|
|
59
62
|
}
|
|
60
63
|
if (isBluefinX) {
|
|
64
|
+
beforeBuildBluefinXTx?.(tx, coinOut);
|
|
61
65
|
return {
|
|
62
66
|
tx: await buildBluefinXTx(tx, accountAddress, quoteResponse),
|
|
63
67
|
coinOut,
|
|
@@ -66,7 +70,7 @@ export const buildTxV2 = async ({ quoteResponse, accountAddress, slippage, commi
|
|
|
66
70
|
tx.setSenderIfNotSet(accountAddress);
|
|
67
71
|
return { tx, coinOut };
|
|
68
72
|
};
|
|
69
|
-
|
|
73
|
+
const optimize = async (pythMap, config, routes, coinData, tx, accountAddress) => {
|
|
70
74
|
// Initialize route states with split coins
|
|
71
75
|
const routeStates = routes.map((route, index) => ({
|
|
72
76
|
routeIndex: index,
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { Config as _Config } from "../../config";
|
|
1
2
|
import { fetchClient } from "../../config/fetchClient";
|
|
2
3
|
import { API_ENDPOINTS } from "../../constants/apiEndpoints";
|
|
3
4
|
export const DEFAULT_CONFIG = {
|
|
@@ -137,7 +138,7 @@ export async function getConfig() {
|
|
|
137
138
|
return config;
|
|
138
139
|
}
|
|
139
140
|
try {
|
|
140
|
-
const response = await fetchClient(`${API_ENDPOINTS.MAIN}/config`);
|
|
141
|
+
const response = await fetchClient(`${_Config.getApi() || API_ENDPOINTS.MAIN}/config`);
|
|
141
142
|
const quoteResponse = (await response.json());
|
|
142
143
|
config = { ...config, ...quoteResponse };
|
|
143
144
|
configTs = Date.now();
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { normalizeStructTag, normalizeSuiObjectId } from "@mysten/sui/utils";
|
|
2
|
+
import { Config } from "../../config";
|
|
2
3
|
import { fetchClient } from "../../config/fetchClient";
|
|
3
4
|
import { API_ENDPOINTS } from "../../constants/apiEndpoints";
|
|
4
5
|
import { isBluefinXRouting, } from "../../types/aggregator";
|
|
@@ -36,7 +37,7 @@ export const ORACLE_BASED_SOURCES = new Set([
|
|
|
36
37
|
"steamm_oracle_quoter",
|
|
37
38
|
"steamm_oracle_quoter_v2",
|
|
38
39
|
]);
|
|
39
|
-
export async function getQuote({ tokenIn, tokenOut, amountIn, sources: _sources = DEFAULT_SOURCES, commissionBps, targetPools, excludedPools, taker, isSponsored,
|
|
40
|
+
export async function getQuote({ tokenIn, tokenOut, amountIn, sources: _sources = DEFAULT_SOURCES, commissionBps, targetPools, excludedPools, taker, isSponsored, maxPaths, }) {
|
|
40
41
|
let sources = _sources;
|
|
41
42
|
if (isSponsored) {
|
|
42
43
|
sources = _sources.filter((s) => !ORACLE_BASED_SOURCES.has(s));
|
|
@@ -59,7 +60,7 @@ export async function getQuote({ tokenIn, tokenOut, amountIn, sources: _sources
|
|
|
59
60
|
if (maxPaths) {
|
|
60
61
|
params.append("max_paths", maxPaths.toString());
|
|
61
62
|
}
|
|
62
|
-
const response = await fetchClient(`${
|
|
63
|
+
const response = await fetchClient(`${Config.getApi() || API_ENDPOINTS.MAIN}/quote?${params}`);
|
|
63
64
|
if (!response.ok) {
|
|
64
65
|
let responseText;
|
|
65
66
|
try {
|
|
@@ -8,7 +8,7 @@ const request = async (path, body) => {
|
|
|
8
8
|
if (bluefinXApiKey) {
|
|
9
9
|
headers.set("Bluefin-X-API-Key", bluefinXApiKey);
|
|
10
10
|
}
|
|
11
|
-
const res = await fetch(`${API_ENDPOINTS.MAIN}/${path}`, {
|
|
11
|
+
const res = await fetch(`${Config.getApi() || API_ENDPOINTS.MAIN}/${path}`, {
|
|
12
12
|
method: "POST",
|
|
13
13
|
body: JSON.stringify(body),
|
|
14
14
|
headers,
|
|
@@ -1,5 +1,7 @@
|
|
|
1
1
|
import { SuiClient } from "@mysten/sui/client";
|
|
2
2
|
import { SuiPriceServiceConnection, SuiPythClient } from "@pythnetwork/pyth-sui-js";
|
|
3
|
+
declare function setApi(url: string): void;
|
|
4
|
+
declare function getApi(): string;
|
|
3
5
|
declare function setApiKey(key: string): void;
|
|
4
6
|
declare function getApiKey(): string;
|
|
5
7
|
declare function setBluefinXApiKey(key: string): void;
|
|
@@ -11,6 +13,8 @@ declare function getPythClient(): SuiPythClient;
|
|
|
11
13
|
declare function setPythConnection(connection: SuiPriceServiceConnection): void;
|
|
12
14
|
declare function getPythConnection(): SuiPriceServiceConnection;
|
|
13
15
|
declare const Config: {
|
|
16
|
+
setApi: typeof setApi;
|
|
17
|
+
getApi: typeof getApi;
|
|
14
18
|
setApiKey: typeof setApiKey;
|
|
15
19
|
getApiKey: typeof getApiKey;
|
|
16
20
|
setBluefinXApiKey: typeof setBluefinXApiKey;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/config/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAkB,MAAM,oBAAoB,CAAC;AAC/D,OAAO,EACL,yBAAyB,EACzB,aAAa,EACd,MAAM,0BAA0B,CAAC;
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/config/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAkB,MAAM,oBAAoB,CAAC;AAC/D,OAAO,EACL,yBAAyB,EACzB,aAAa,EACd,MAAM,0BAA0B,CAAC;AAuBlC,iBAAS,MAAM,CAAC,GAAG,EAAE,MAAM,GAAG,IAAI,CAEjC;AAED,iBAAS,MAAM,IAAI,MAAM,CAExB;AAED,iBAAS,SAAS,CAAC,GAAG,EAAE,MAAM,GAAG,IAAI,CAEpC;AAED,iBAAS,SAAS,IAAI,MAAM,CAE3B;AAED,iBAAS,iBAAiB,CAAC,GAAG,EAAE,MAAM,GAAG,IAAI,CAE5C;AAED,iBAAS,iBAAiB,IAAI,MAAM,CAEnC;AAED,iBAAS,YAAY,IAAI,SAAS,CAEjC;AAED,iBAAS,YAAY,CAAC,MAAM,EAAE,SAAS,GAAG,IAAI,CAE7C;AAED,iBAAS,aAAa,CAAC,MAAM,EAAE,aAAa,GAAG,IAAI,CAElD;AAED,iBAAS,aAAa,IAAI,aAAa,CAEtC;AAED,iBAAS,iBAAiB,CAAC,UAAU,EAAE,yBAAyB,GAAG,IAAI,CAEtE;AAED,iBAAS,iBAAiB,IAAI,yBAAyB,CAEtD;AAED,QAAA,MAAM,MAAM;;;;;;;;;;;;;CAaX,CAAC;AAEF,OAAO,EAAE,MAAM,EAAE,CAAC"}
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
import { GasCostSummary } from "@mysten/sui/client";
|
|
2
|
+
import { Transaction, TransactionObjectArgument } from "@mysten/sui/transactions";
|
|
3
|
+
import { AggregatorProvider, EProvider, MetaAgOptions, MetaQuote, MetaSimulationOptions } from "../../types/metaAg";
|
|
4
|
+
import { SuiClientUtils } from "../../utils/SuiClientUtils";
|
|
5
|
+
export declare const simulateBluefinX: <T extends MetaQuote & {
|
|
6
|
+
provider: EProvider.BLUEFINX;
|
|
7
|
+
}>(quote: T) => {
|
|
8
|
+
id: string;
|
|
9
|
+
simulatedAmountOut: string;
|
|
10
|
+
gasUsed: GasCostSummary;
|
|
11
|
+
provider: EProvider.BLUEFINX;
|
|
12
|
+
};
|
|
13
|
+
export declare const simulateSwapTx: (tx: Transaction, inspector: SuiClientUtils, simulation: MetaSimulationOptions) => Promise<{
|
|
14
|
+
simulatedAmountOut: string;
|
|
15
|
+
gasUsed: GasCostSummary;
|
|
16
|
+
}>;
|
|
17
|
+
export declare const simulateAggregator: (provider: AggregatorProvider, quote: MetaQuote, simulation: MetaSimulationOptions, inspector: SuiClientUtils, options: Required<MetaAgOptions>) => Promise<{
|
|
18
|
+
simulatedAmountOut: string;
|
|
19
|
+
gasUsed: GasCostSummary;
|
|
20
|
+
id: string;
|
|
21
|
+
provider: EProvider.BLUEFIN7K | EProvider.CETUS | EProvider.FLOWX | EProvider.ASTRO;
|
|
22
|
+
}>;
|
|
23
|
+
/**
|
|
24
|
+
* this settlement does not charge commission fee for partner, since all integrated aggregators already charge commission fee for partner
|
|
25
|
+
* @param quote Meta Aggregator Quote
|
|
26
|
+
* @param coinOut Coin Out Object
|
|
27
|
+
* @param slippageBps Slippage Bps
|
|
28
|
+
* @param tipBps Tip Bps default = 0
|
|
29
|
+
* @param partner address of partner for analytic default is zero address
|
|
30
|
+
*/
|
|
31
|
+
export declare const metaSettle: (quote: MetaQuote, coinOut: TransactionObjectArgument, slippageBps?: number, tipBps?: number, partner?: string, commissionBps?: number) => (tx: Transaction) => void;
|
|
32
|
+
export declare const timeout: <T = any>(fn: () => Promise<T>, timeout: number, msg?: string) => Promise<T>;
|
|
33
|
+
//# sourceMappingURL=common.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"common.d.ts","sourceRoot":"","sources":["../../../../../src/features/metaAg/common.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,cAAc,EAAY,MAAM,oBAAoB,CAAC;AAC9D,OAAO,EAEL,WAAW,EACX,yBAAyB,EAC1B,MAAM,0BAA0B,CAAC;AAOlC,OAAO,EACL,kBAAkB,EAClB,SAAS,EACT,aAAa,EACb,SAAS,EACT,qBAAqB,EACtB,MAAM,oBAAoB,CAAC;AAC5B,OAAO,EAAE,cAAc,EAAE,MAAM,4BAA4B,CAAC;AAS5D,eAAO,MAAM,gBAAgB,GAC3B,CAAC,SAAS,SAAS,GAAG;IAAE,QAAQ,EAAE,SAAS,CAAC,QAAQ,CAAA;CAAE,EAEtD,OAAO,CAAC;;;;;CAQT,CAAC;AACF,eAAO,MAAM,cAAc,GACzB,IAAI,WAAW,EACf,WAAW,cAAc,EACzB,YAAY,qBAAqB;wBAeE,MAAM;;EAG1C,CAAC;AACF,eAAO,MAAM,kBAAkB,GAC7B,UAAU,kBAAkB,EAC5B,OAAO,SAAS,EAChB,YAAY,qBAAqB,EACjC,WAAW,cAAc,EACzB,SAAS,QAAQ,CAAC,aAAa,CAAC;wBATG,MAAM;;;;EAuC1C,CAAC;AAEF;;;;;;;GAOG;AACH,eAAO,MAAM,UAAU,GACrB,OAAO,SAAS,EAChB,SAAS,yBAAyB,EAClC,oBAAiB,EACjB,eAAU,EACV,UAAU,MAAM,EAChB,sBAAiB,MAET,IAAI,WAAW,SAqCxB,CAAC;AASF,eAAO,MAAM,OAAO,GAAU,CAAC,GAAG,GAAG,EACnC,IAAI,MAAM,OAAO,CAAC,CAAC,CAAC,EACpB,SAAS,MAAM,EACf,MAAM,MAAM,eAab,CAAC"}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { SuiClient } from "@mysten/sui/client";
|
|
1
|
+
import { GetTransactionBlockParams, SuiClient, SuiTransactionBlockResponse } from "@mysten/sui/client";
|
|
2
2
|
import { TransactionObjectArgument } from "@mysten/sui/transactions";
|
|
3
|
-
import { MetaAgOptions, MetaQuote, MetaQuoteOptions, MetaSimulationOptions, MetaSwapOptions } from "../../types/metaAg";
|
|
3
|
+
import { MetaAgOptions, MetaFastSwapOptions, MetaQuote, MetaQuoteOptions, MetaSimulationOptions, MetaSwapOptions } from "../../types/metaAg";
|
|
4
4
|
export declare class MetaAg {
|
|
5
5
|
client: SuiClient;
|
|
6
6
|
private providers;
|
|
@@ -10,6 +10,7 @@ export declare class MetaAg {
|
|
|
10
10
|
private _getProvider;
|
|
11
11
|
private _simulate;
|
|
12
12
|
private _quote;
|
|
13
|
+
private _fastSwap;
|
|
13
14
|
/**
|
|
14
15
|
* Get quotes from all providers
|
|
15
16
|
* @param options - quote options
|
|
@@ -19,11 +20,19 @@ export declare class MetaAg {
|
|
|
19
20
|
quote(options: MetaQuoteOptions, simulation?: MetaSimulationOptions): Promise<MetaQuote[]>;
|
|
20
21
|
/**
|
|
21
22
|
* Build transaction from quote
|
|
23
|
+
* @info Use this function to build composable transaction (ie: add more commands after the swap, consume the coin out object)
|
|
24
|
+
* @warning Providers that build transaction on the fly (typically RFQ, Swap-API providers ie: BluefinX, Okx, ...) are not supported, please use `fastSwap` instead
|
|
22
25
|
* @param options - build tx options
|
|
23
26
|
* @param slippageBps - slippage bps if not specified, fallback to global slippage bps, if none of them specified, default to 100
|
|
24
27
|
* @returns coin out object, you must consume it by transferObjects, or other sub sequence commands
|
|
25
28
|
*/
|
|
26
29
|
swap(options: MetaSwapOptions, slippageBps?: number): Promise<TransactionObjectArgument>;
|
|
30
|
+
/**
|
|
31
|
+
* Build, Sign, and Execute transaction in one step
|
|
32
|
+
* @param options - fast swap options
|
|
33
|
+
* @returns - txDigest of the transaction
|
|
34
|
+
*/
|
|
35
|
+
fastSwap(options: MetaFastSwapOptions, getTransactionBlockParams?: Omit<GetTransactionBlockParams, "digest">): Promise<SuiTransactionBlockResponse>;
|
|
27
36
|
/**
|
|
28
37
|
* Update meta aggregator options
|
|
29
38
|
* @param options - update options payload
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/features/metaAg/index.ts"],"names":[],"mappings":"AAAA,OAAO,
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/features/metaAg/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAEL,yBAAyB,EACzB,SAAS,EACT,2BAA2B,EAC5B,MAAM,oBAAoB,CAAC;AAC5B,OAAO,EAGL,yBAAyB,EAC1B,MAAM,0BAA0B,CAAC;AAGlC,OAAO,EASL,aAAa,EACb,mBAAmB,EACnB,SAAS,EACT,gBAAgB,EAChB,qBAAqB,EACrB,eAAe,EAGhB,MAAM,oBAAoB,CAAC;AAwB5B,qBAAa,MAAM;IACjB,MAAM,EAAE,SAAS,CAAC;IAClB,OAAO,CAAC,SAAS,CAAiD;IAClE,OAAO,CAAC,SAAS,CAAiB;IAClC,OAAO,CAAC,OAAO,CAA0B;gBAC7B,OAAO,CAAC,EAAE,aAAa;YAkBrB,YAAY;YA2DZ,SAAS;YAkCT,MAAM;YAqBN,SAAS;IA2BvB;;;;;OAKG;IACG,KAAK,CACT,OAAO,EAAE,gBAAgB,EACzB,UAAU,CAAC,EAAE,qBAAqB,GACjC,OAAO,CAAC,SAAS,EAAE,CAAC;IAsCvB;;;;;;;OAOG;IACG,IAAI,CACR,OAAO,EAAE,eAAe,EACxB,WAAW,CAAC,EAAE,MAAM,GACnB,OAAO,CAAC,yBAAyB,CAAC;IAsBrC;;;;OAIG;IACG,QAAQ,CACZ,OAAO,EAAE,mBAAmB,EAC5B,yBAAyB,CAAC,EAAE,IAAI,CAAC,yBAAyB,EAAE,QAAQ,CAAC,GACpE,OAAO,CAAC,2BAA2B,CAAC;IAcvC;;;OAGG;IACH,mBAAmB,CAAC,OAAO,EAAE,aAAa;CA4B3C"}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { AggregatorProvider, AstroProviderOptions, EProvider, MetaQuote, MetaQuoteOptions, MetaSwapOptions, QuoteProvider } from "../../../types/metaAg";
|
|
2
|
+
export declare class AstroProvider implements QuoteProvider, AggregatorProvider {
|
|
3
|
+
private readonly options;
|
|
4
|
+
readonly kind = EProvider.ASTRO;
|
|
5
|
+
constructor(options: AstroProviderOptions);
|
|
6
|
+
quote({ amountIn, coinTypeIn, coinTypeOut, }: MetaQuoteOptions): Promise<MetaQuote | null>;
|
|
7
|
+
swap({ signer, quote, coinIn, tx }: MetaSwapOptions): Promise<import("@mysten/sui/dist/cjs/transactions").TransactionResult>;
|
|
8
|
+
}
|
|
9
|
+
//# sourceMappingURL=astro.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"astro.d.ts","sourceRoot":"","sources":["../../../../../../src/features/metaAg/providers/astro.ts"],"names":[],"mappings":"AAMA,OAAO,EACL,kBAAkB,EAClB,oBAAoB,EACpB,SAAS,EACT,SAAS,EACT,gBAAgB,EAChB,eAAe,EACf,aAAa,EACd,MAAM,uBAAuB,CAAC;AAG/B,qBAAa,aAAc,YAAW,aAAa,EAAE,kBAAkB;IAEzD,OAAO,CAAC,QAAQ,CAAC,OAAO;IADpC,QAAQ,CAAC,IAAI,mBAAmB;gBACH,OAAO,EAAE,oBAAoB;IAEpD,KAAK,CAAC,EACV,QAAQ,EACR,UAAU,EACV,WAAW,GACZ,EAAE,gBAAgB,GAAG,OAAO,CAAC,SAAS,GAAG,IAAI,CAAC;IA8BzC,IAAI,CAAC,EAAE,MAAM,EAAE,KAAK,EAAE,MAAM,EAAE,EAAE,EAAE,EAAE,eAAe;CAW1D"}
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import { SuiClient } from "@mysten/sui/client";
|
|
2
|
-
import {
|
|
3
|
-
export declare class BluefinProvider implements
|
|
2
|
+
import { AggregatorProvider, BluefinProviderOptions, EProvider, MetaAgOptions, MetaQuote, MetaQuoteOptions, MetaSwapOptions, QuoteProvider } from "../../../types/metaAg";
|
|
3
|
+
export declare class BluefinProvider implements QuoteProvider, AggregatorProvider {
|
|
4
4
|
private readonly options;
|
|
5
5
|
private readonly metaOptions;
|
|
6
|
-
kind
|
|
6
|
+
readonly kind = EProvider.BLUEFIN7K;
|
|
7
7
|
constructor(options: BluefinProviderOptions, metaOptions: Required<MetaAgOptions>, client: SuiClient);
|
|
8
8
|
quote(options: MetaQuoteOptions): Promise<MetaQuote>;
|
|
9
9
|
swap({ quote, signer, tx, coinIn }: MetaSwapOptions): Promise<import("@mysten/sui/dist/cjs/transactions").TransactionObjectArgument>;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"bluefin.d.ts","sourceRoot":"","sources":["../../../../../../src/features/metaAg/providers/bluefin.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,MAAM,oBAAoB,CAAC;
|
|
1
|
+
{"version":3,"file":"bluefin.d.ts","sourceRoot":"","sources":["../../../../../../src/features/metaAg/providers/bluefin.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,MAAM,oBAAoB,CAAC;AAS/C,OAAO,EACL,kBAAkB,EAClB,sBAAsB,EACtB,SAAS,EACT,aAAa,EACb,SAAS,EACT,gBAAgB,EAChB,eAAe,EACf,aAAa,EACd,MAAM,uBAAuB,CAAC;AAQ/B,qBAAa,eAAgB,YAAW,aAAa,EAAE,kBAAkB;IAGrE,OAAO,CAAC,QAAQ,CAAC,OAAO;IACxB,OAAO,CAAC,QAAQ,CAAC,WAAW;IAH9B,QAAQ,CAAC,IAAI,uBAAuB;gBAEjB,OAAO,EAAE,sBAAsB,EAC/B,WAAW,EAAE,QAAQ,CAAC,aAAa,CAAC,EACrD,MAAM,EAAE,SAAS;IAgBb,KAAK,CAAC,OAAO,EAAE,gBAAgB,GAAG,OAAO,CAAC,SAAS,CAAC;IAqBpD,IAAI,CAAC,EAAE,KAAK,EAAE,MAAM,EAAE,EAAE,EAAE,MAAM,EAAE,EAAE,eAAe;CAiB1D"}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { BluefinXProviderOptions, EProvider, MetaFastSwapOptions, MetaQuote, MetaQuoteOptions, QuoteProvider, SwapAPIProvider } from "../../../types/metaAg";
|
|
2
|
+
export declare class BluefinXProvider implements QuoteProvider, SwapAPIProvider {
|
|
3
|
+
private readonly options;
|
|
4
|
+
readonly kind = EProvider.BLUEFINX;
|
|
5
|
+
constructor(options: BluefinXProviderOptions);
|
|
6
|
+
quote(options: MetaQuoteOptions): Promise<MetaQuote | null>;
|
|
7
|
+
canQuote(options: MetaQuoteOptions): boolean;
|
|
8
|
+
fastSwap(options: MetaFastSwapOptions): Promise<string>;
|
|
9
|
+
}
|
|
10
|
+
//# sourceMappingURL=bluefinx.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"bluefinx.d.ts","sourceRoot":"","sources":["../../../../../../src/features/metaAg/providers/bluefinx.ts"],"names":[],"mappings":"AAOA,OAAO,EACL,uBAAuB,EACvB,SAAS,EACT,mBAAmB,EACnB,SAAS,EACT,gBAAgB,EAChB,aAAa,EACb,eAAe,EAChB,MAAM,uBAAuB,CAAC;AAU/B,qBAAa,gBAAiB,YAAW,aAAa,EAAE,eAAe;IAEzD,OAAO,CAAC,QAAQ,CAAC,OAAO;IADpC,QAAQ,CAAC,IAAI,sBAAsB;gBACN,OAAO,EAAE,uBAAuB;IAKvD,KAAK,CAAC,OAAO,EAAE,gBAAgB,GAAG,OAAO,CAAC,SAAS,GAAG,IAAI,CAAC;IAqBjE,QAAQ,CAAC,OAAO,EAAE,gBAAgB,GAAG,OAAO;IAStC,QAAQ,CAAC,OAAO,EAAE,mBAAmB,GAAG,OAAO,CAAC,MAAM,CAAC;CAiC9D"}
|
|
@@ -1,12 +1,11 @@
|
|
|
1
1
|
import { SuiClient } from "@mysten/sui/client";
|
|
2
|
-
import {
|
|
3
|
-
|
|
4
|
-
export declare class CetusProvider implements AgProvider {
|
|
2
|
+
import { AggregatorProvider, CetusProviderOptions, EProvider, MetaAgOptions, MetaQuote, MetaQuoteOptions, MetaSwapOptions, QuoteProvider } from "../../../types/metaAg";
|
|
3
|
+
export declare class CetusProvider implements QuoteProvider, AggregatorProvider {
|
|
5
4
|
private readonly options;
|
|
6
|
-
kind
|
|
5
|
+
readonly kind = EProvider.CETUS;
|
|
7
6
|
private readonly cetusClient;
|
|
8
7
|
constructor(options: CetusProviderOptions, metaOptions: MetaAgOptions, client: SuiClient);
|
|
9
8
|
quote(quoteOptions: MetaQuoteOptions): Promise<MetaQuote>;
|
|
10
|
-
swap(options: MetaSwapOptions): Promise<TransactionObjectArgument>;
|
|
9
|
+
swap(options: MetaSwapOptions): Promise<import("@mysten/sui/dist/cjs/transactions").TransactionObjectArgument>;
|
|
11
10
|
}
|
|
12
11
|
//# sourceMappingURL=cetus.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"cetus.d.ts","sourceRoot":"","sources":["../../../../../../src/features/metaAg/providers/cetus.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,SAAS,EAAE,MAAM,oBAAoB,CAAC;
|
|
1
|
+
{"version":3,"file":"cetus.d.ts","sourceRoot":"","sources":["../../../../../../src/features/metaAg/providers/cetus.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,SAAS,EAAE,MAAM,oBAAoB,CAAC;AAG/C,OAAO,EACL,kBAAkB,EAClB,oBAAoB,EACpB,SAAS,EACT,aAAa,EACb,SAAS,EACT,gBAAgB,EAChB,eAAe,EACf,aAAa,EACd,MAAM,uBAAuB,CAAC;AAG/B,qBAAa,aAAc,YAAW,aAAa,EAAE,kBAAkB;IAInE,OAAO,CAAC,QAAQ,CAAC,OAAO;IAH1B,QAAQ,CAAC,IAAI,mBAAmB;IAChC,OAAO,CAAC,QAAQ,CAAC,WAAW,CAAmB;gBAE5B,OAAO,EAAE,oBAAoB,EAC9C,WAAW,EAAE,aAAa,EAC1B,MAAM,EAAE,SAAS;IAab,KAAK,CAAC,YAAY,EAAE,gBAAgB,GAAG,OAAO,CAAC,SAAS,CAAC;IA0BzD,IAAI,CAAC,OAAO,EAAE,eAAe;CAUpC"}
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import { SuiClient } from "@mysten/sui/client";
|
|
2
2
|
import { TransactionObjectArgument } from "@mysten/sui/transactions";
|
|
3
|
-
import {
|
|
4
|
-
export declare class FlowxProvider implements
|
|
3
|
+
import { AggregatorProvider, EProvider, FlowxProviderOptions, MetaQuote, MetaQuoteOptions, MetaSwapOptions, QuoteProvider } from "../../../types/metaAg";
|
|
4
|
+
export declare class FlowxProvider implements QuoteProvider, AggregatorProvider {
|
|
5
5
|
private readonly options;
|
|
6
6
|
private readonly client;
|
|
7
|
-
kind
|
|
7
|
+
readonly kind = EProvider.FLOWX;
|
|
8
8
|
private quoter;
|
|
9
9
|
constructor(options: FlowxProviderOptions, client: SuiClient);
|
|
10
10
|
quote(quoteOptions: MetaQuoteOptions): Promise<MetaQuote>;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"flowx.d.ts","sourceRoot":"","sources":["../../../../../../src/features/metaAg/providers/flowx.ts"],"names":[],"mappings":"AAMA,OAAO,EAAE,SAAS,EAAE,MAAM,oBAAoB,CAAC;AAC/C,OAAO,EAAE,yBAAyB,EAAE,MAAM,0BAA0B,CAAC;AAGrE,OAAO,EACL,
|
|
1
|
+
{"version":3,"file":"flowx.d.ts","sourceRoot":"","sources":["../../../../../../src/features/metaAg/providers/flowx.ts"],"names":[],"mappings":"AAMA,OAAO,EAAE,SAAS,EAAE,MAAM,oBAAoB,CAAC;AAC/C,OAAO,EAAE,yBAAyB,EAAE,MAAM,0BAA0B,CAAC;AAGrE,OAAO,EACL,kBAAkB,EAClB,SAAS,EACT,oBAAoB,EACpB,SAAS,EACT,gBAAgB,EAChB,eAAe,EACf,aAAa,EACd,MAAM,uBAAuB,CAAC;AAG/B,qBAAa,aAAc,YAAW,aAAa,EAAE,kBAAkB;IAInE,OAAO,CAAC,QAAQ,CAAC,OAAO;IACxB,OAAO,CAAC,QAAQ,CAAC,MAAM;IAJzB,QAAQ,CAAC,IAAI,mBAAmB;IAChC,OAAO,CAAC,MAAM,CAAmB;gBAEd,OAAO,EAAE,oBAAoB,EAC7B,MAAM,EAAE,SAAS;IAK9B,KAAK,CAAC,YAAY,EAAE,gBAAgB,GAAG,OAAO,CAAC,SAAS,CAAC;IAuBzD,IAAI,CAAC,OAAO,EAAE,eAAe,GAAG,OAAO,CAAC,yBAAyB,CAAC;CAqBzE"}
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import { SuiClient } from "@mysten/sui/client";
|
|
2
|
+
import { EProvider, MetaAgOptions, MetaFastSwapOptions, MetaQuote, MetaQuoteOptions, MetaSimulationOptions, OkxProviderOptions, QuoteProvider, SwapAPIProvider } from "../../../types/metaAg";
|
|
3
|
+
import { SuiClientUtils } from "../../../utils/SuiClientUtils";
|
|
4
|
+
export declare class OkxProvider implements QuoteProvider, SwapAPIProvider {
|
|
5
|
+
private readonly options;
|
|
6
|
+
private readonly metaOptions;
|
|
7
|
+
private readonly client;
|
|
8
|
+
readonly kind = EProvider.OKX;
|
|
9
|
+
constructor(options: OkxProviderOptions, metaOptions: Required<MetaAgOptions>, client: SuiClient);
|
|
10
|
+
quote({ amountIn, coinTypeIn, coinTypeOut, signer, }: MetaQuoteOptions): Promise<MetaQuote | null>;
|
|
11
|
+
fastSwap(options: MetaFastSwapOptions): Promise<string>;
|
|
12
|
+
}
|
|
13
|
+
export declare const simulateOKXSwap: <T extends MetaQuote & {
|
|
14
|
+
provider: EProvider.OKX;
|
|
15
|
+
}>(quote: T, inspector: SuiClientUtils, simulation: MetaSimulationOptions, metaOptions: Required<MetaAgOptions>) => Promise<{
|
|
16
|
+
simulatedAmountOut: string;
|
|
17
|
+
gasUsed: import("@mysten/sui/client").GasCostSummary;
|
|
18
|
+
id: string;
|
|
19
|
+
provider: EProvider.OKX;
|
|
20
|
+
}>;
|
|
21
|
+
//# sourceMappingURL=okx.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"okx.d.ts","sourceRoot":"","sources":["../../../../../../src/features/metaAg/providers/okx.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,MAAM,oBAAoB,CAAC;AAc/C,OAAO,EACL,SAAS,EACT,aAAa,EACb,mBAAmB,EACnB,SAAS,EACT,gBAAgB,EAChB,qBAAqB,EAErB,kBAAkB,EAClB,aAAa,EACb,eAAe,EAChB,MAAM,uBAAuB,CAAC;A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,iBAAiB,GAAI,WAAW,aAAa,EAAE,aAa3D,CAAC;AAEF,eAAO,MAAM,yBAAyB,GACpC,IAAI,WAAW,EACf,eAAe,aAAa,EAAE,
|
|
1
|
+
{"version":3,"file":"buildTx.d.ts","sourceRoot":"","sources":["../../../../../src/features/swap/buildTx.ts"],"names":[],"mappings":"AAAA,OAAO,EAEL,WAAW,EACX,yBAAyB,EAC1B,MAAM,0BAA0B,CAAC;AAOlC,OAAO,EAAE,UAAU,EAAE,MAAM,qCAAqC,CAAC;AAEjE,OAAO,EACL,aAAa,EACb,UAAU,EAEV,aAAa,EACb,SAAS,EACV,MAAM,wBAAwB,CAAC;AAChC,OAAO,EAAE,aAAa,EAAE,MAAM,gBAAgB,CAAC;AAK/C,eAAO,MAAM,OAAO,GAAU,2GAQ3B,aAAa,KAAG,OAAO,CAAC,aAAa,CA+FvC,CAAC;AAEF,eAAO,MAAM,iBAAiB,GAAI,WAAW,aAAa,EAAE,aAa3D,CAAC;AAEF,eAAO,MAAM,yBAAyB,GACpC,IAAI,WAAW,EACf,eAAe,aAAa,EAAE,oCAmB/B,CAAC;AAEF,eAAO,MAAM,cAAc,GACzB,QAAQ,SAAS,EAAE,EAAE,EACrB,cAAc,OAAO,SAWtB,CAAC;AAEF,eAAO,MAAM,iBAAiB,GAC5B,cAAc,MAAM,EACpB,aAAa,MAAM,EACnB,eAAe,MAAM,EACrB,SAAQ,MAAU;;;;;CA8BnB,CAAC;AAEF,eAAO,MAAM,MAAM,GACjB,aAAa,yBAAyB,EAAE,EACxC,eAAe,aAAa,EAC5B,aAAa,MAAM,EACnB,aAAa,UAAU,MAEf,IAAI,WAAW,8BAiCxB,CAAC;AAEF,eAAO,MAAM,eAAe,GAC1B,IAAI,WAAW,EACf,gBAAgB,MAAM,EACtB,eAAe,aAAa,wBAyB7B,CAAC"}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { Transaction, TransactionObjectArgument } from "@mysten/sui/transactions";
|
|
2
|
-
import { BuildTxResult
|
|
2
|
+
import { BuildTxResult } from "../../types/aggregator";
|
|
3
3
|
import { BuildTxParams, MultiSwapParams } from "../../types/tx";
|
|
4
4
|
/**
|
|
5
5
|
* Wave-based transaction builder that optimizes swap execution by:
|
|
@@ -7,8 +7,8 @@ import { BuildTxParams, MultiSwapParams } from "../../types/tx";
|
|
|
7
7
|
* 2. Merging redundant swaps to the same pool within each wave
|
|
8
8
|
* 3. Processing waves sequentially, passing intermediate tokens between waves
|
|
9
9
|
*/
|
|
10
|
-
export declare const buildTxV2: (
|
|
11
|
-
export declare const
|
|
10
|
+
export declare const buildTxV2: (params: BuildTxParams) => Promise<BuildTxResult>;
|
|
11
|
+
export declare const buildTxV2Int: ({ quoteResponse, accountAddress, slippage, commission: __commission, devInspect, extendTx, isSponsored, }: BuildTxParams, beforeBuildBluefinXTx?: (tx: Transaction, coinOut: TransactionObjectArgument | undefined) => void) => Promise<BuildTxResult>;
|
|
12
12
|
/**
|
|
13
13
|
* execute multiple swap in single transaction
|
|
14
14
|
*
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"buildTxV2.d.ts","sourceRoot":"","sources":["../../../../../src/features/swap/buildTxV2.ts"],"names":[],"mappings":"AAAA,OAAO,EAEL,WAAW,EACX,yBAAyB,EAC1B,MAAM,0BAA0B,CAAC;AAIlC,OAAO,EACL,aAAa,
|
|
1
|
+
{"version":3,"file":"buildTxV2.d.ts","sourceRoot":"","sources":["../../../../../src/features/swap/buildTxV2.ts"],"names":[],"mappings":"AAAA,OAAO,EAEL,WAAW,EACX,yBAAyB,EAC1B,MAAM,0BAA0B,CAAC;AAIlC,OAAO,EACL,aAAa,EAId,MAAM,wBAAwB,CAAC;AAChC,OAAO,EAAE,aAAa,EAAE,eAAe,EAAE,MAAM,gBAAgB,CAAC;AAUhE;;;;;GAKG;AACH,eAAO,MAAM,SAAS,GACpB,QAAQ,aAAa,KACpB,OAAO,CAAC,aAAa,CAEvB,CAAC;AAEF,eAAO,MAAM,YAAY,GACvB,2GAQG,aAAa,EAChB,wBAAwB,CACtB,EAAE,EAAE,WAAW,EACf,OAAO,EAAE,yBAAyB,GAAG,SAAS,KAC3C,IAAI,KACR,OAAO,CAAC,aAAa,CAwFvB,CAAC;AAiKF;;;;;;GAMG;AACH,eAAO,MAAM,SAAS,GAAU,iDAM7B,eAAe,uDAiDjB,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"config.d.ts","sourceRoot":"","sources":["../../../../../src/features/swap/config.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"config.d.ts","sourceRoot":"","sources":["../../../../../src/features/swap/config.ts"],"names":[],"mappings":"AAGA,OAAO,EAAE,MAAM,EAAE,MAAM,wBAAwB,CAAC;AAEhD,eAAO,MAAM,cAAc,EAAE,MAqL5B,CAAC;AAIF,wBAAsB,SAAS,oBAiB9B"}
|
|
@@ -17,13 +17,11 @@ interface Params {
|
|
|
17
17
|
taker?: string;
|
|
18
18
|
/** If true, excludes all liquidity sources that depend on pyth price feeds - pyth client use tx.gas to pay the fee*/
|
|
19
19
|
isSponsored?: boolean;
|
|
20
|
-
/** Custom API endpoint */
|
|
21
|
-
api?: string;
|
|
22
20
|
/** Maximum number of paths to consider for the quote */
|
|
23
21
|
maxPaths?: number;
|
|
24
22
|
}
|
|
25
23
|
export declare const DEFAULT_SOURCES: SourceDex[];
|
|
26
24
|
export declare const ORACLE_BASED_SOURCES: Set<SourceDex>;
|
|
27
|
-
export declare function getQuote({ tokenIn, tokenOut, amountIn, sources: _sources, commissionBps, targetPools, excludedPools, taker, isSponsored,
|
|
25
|
+
export declare function getQuote({ tokenIn, tokenOut, amountIn, sources: _sources, commissionBps, targetPools, excludedPools, taker, isSponsored, maxPaths, }: Params): Promise<QuoteResponse>;
|
|
28
26
|
export {};
|
|
29
27
|
//# sourceMappingURL=getQuote.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"getQuote.d.ts","sourceRoot":"","sources":["../../../../../src/features/swap/getQuote.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"getQuote.d.ts","sourceRoot":"","sources":["../../../../../src/features/swap/getQuote.ts"],"names":[],"mappings":"AAIA,OAAO,EAEL,aAAa,EACb,SAAS,EACV,MAAM,wBAAwB,CAAC;AAEhC,UAAU,MAAM;IACd,OAAO,EAAE,MAAM,CAAC;IAChB,QAAQ,EAAE,MAAM,CAAC;IACjB,QAAQ,EAAE,MAAM,CAAC;IACjB;;;kEAG8D;IAC9D,OAAO,CAAC,EAAE,SAAS,EAAE,CAAC;IACtB,aAAa,CAAC,EAAE,MAAM,CAAC;IACvB,iDAAiD;IACjD,WAAW,CAAC,EAAE,MAAM,EAAE,CAAC;IACvB,qDAAqD;IACrD,aAAa,CAAC,EAAE,MAAM,EAAE,CAAC;IACzB,+CAA+C;IAC/C,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,qHAAqH;IACrH,WAAW,CAAC,EAAE,OAAO,CAAC;IACtB,wDAAwD;IACxD,QAAQ,CAAC,EAAE,MAAM,CAAC;CACnB;AAED,eAAO,MAAM,eAAe,EAAE,SAAS,EA0BtC,CAAC;AAEF,eAAO,MAAM,oBAAoB,gBAM/B,CAAC;AAEH,wBAAsB,QAAQ,CAAC,EAC7B,OAAO,EACP,QAAQ,EACR,QAAQ,EACR,OAAO,EAAE,QAA0B,EACnC,aAAa,EACb,WAAW,EACX,aAAa,EACb,KAAK,EACL,WAAW,EACX,QAAQ,GACT,EAAE,MAAM,0BA8CR"}
|
package/lib/esm/types/index.d.ts
CHANGED
|
@@ -11,6 +11,8 @@ declare const setSuiClient: (client: import("@mysten/sui/dist/cjs/client").SuiCl
|
|
|
11
11
|
export { buildTx, buildTxV2, cancelDcaOrder, cancelLimitOrder, claimExpiredLimitOrder, Config, DEFAULT_SOURCES, estimateGasFee, executeBluefinTx, executeTx, getClosedDcaOrders, getClosedLimitOrders, getDcaOrderExecutions, getOpenDcaOrders, getOpenLimitOrders, getQuote, getSuiClient, getSuiPrice, getSwapHistory, getTokenPrice, getTokenPrices, MetaAg, multiSwap, placeDcaOrder, placeLimitOrder, setSuiClient, };
|
|
12
12
|
declare const _default: {
|
|
13
13
|
Config: {
|
|
14
|
+
setApi: (url: string) => void;
|
|
15
|
+
getApi: () => string;
|
|
14
16
|
setApiKey: (key: string) => void;
|
|
15
17
|
getApiKey: () => string;
|
|
16
18
|
setBluefinXApiKey: (key: string) => void;
|
|
@@ -30,7 +32,7 @@ declare const _default: {
|
|
|
30
32
|
getQuote: typeof getQuote;
|
|
31
33
|
estimateGasFee: typeof estimateGasFee;
|
|
32
34
|
buildTx: ({ quoteResponse, accountAddress, slippage, commission: __commission, devInspect, extendTx, isSponsored, }: import("./types/tx").BuildTxParams) => Promise<import("./types/aggregator").BuildTxResult>;
|
|
33
|
-
buildTxV2: (
|
|
35
|
+
buildTxV2: (params: import("./types/tx").BuildTxParams) => Promise<import("./types/aggregator").BuildTxResult>;
|
|
34
36
|
multiSwap: ({ sender, slippageBps, swaps, tx, commission, }: import("./types/tx").MultiSwapParams) => Promise<Record<string, import("@mysten/sui/dist/cjs/transactions").TransactionObjectArgument>>;
|
|
35
37
|
getSwapHistory: typeof getSwapHistory;
|
|
36
38
|
executeTx: (tx: import("./types/aggregator").AggregatorTx, signature: string, signedTxBytes: string, options?: import("@mysten/sui/dist/cjs/client").SuiTransactionBlockResponseOptions) => Promise<import("@mysten/sui/dist/cjs/client").SuiTransactionBlockResponse>;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/index.ts"],"names":[],"mappings":"AAAA,cAAc,oBAAoB,CAAC;AACnC,cAAc,gBAAgB,CAAC;AAE/B,OAAO,EAAE,MAAM,EAAE,MAAM,UAAU,CAAC;AAElC,OAAO,EAAE,MAAM,EAAE,MAAM,mBAAmB,CAAC;AAC3C,OAAO,EAAE,WAAW,EAAE,aAAa,EAAE,cAAc,EAAE,MAAM,mBAAmB,CAAC;AAC/E,OAAO,EAAE,gBAAgB,EAAE,MAAM,kCAAkC,CAAC;AAEpE,OAAO,EACL,OAAO,EACP,SAAS,EACT,eAAe,EACf,cAAc,EACd,SAAS,EACT,QAAQ,EACR,cAAc,EACd,SAAS,EACV,MAAM,iBAAiB,CAAC;AAEzB,OAAO,EACL,cAAc,EACd,gBAAgB,EAChB,sBAAsB,EACtB,kBAAkB,EAClB,oBAAoB,EACpB,qBAAqB,EACrB,gBAAgB,EAChB,kBAAkB,EAClB,aAAa,EACb,eAAe,EAChB,MAAM,qBAAqB,CAAC;AAG7B,QAAA,MAAM,YAAY,uDAAsB,CAAC;AACzC,QAAA,MAAM,YAAY,mEAAsB,CAAC;AAEzC,OAAO,EACL,OAAO,EACP,SAAS,EACT,cAAc,EACd,gBAAgB,EAChB,sBAAsB,EAEtB,MAAM,EACN,eAAe,EACf,cAAc,EACd,gBAAgB,EAChB,SAAS,EACT,kBAAkB,EAClB,oBAAoB,EACpB,qBAAqB,EACrB,gBAAgB,EAChB,kBAAkB,EAElB,QAAQ,EAER,YAAY,EACZ,WAAW,EACX,cAAc,EAEd,aAAa,EACb,cAAc,EACd,MAAM,EACN,SAAS,EAET,aAAa,EAEb,eAAe,EACf,YAAY,GACb,CAAC
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/index.ts"],"names":[],"mappings":"AAAA,cAAc,oBAAoB,CAAC;AACnC,cAAc,gBAAgB,CAAC;AAE/B,OAAO,EAAE,MAAM,EAAE,MAAM,UAAU,CAAC;AAElC,OAAO,EAAE,MAAM,EAAE,MAAM,mBAAmB,CAAC;AAC3C,OAAO,EAAE,WAAW,EAAE,aAAa,EAAE,cAAc,EAAE,MAAM,mBAAmB,CAAC;AAC/E,OAAO,EAAE,gBAAgB,EAAE,MAAM,kCAAkC,CAAC;AAEpE,OAAO,EACL,OAAO,EACP,SAAS,EACT,eAAe,EACf,cAAc,EACd,SAAS,EACT,QAAQ,EACR,cAAc,EACd,SAAS,EACV,MAAM,iBAAiB,CAAC;AAEzB,OAAO,EACL,cAAc,EACd,gBAAgB,EAChB,sBAAsB,EACtB,kBAAkB,EAClB,oBAAoB,EACpB,qBAAqB,EACrB,gBAAgB,EAChB,kBAAkB,EAClB,aAAa,EACb,eAAe,EAChB,MAAM,qBAAqB,CAAC;AAG7B,QAAA,MAAM,YAAY,uDAAsB,CAAC;AACzC,QAAA,MAAM,YAAY,mEAAsB,CAAC;AAEzC,OAAO,EACL,OAAO,EACP,SAAS,EACT,cAAc,EACd,gBAAgB,EAChB,sBAAsB,EAEtB,MAAM,EACN,eAAe,EACf,cAAc,EACd,gBAAgB,EAChB,SAAS,EACT,kBAAkB,EAClB,oBAAoB,EACpB,qBAAqB,EACrB,gBAAgB,EAChB,kBAAkB,EAElB,QAAQ,EAER,YAAY,EACZ,WAAW,EACX,cAAc,EAEd,aAAa,EACb,cAAc,EACd,MAAM,EACN,SAAS,EAET,aAAa,EAEb,eAAe,EACf,YAAY,GACb,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAEF,wBAwCE"}
|
package/lib/esm/types/metaAg.js
CHANGED
|
@@ -3,6 +3,12 @@ export var EProvider;
|
|
|
3
3
|
EProvider["BLUEFIN7K"] = "bluefin7k";
|
|
4
4
|
EProvider["CETUS"] = "cetus";
|
|
5
5
|
EProvider["FLOWX"] = "flowx";
|
|
6
|
+
EProvider["OKX"] = "okx";
|
|
7
|
+
EProvider["BLUEFINX"] = "bluefinx";
|
|
8
|
+
EProvider["ASTRO"] = "astro";
|
|
6
9
|
})(EProvider || (EProvider = {}));
|
|
7
|
-
export
|
|
8
|
-
|
|
10
|
+
export const isAggregatorProvider = (provider) => provider.kind === EProvider.BLUEFIN7K ||
|
|
11
|
+
provider.kind === EProvider.CETUS ||
|
|
12
|
+
provider.kind === EProvider.FLOWX ||
|
|
13
|
+
provider.kind === EProvider.ASTRO;
|
|
14
|
+
export const isSwapAPIProvider = (provider) => provider.kind === EProvider.OKX || provider.kind === EProvider.BLUEFINX;
|
|
@@ -1,12 +1,18 @@
|
|
|
1
1
|
import type { PreSwapLpChangeParams, RouterDataV3 } from "@cetusprotocol/aggregator-sdk";
|
|
2
2
|
import type { AggregatorQuoter, Protocol } from "@flowx-finance/sdk";
|
|
3
3
|
import type { GasCostSummary } from "@mysten/sui/client";
|
|
4
|
+
import { SignatureWithBytes } from "@mysten/sui/cryptography";
|
|
4
5
|
import type { Transaction, TransactionObjectArgument } from "@mysten/sui/transactions";
|
|
6
|
+
import type { Quote, SwapOptions } from "@naviprotocol/astros-aggregator-sdk";
|
|
5
7
|
import { QuoteResponse, SourceDex } from "./aggregator";
|
|
8
|
+
import { OkxSwapResponseData } from "./okx";
|
|
6
9
|
export declare enum EProvider {
|
|
7
10
|
BLUEFIN7K = "bluefin7k",
|
|
8
11
|
CETUS = "cetus",
|
|
9
|
-
FLOWX = "flowx"
|
|
12
|
+
FLOWX = "flowx",
|
|
13
|
+
OKX = "okx",
|
|
14
|
+
BLUEFINX = "bluefinx",
|
|
15
|
+
ASTRO = "astro"
|
|
10
16
|
}
|
|
11
17
|
type ProviderBaseOptions = {
|
|
12
18
|
api?: string;
|
|
@@ -34,12 +40,23 @@ export type CetusProviderOptions = ProviderBaseOptions & {
|
|
|
34
40
|
depth?: number;
|
|
35
41
|
liquidityChanges?: PreSwapLpChangeParams[];
|
|
36
42
|
};
|
|
43
|
+
export type OkxProviderOptions = Required<Omit<ProviderBaseOptions, "api">> & {
|
|
44
|
+
api?: string;
|
|
45
|
+
secretKey: string;
|
|
46
|
+
apiPassphrase: string;
|
|
47
|
+
projectId: string;
|
|
48
|
+
};
|
|
49
|
+
export type BluefinXProviderOptions = ProviderBaseOptions;
|
|
50
|
+
export type AstroProviderOptions = ProviderBaseOptions & Pick<SwapOptions, "dexList" | "depth">;
|
|
37
51
|
export interface MetaAgOptions {
|
|
38
52
|
/**If not specified, all providers will be used */
|
|
39
53
|
providers?: {
|
|
40
54
|
[EProvider.BLUEFIN7K]?: BluefinProviderOptions;
|
|
41
55
|
[EProvider.FLOWX]?: FlowxProviderOptions;
|
|
42
56
|
[EProvider.CETUS]?: CetusProviderOptions;
|
|
57
|
+
[EProvider.OKX]?: OkxProviderOptions;
|
|
58
|
+
[EProvider.BLUEFINX]?: BluefinXProviderOptions;
|
|
59
|
+
[EProvider.ASTRO]?: AstroProviderOptions;
|
|
43
60
|
};
|
|
44
61
|
/**Mainnet Json Rpc url, if not specified, the default mainnet url will be used */
|
|
45
62
|
fullnodeUrl?: string;
|
|
@@ -57,9 +74,11 @@ export interface MetaAgOptions {
|
|
|
57
74
|
tipBps?: number;
|
|
58
75
|
}
|
|
59
76
|
export interface MetaQuoteOptions {
|
|
60
|
-
|
|
61
|
-
|
|
77
|
+
coinTypeIn: string;
|
|
78
|
+
coinTypeOut: string;
|
|
62
79
|
amountIn: string;
|
|
80
|
+
/** Required for RFQ providers (ie: BluefinX) */
|
|
81
|
+
signer?: string;
|
|
63
82
|
/**
|
|
64
83
|
* Timeout for quote operation in milliseconds
|
|
65
84
|
* @default 2000ms
|
|
@@ -76,7 +95,22 @@ export interface MetaSimulationOptions {
|
|
|
76
95
|
/** If specify, defer the simulation that could reduce the time to display quote result, you must update the quote via the id on callback
|
|
77
96
|
* else await all quote and simulation before return
|
|
78
97
|
*/
|
|
79
|
-
onSimulated?: (payload:
|
|
98
|
+
onSimulated?: (payload: MetaQuote) => void;
|
|
99
|
+
}
|
|
100
|
+
export interface MetaFastSwapOptions {
|
|
101
|
+
/** Quote object from the quote operation */
|
|
102
|
+
quote: MetaQuote;
|
|
103
|
+
/** Signer address (owner of `coinIn`) */
|
|
104
|
+
signer: string;
|
|
105
|
+
/** If true, use the gas coin for the swap
|
|
106
|
+
* @default true */
|
|
107
|
+
useGasCoin?: boolean;
|
|
108
|
+
/**
|
|
109
|
+
* Sign the transaction bytes
|
|
110
|
+
* @param txBytes - base64 transaction bytes
|
|
111
|
+
* @returns - signature with bytes
|
|
112
|
+
*/
|
|
113
|
+
signTransaction: (txBytes: string) => Promise<SignatureWithBytes>;
|
|
80
114
|
}
|
|
81
115
|
export interface MetaSwapOptions {
|
|
82
116
|
/** Quote object from the quote operation */
|
|
@@ -100,6 +134,15 @@ export type MetaQuote = ({
|
|
|
100
134
|
} | {
|
|
101
135
|
provider: EProvider.FLOWX;
|
|
102
136
|
quote: FlowxQuoteResponse;
|
|
137
|
+
} | {
|
|
138
|
+
provider: EProvider.OKX;
|
|
139
|
+
quote: OkxSwapResponseData;
|
|
140
|
+
} | {
|
|
141
|
+
provider: EProvider.BLUEFINX;
|
|
142
|
+
quote: QuoteResponse;
|
|
143
|
+
} | {
|
|
144
|
+
provider: EProvider.ASTRO;
|
|
145
|
+
quote: Quote;
|
|
103
146
|
}) & {
|
|
104
147
|
/** uuid to keep track the quote result, used to apply simulation result on quote on callback `onSimulated`*/
|
|
105
148
|
id: string;
|
|
@@ -118,10 +161,19 @@ export type MetaQuote = ({
|
|
|
118
161
|
/** Estimate gas consumption if the transaction is executed */
|
|
119
162
|
gasUsed?: GasCostSummary;
|
|
120
163
|
};
|
|
121
|
-
export
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
164
|
+
export interface QuoteProvider {
|
|
165
|
+
readonly kind: EProvider;
|
|
166
|
+
quote(_quoteOptions: MetaQuoteOptions): Promise<MetaQuote | null>;
|
|
167
|
+
}
|
|
168
|
+
export interface SwapAPIProvider extends QuoteProvider {
|
|
169
|
+
readonly kind: EProvider.OKX | EProvider.BLUEFINX;
|
|
170
|
+
fastSwap(options: MetaFastSwapOptions): Promise<string>;
|
|
171
|
+
}
|
|
172
|
+
export interface AggregatorProvider extends QuoteProvider {
|
|
173
|
+
readonly kind: EProvider.BLUEFIN7K | EProvider.CETUS | EProvider.FLOWX | EProvider.ASTRO;
|
|
174
|
+
swap(options: MetaSwapOptions): Promise<TransactionObjectArgument>;
|
|
125
175
|
}
|
|
176
|
+
export declare const isAggregatorProvider: (provider: QuoteProvider) => provider is AggregatorProvider;
|
|
177
|
+
export declare const isSwapAPIProvider: (provider: QuoteProvider) => provider is SwapAPIProvider;
|
|
126
178
|
export {};
|
|
127
179
|
//# sourceMappingURL=metaAg.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"metaAg.d.ts","sourceRoot":"","sources":["../../../../src/types/metaAg.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EACV,qBAAqB,EACrB,YAAY,EACb,MAAM,+BAA+B,CAAC;AACvC,OAAO,KAAK,EAAE,gBAAgB,EAAE,QAAQ,EAAE,MAAM,oBAAoB,CAAC;AACrE,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,oBAAoB,CAAC;AACzD,OAAO,KAAK,EACV,WAAW,EACX,yBAAyB,EAC1B,MAAM,0BAA0B,CAAC;AAClC,OAAO,EAAE,aAAa,EAAE,SAAS,EAAE,MAAM,cAAc,CAAC;
|
|
1
|
+
{"version":3,"file":"metaAg.d.ts","sourceRoot":"","sources":["../../../../src/types/metaAg.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EACV,qBAAqB,EACrB,YAAY,EACb,MAAM,+BAA+B,CAAC;AACvC,OAAO,KAAK,EAAE,gBAAgB,EAAE,QAAQ,EAAE,MAAM,oBAAoB,CAAC;AACrE,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,oBAAoB,CAAC;AACzD,OAAO,EAAE,kBAAkB,EAAE,MAAM,0BAA0B,CAAC;AAC9D,OAAO,KAAK,EACV,WAAW,EACX,yBAAyB,EAC1B,MAAM,0BAA0B,CAAC;AAClC,OAAO,KAAK,EAAE,KAAK,EAAE,WAAW,EAAE,MAAM,qCAAqC,CAAC;AAC9E,OAAO,EAAE,aAAa,EAAE,SAAS,EAAE,MAAM,cAAc,CAAC;AACxD,OAAO,EAAE,mBAAmB,EAAE,MAAM,OAAO,CAAC;AAE5C,oBAAY,SAAS;IACnB,SAAS,cAAc;IACvB,KAAK,UAAU;IACf,KAAK,UAAU;IACf,GAAG,QA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