@skate-org/amm-core-v2 2.0.0-beta.2 → 2.0.0-beta.6
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/CHANGELOG.md +21 -0
- package/dist/deployment/aggregated/dev.d.ts.map +1 -1
- package/dist/deployment/aggregated/production.d.ts.map +1 -1
- package/dist/deployment/aggregated/retrieval.d.ts +6 -2
- package/dist/deployment/aggregated/retrieval.d.ts.map +1 -1
- package/dist/deployment/index.d.ts +1 -0
- package/dist/deployment/index.d.ts.map +1 -1
- package/dist/deployment/sui.d.ts +42 -0
- package/dist/deployment/sui.d.ts.map +1 -0
- package/dist/deployment/svm.d.ts +40 -3
- package/dist/deployment/svm.d.ts.map +1 -1
- package/dist/index.cjs +104 -23
- package/dist/index.cjs.map +1 -1
- package/dist/index.js +100 -23
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,26 @@
|
|
|
1
1
|
# @skate-org/amm-core-v2
|
|
2
2
|
|
|
3
|
+
## 2.0.0-beta.3 — 2026-05-18
|
|
4
|
+
|
|
5
|
+
Internal refactor: per-pool SVM addresses consolidated into one file.
|
|
6
|
+
No public type changes, no runtime data changes — `POOL_INFO_Dev` resolves
|
|
7
|
+
to the same object shape it did in beta.2.
|
|
8
|
+
|
|
9
|
+
- **`deployment/svm.ts` — new `SVM_POOLS_DEV` export:** map keyed by
|
|
10
|
+
`[poolKey][SvmChain]` (e.g. `SVM_POOLS_DEV.USDC_USDT[CHAIN.SOLANA]`)
|
|
11
|
+
carrying per-pool PDAs, vaults, mints, and token programs. Validated
|
|
12
|
+
at the declaration site via `satisfies Record<string, Partial<Record<
|
|
13
|
+
SvmChain, SvmPeripheryInfo>>>`. Additive, non-breaking — public surface
|
|
14
|
+
gains the export.
|
|
15
|
+
- **`deployment/aggregated/dev.ts` — thin composition:**
|
|
16
|
+
`POOL_INFO_Dev.USDC_USDT.peripheryInfo` now spreads
|
|
17
|
+
`...SVM_POOLS_DEV.USDC_USDT` instead of inlining the SOLANA literal.
|
|
18
|
+
Adding a new SVM chain entry to an existing pool (e.g. Eclipse once it
|
|
19
|
+
deploys) is a one-file edit in `svm.ts`.
|
|
20
|
+
- **`manager` field on `SvmPeripheryInfo`:** unchanged — duplication
|
|
21
|
+
against `SVM_DEPLOYMENT_DEV[chain].manager` is intentional and deferred
|
|
22
|
+
to a future PR; dedup would be a public-type change.
|
|
23
|
+
|
|
3
24
|
## 2.0.0-beta.2 — 2026-05-17
|
|
4
25
|
|
|
5
26
|
SVM-side periphery wired into the deployment catalog. Solana mainnet
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"dev.d.ts","sourceRoot":"","sources":["../../../src/deployment/aggregated/dev.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"dev.d.ts","sourceRoot":"","sources":["../../../src/deployment/aggregated/dev.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,YAAY,EAAE,MAAM,UAAU,CAAC;AAExC,eAAO,MAAM,aAAa,EAAE,YA6B3B,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"production.d.ts","sourceRoot":"","sources":["../../../src/deployment/aggregated/production.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"production.d.ts","sourceRoot":"","sources":["../../../src/deployment/aggregated/production.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,YAAY,EAAE,MAAM,UAAU,CAAC;AAOxC,eAAO,MAAM,oBAAoB,EAAE,YA6BlC,CAAC"}
|
|
@@ -27,9 +27,13 @@ export declare function getPeripheryDetailsByKernelPoolAndChainId(kernelPool: `0
|
|
|
27
27
|
* `(symbol, chainId)` pair always points at one token, but
|
|
28
28
|
* `(symbol, chainIds[])` may produce many.
|
|
29
29
|
*
|
|
30
|
-
*
|
|
30
|
+
* Omit `chainIds` to search every supported chain.
|
|
31
31
|
*/
|
|
32
|
-
export declare function findTokensBySymbol(
|
|
32
|
+
export declare function findTokensBySymbol(args: {
|
|
33
|
+
symbol: string;
|
|
34
|
+
chainIds?: readonly CHAIN[];
|
|
35
|
+
mode?: EnvMode;
|
|
36
|
+
}): Token[];
|
|
33
37
|
/**
|
|
34
38
|
* Reverse lookup: return the symbol of the token at `address` on
|
|
35
39
|
* `chainId`, or `null` if no supported token matches that pair.
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"retrieval.d.ts","sourceRoot":"","sources":["../../../src/deployment/aggregated/retrieval.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,EAAE,OAAO,EAAE,KAAK,EAAE,SAAS,EAAE,MAAM,aAAa,CAAC;AAC/D,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,UAAU,CAAC;AAIjD,OAAO,EAAE,YAAY,EAAE,OAAO,EAAE,MAAM,UAAU,CAAC;AAEjD,wBAAgB,cAAc,CAAC,IAAI,GAAE,OAAsB,GAAG,YAAY,CAMzE;AAED,wBAAgB,cAAc,CAAC,IAAI,GAAE,OAAsB,GAAG,OAAO,EAAE,CAEtE;AAED,wBAAgB,gBAAgB,CAAC,GAAG,EAAE,OAAO,EAAE,IAAI,GAAE,OAAsB;;;;;iCAkClB,CAAA;SAhCxD;AAED,wBAAgB,kBAAkB,CAAC,IAAI,GAAE,OAAsB,GAAG,KAAK,EAAE,CASxE;AAED,wBAAgB,iBAAiB,CAC/B,OAAO,EAAE,KAAK,EACd,IAAI,GAAE,OAAsB,GAC3B,CAAC,SAAS,GAAG;IAAE,OAAO,EAAE,OAAO,CAAA;CAAE,CAAC,EAAE,CActC;AAED,wBAAgB,kBAAkB,CAAC,OAAO,EAAE,KAAK,EAAE,IAAI,GAAE,OAAsB,GAAG,KAAK,EAAE,CAcxF;AAED,wBAAgB,qBAAqB,CACnC,OAAO,EAAE,KAAK,EACd,YAAY,EAAE,MAAM,EACpB,IAAI,GAAE,OAAsB,GAC3B,KAAK,EAAE,CAeT;AAED,wBAAgB,mBAAm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.d.ts","sourceRoot":"","sources":["../../src/deployment/index.ts"],"names":[],"mappings":"AAAA,cAAc,UAAU,CAAC;AACzB,cAAc,aAAa,CAAC;AAC5B,cAAc,OAAO,CAAC;AACtB,cAAc,OAAO,CAAC;AACtB,cAAc,cAAc,CAAC"}
|
|
@@ -0,0 +1,42 @@
|
|
|
1
|
+
import { CHAIN, EnvMode } from "../types";
|
|
2
|
+
import type { SuiChain } from "../types/chain-vm";
|
|
3
|
+
/** Deploy-wide Sui addresses. Per-pool object ids live in `SUI_POOLS_<mode>`
|
|
4
|
+
* below; this struct holds the deploy-wide pieces shared across pools. */
|
|
5
|
+
export interface SuiDeployment {
|
|
6
|
+
/** Sui package id that owns the periphery module. */
|
|
7
|
+
peripheryPackage: string;
|
|
8
|
+
}
|
|
9
|
+
export declare const SUI_DEPLOYMENT_DEV: Partial<Record<SuiChain, SuiDeployment>>;
|
|
10
|
+
/** Returns `null` for an unregistered SuiChain in DEV; throws for
|
|
11
|
+
* STAGING/PRODUCTION (no Sui deploy yet). */
|
|
12
|
+
export declare function SuiDeploymentFor(chain: SuiChain, mode: EnvMode): SuiDeployment | null;
|
|
13
|
+
/** Per-pool Sui addresses, keyed by `[poolKey][SuiChain]`. `poolKey` matches
|
|
14
|
+
* the key used by `POOL_INFO_Dev` (e.g. "USDC_USDT"). Mirrors `SVM_POOLS_DEV`.
|
|
15
|
+
* - Adding a brand-new pool requires a new key here AND a new pool object
|
|
16
|
+
* in `aggregated/dev.ts` with `...SUI_POOLS_DEV.<key>` in its
|
|
17
|
+
* `peripheryInfo`. */
|
|
18
|
+
export declare const SUI_POOLS_DEV: {
|
|
19
|
+
USDC_USDT: {
|
|
20
|
+
1001: {
|
|
21
|
+
poolId: string;
|
|
22
|
+
managerCapId: string;
|
|
23
|
+
peripheryPackage: string;
|
|
24
|
+
token0: {
|
|
25
|
+
address: string;
|
|
26
|
+
symbol: string;
|
|
27
|
+
isNative: false;
|
|
28
|
+
decimal: number;
|
|
29
|
+
chainId: CHAIN.SUI;
|
|
30
|
+
};
|
|
31
|
+
token1: {
|
|
32
|
+
address: string;
|
|
33
|
+
symbol: string;
|
|
34
|
+
isNative: false;
|
|
35
|
+
decimal: number;
|
|
36
|
+
chainId: CHAIN.SUI;
|
|
37
|
+
};
|
|
38
|
+
chain: string;
|
|
39
|
+
};
|
|
40
|
+
};
|
|
41
|
+
};
|
|
42
|
+
//# sourceMappingURL=sui.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"sui.d.ts","sourceRoot":"","sources":["../../src/deployment/sui.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,EAAE,OAAO,EAAE,MAAM,UAAU,CAAC;AAC1C,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,mBAAmB,CAAC;AAIlD;2EAC2E;AAC3E,MAAM,WAAW,aAAa;IAC5B,qDAAqD;IACrD,gBAAgB,EAAE,MAAM,CAAC;CAC1B;AAED,eAAO,MAAM,kBAAkB,EAAE,OAAO,CAAC,MAAM,CAAC,QAAQ,EAAE,aAAa,CAAC,CAKvE,CAAC;AAEF;8CAC8C;AAC9C,wBAAgB,gBAAgB,CAC9B,KAAK,EAAE,QAAQ,EACf,IAAI,EAAE,OAAO,GACZ,aAAa,GAAG,IAAI,CAItB;AAED;;;;yBAIyB;AACzB,eAAO,MAAM,aAAa;;;;;;;;;;;;;;;;;;;;;;;CA4B6C,CAAC"}
|
package/dist/deployment/svm.d.ts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { EnvMode } from "../types";
|
|
1
|
+
import { CHAIN, EnvMode } from "../types";
|
|
2
2
|
import type { SvmChain } from "../types/chain-vm";
|
|
3
|
-
/** Deploy-wide SVM pubkeys. Per-pool addresses live in
|
|
4
|
-
*
|
|
3
|
+
/** Deploy-wide SVM pubkeys. Per-pool addresses live in `SVM_POOLS_<mode>`
|
|
4
|
+
* below; this struct holds the deploy-wide pieces shared across pools. */
|
|
5
5
|
export interface SvmDeployment {
|
|
6
6
|
peripheryPoolProgramId: string;
|
|
7
7
|
actionBoxProgramId: string;
|
|
@@ -16,4 +16,41 @@ export declare const SVM_DEPLOYMENT_DEV: Partial<Record<SvmChain, SvmDeployment>
|
|
|
16
16
|
/** Returns `null` for an unregistered SvmChain in DEV; throws for
|
|
17
17
|
* STAGING/PRODUCTION (no SVM deploy yet). */
|
|
18
18
|
export declare function SvmDeploymentFor(chain: SvmChain, mode: EnvMode): SvmDeployment | null;
|
|
19
|
+
/** Per-pool SVM addresses, keyed by `[poolKey][SvmChain]`. `poolKey` matches
|
|
20
|
+
* the key used by `POOL_INFO_Dev` (e.g. "USDC_USDT").
|
|
21
|
+
* - Adding a new SVM chain entry to an existing pool (e.g. Eclipse under
|
|
22
|
+
* USDC_USDT) requires editing this map only — `aggregated/dev.ts` picks
|
|
23
|
+
* it up automatically via the existing spread.
|
|
24
|
+
* - Adding a brand-new pool requires a new key here AND a new pool object
|
|
25
|
+
* in `aggregated/dev.ts` with `...SVM_POOLS_DEV.<key>` in its
|
|
26
|
+
* `peripheryInfo`. */
|
|
27
|
+
export declare const SVM_POOLS_DEV: {
|
|
28
|
+
USDC_USDT: {
|
|
29
|
+
901: {
|
|
30
|
+
peripheryPool: string;
|
|
31
|
+
poolAuthority: string;
|
|
32
|
+
dust: string;
|
|
33
|
+
poolToken0Vault: string;
|
|
34
|
+
poolToken1Vault: string;
|
|
35
|
+
manager: string;
|
|
36
|
+
tokenProgramId0: string;
|
|
37
|
+
tokenProgramId1: string;
|
|
38
|
+
token0: {
|
|
39
|
+
address: string;
|
|
40
|
+
symbol: string;
|
|
41
|
+
isNative: false;
|
|
42
|
+
decimal: number;
|
|
43
|
+
chainId: CHAIN.SOLANA;
|
|
44
|
+
};
|
|
45
|
+
token1: {
|
|
46
|
+
address: string;
|
|
47
|
+
symbol: string;
|
|
48
|
+
isNative: false;
|
|
49
|
+
decimal: number;
|
|
50
|
+
chainId: CHAIN.SOLANA;
|
|
51
|
+
};
|
|
52
|
+
chain: string;
|
|
53
|
+
};
|
|
54
|
+
};
|
|
55
|
+
};
|
|
19
56
|
//# sourceMappingURL=svm.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"svm.d.ts","sourceRoot":"","sources":["../../src/deployment/svm.ts"],"names":[],"mappings":"AAAA,OAAO,
|
|
1
|
+
{"version":3,"file":"svm.d.ts","sourceRoot":"","sources":["../../src/deployment/svm.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,EAAE,OAAO,EAAE,MAAM,UAAU,CAAC;AAC1C,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,mBAAmB,CAAC;AAIlD;2EAC2E;AAC3E,MAAM,WAAW,aAAa;IAC5B,sBAAsB,EAAE,MAAM,CAAC;IAC/B,kBAAkB,EAAE,MAAM,CAAC;IAC3B,iDAAiD;IACjD,gBAAgB,EAAE,MAAM,CAAC;IACzB,yCAAyC;IACzC,UAAU,EAAE,MAAM,CAAC;IACnB,qEAAqE;IACrE,OAAO,EAAE,MAAM,CAAC;CACjB;AAED,eAAO,MAAM,kBAAkB,EAAE,OAAO,CAAC,MAAM,CAAC,QAAQ,EAAE,aAAa,CAAC,CAQvE,CAAC;AAEF;8CAC8C;AAC9C,wBAAgB,gBAAgB,CAC9B,KAAK,EAAE,QAAQ,EACf,IAAI,EAAE,OAAO,GACZ,aAAa,GAAG,IAAI,CAGtB;AAKD;;;;;;;yBAOyB;AACzB,eAAO,MAAM,aAAa;;;;;;;;;;;;;;;;;;;;;;;;;;;;CA4B6C,CAAC"}
|
package/dist/index.cjs
CHANGED
|
@@ -42,9 +42,13 @@ __export(index_exports, {
|
|
|
42
42
|
PeripheryDeploymentFor: () => PeripheryDeploymentFor,
|
|
43
43
|
PeripheryEventEmitterAddress: () => PeripheryEventEmitterAddress,
|
|
44
44
|
PeripheryManagerAddress: () => PeripheryManagerAddress,
|
|
45
|
+
SUI_DEPLOYMENT_DEV: () => SUI_DEPLOYMENT_DEV,
|
|
46
|
+
SUI_POOLS_DEV: () => SUI_POOLS_DEV,
|
|
45
47
|
SVM_DEPLOYMENT_DEV: () => SVM_DEPLOYMENT_DEV,
|
|
48
|
+
SVM_POOLS_DEV: () => SVM_POOLS_DEV,
|
|
46
49
|
SdkError: () => SdkError,
|
|
47
50
|
SkateGatewayAddress: () => SkateGatewayAddress,
|
|
51
|
+
SuiDeploymentFor: () => SuiDeploymentFor,
|
|
48
52
|
SvmDeploymentFor: () => SvmDeploymentFor,
|
|
49
53
|
TaskPhase: () => TaskPhase,
|
|
50
54
|
VM: () => VM,
|
|
@@ -305,6 +309,72 @@ function SvmDeploymentFor(chain, mode) {
|
|
|
305
309
|
if (mode !== "DEV") return notDeployed("SvmDeploymentFor", mode, "SDK v2 SVM side");
|
|
306
310
|
return SVM_DEPLOYMENT_DEV[chain] ?? null;
|
|
307
311
|
}
|
|
312
|
+
var TOKEN_PROGRAM_ID = "TokenkegQfeZyiNwAJbNbGKPFXCWuBvf9Ss623VQ5DA";
|
|
313
|
+
var SVM_POOLS_DEV = {
|
|
314
|
+
USDC_USDT: {
|
|
315
|
+
[901 /* SOLANA */]: {
|
|
316
|
+
peripheryPool: "G2j8vLu3ryzUqPYpknpBcBLDcFiiRmXtB7z9Dpg9dVxe",
|
|
317
|
+
poolAuthority: "2Mvbo1TrsVeqyjQwNcdDDGjFNbwMk4tV8oD2TN2fV4Nw",
|
|
318
|
+
dust: "4m1AdUZvYJUSMTYpFH8df1JrgHTqUeKA3Xf7DapB4VcX",
|
|
319
|
+
poolToken0Vault: "BihGfVYmaT4KpiHiBLwH2ad9Q2ybYVHS2Bd3hQtzg486",
|
|
320
|
+
poolToken1Vault: "3DW4k4ims6dFB2cXBk5m1uAfh1zowuj9CzBbF4jm1FRh",
|
|
321
|
+
manager: "SGMSTk5t2gmiHKQjtb9XV6qviasgD5UKTsVMHLGCSZA",
|
|
322
|
+
tokenProgramId0: TOKEN_PROGRAM_ID,
|
|
323
|
+
tokenProgramId1: TOKEN_PROGRAM_ID,
|
|
324
|
+
token0: {
|
|
325
|
+
address: "EPjFWdd5AufqSSqeM2qN1xzybapC8G4wEGGkZwyTDt1v",
|
|
326
|
+
symbol: "USDC",
|
|
327
|
+
isNative: false,
|
|
328
|
+
decimal: 6,
|
|
329
|
+
chainId: 901 /* SOLANA */
|
|
330
|
+
},
|
|
331
|
+
token1: {
|
|
332
|
+
address: "Es9vMFrzaCERmJfrF4H2FYD4KCoNkY11McCe8BenwNYB",
|
|
333
|
+
symbol: "USDT",
|
|
334
|
+
isNative: false,
|
|
335
|
+
decimal: 6,
|
|
336
|
+
chainId: 901 /* SOLANA */
|
|
337
|
+
},
|
|
338
|
+
chain: "SOLANA"
|
|
339
|
+
}
|
|
340
|
+
}
|
|
341
|
+
};
|
|
342
|
+
|
|
343
|
+
// src/deployment/sui.ts
|
|
344
|
+
var SUI_DEPLOYMENT_DEV = {
|
|
345
|
+
[1001 /* SUI */]: {
|
|
346
|
+
peripheryPackage: "0x96e1d3897efee30bede047a14d186a952350d4759d3175f76ff6ac2c4a121901"
|
|
347
|
+
}
|
|
348
|
+
};
|
|
349
|
+
function SuiDeploymentFor(chain, mode) {
|
|
350
|
+
if (mode !== "DEV")
|
|
351
|
+
return notDeployed("SuiDeploymentFor", mode, "SDK v2 Sui side");
|
|
352
|
+
return SUI_DEPLOYMENT_DEV[chain] ?? null;
|
|
353
|
+
}
|
|
354
|
+
var SUI_POOLS_DEV = {
|
|
355
|
+
USDC_USDT: {
|
|
356
|
+
[1001 /* SUI */]: {
|
|
357
|
+
poolId: "0xc014f7cb0a2604fb887d09165242828e6fe913f30d7ae2bea80199caed5ccbcb",
|
|
358
|
+
managerCapId: "0xca34c6dff464f42a349294fa9fbe67a6d72eb999081db8de3fd56672b68863ee",
|
|
359
|
+
peripheryPackage: "0x96e1d3897efee30bede047a14d186a952350d4759d3175f76ff6ac2c4a121901",
|
|
360
|
+
token0: {
|
|
361
|
+
address: "0xdba34672e30cb065b1f93e3ab55318768fd6fef66c15942c9f7cb846e2f900e7::usdc::USDC",
|
|
362
|
+
symbol: "USDC",
|
|
363
|
+
isNative: false,
|
|
364
|
+
decimal: 6,
|
|
365
|
+
chainId: 1001 /* SUI */
|
|
366
|
+
},
|
|
367
|
+
token1: {
|
|
368
|
+
address: "0x375f70cf2ae4c00bf37117d0c85a2c71545e6ee05c4a5c7d282cd66a4504b068::usdt::USDT",
|
|
369
|
+
symbol: "USDT",
|
|
370
|
+
isNative: false,
|
|
371
|
+
decimal: 6,
|
|
372
|
+
chainId: 1001 /* SUI */
|
|
373
|
+
},
|
|
374
|
+
chain: "SUI"
|
|
375
|
+
}
|
|
376
|
+
}
|
|
377
|
+
};
|
|
308
378
|
|
|
309
379
|
// src/deployment/aggregated/dev.ts
|
|
310
380
|
var POOL_INFO_Dev = {
|
|
@@ -332,41 +402,47 @@ var POOL_INFO_Dev = {
|
|
|
332
402
|
address: "0x0433CCB013a590eA4231aAC9ddf05bb753c14127",
|
|
333
403
|
chain: "ARBITRUM"
|
|
334
404
|
},
|
|
335
|
-
|
|
405
|
+
...SVM_POOLS_DEV.USDC_USDT,
|
|
406
|
+
...SUI_POOLS_DEV.USDC_USDT
|
|
407
|
+
}
|
|
408
|
+
}
|
|
409
|
+
};
|
|
410
|
+
|
|
411
|
+
// src/deployment/aggregated/staging.ts
|
|
412
|
+
var POOL_INFO_Staging = {};
|
|
413
|
+
|
|
414
|
+
// src/deployment/aggregated/production.ts
|
|
415
|
+
var POOL_INFO_Production = {
|
|
416
|
+
USDC_USDT: {
|
|
417
|
+
kernelPool: "0x9D62b2b6243627518072e07DaE6443E54e8baA1C",
|
|
418
|
+
token0: "USDC",
|
|
419
|
+
token1: "USDT",
|
|
420
|
+
feeBps: 1,
|
|
421
|
+
peripheryInfo: {
|
|
422
|
+
[1001 /* SUI */]: {
|
|
423
|
+
poolId: "0xc014f7cb0a2604fb887d09165242828e6fe913f30d7ae2bea80199caed5ccbcb",
|
|
424
|
+
managerCapId: "0xca34c6dff464f42a349294fa9fbe67a6d72eb999081db8de3fd56672b68863ee",
|
|
425
|
+
peripheryPackage: "0x96e1d3897efee30bede047a14d186a952350d4759d3175f76ff6ac2c4a121901",
|
|
336
426
|
token0: {
|
|
337
|
-
address: "
|
|
427
|
+
address: "0xdba34672e30cb065b1f93e3ab55318768fd6fef66c15942c9f7cb846e2f900e7::usdc::USDC",
|
|
338
428
|
symbol: "USDC",
|
|
339
|
-
isNative: false,
|
|
340
429
|
decimal: 6,
|
|
341
|
-
chainId:
|
|
430
|
+
chainId: 1001 /* SUI */,
|
|
431
|
+
isNative: false
|
|
342
432
|
},
|
|
343
433
|
token1: {
|
|
344
|
-
address: "
|
|
434
|
+
address: "0x375f70cf2ae4c00bf37117d0c85a2c71545e6ee05c4a5c7d282cd66a4504b068::usdt::USDT",
|
|
345
435
|
symbol: "USDT",
|
|
346
|
-
isNative: false,
|
|
347
436
|
decimal: 6,
|
|
348
|
-
chainId:
|
|
437
|
+
chainId: 1001 /* SUI */,
|
|
438
|
+
isNative: false
|
|
349
439
|
},
|
|
350
|
-
|
|
351
|
-
poolAuthority: "2Mvbo1TrsVeqyjQwNcdDDGjFNbwMk4tV8oD2TN2fV4Nw",
|
|
352
|
-
dust: "4m1AdUZvYJUSMTYpFH8df1JrgHTqUeKA3Xf7DapB4VcX",
|
|
353
|
-
poolToken0Vault: "BihGfVYmaT4KpiHiBLwH2ad9Q2ybYVHS2Bd3hQtzg486",
|
|
354
|
-
poolToken1Vault: "3DW4k4ims6dFB2cXBk5m1uAfh1zowuj9CzBbF4jm1FRh",
|
|
355
|
-
manager: "SGMSTk5t2gmiHKQjtb9XV6qviasgD5UKTsVMHLGCSZA",
|
|
356
|
-
tokenProgramId0: "TokenkegQfeZyiNwAJbNbGKPFXCWuBvf9Ss623VQ5DA",
|
|
357
|
-
tokenProgramId1: "TokenkegQfeZyiNwAJbNbGKPFXCWuBvf9Ss623VQ5DA",
|
|
358
|
-
chain: "SOLANA"
|
|
440
|
+
chain: "SUI"
|
|
359
441
|
}
|
|
360
442
|
}
|
|
361
443
|
}
|
|
362
444
|
};
|
|
363
445
|
|
|
364
|
-
// src/deployment/aggregated/staging.ts
|
|
365
|
-
var POOL_INFO_Staging = {};
|
|
366
|
-
|
|
367
|
-
// src/deployment/aggregated/production.ts
|
|
368
|
-
var POOL_INFO_Production = {};
|
|
369
|
-
|
|
370
446
|
// src/deployment/aggregated/retrieval.ts
|
|
371
447
|
function getAllPoolInfo(mode = "PRODUCTION") {
|
|
372
448
|
switch (mode) {
|
|
@@ -453,7 +529,8 @@ function getPeripheryDetailsByKernelPoolAndChainId(kernelPool, chainId, mode = "
|
|
|
453
529
|
const info = getAllPoolInfo(mode);
|
|
454
530
|
return info[poolKey]?.peripheryInfo[chainId] ?? null;
|
|
455
531
|
}
|
|
456
|
-
function findTokensBySymbol(
|
|
532
|
+
function findTokensBySymbol(args) {
|
|
533
|
+
const { symbol, chainIds, mode = "PRODUCTION" } = args;
|
|
457
534
|
const normalized = symbol.toLowerCase();
|
|
458
535
|
const chains = chainIds ?? getSupportedChains(mode);
|
|
459
536
|
const out = [];
|
|
@@ -1029,9 +1106,13 @@ function addDelta(x, y) {
|
|
|
1029
1106
|
PeripheryDeploymentFor,
|
|
1030
1107
|
PeripheryEventEmitterAddress,
|
|
1031
1108
|
PeripheryManagerAddress,
|
|
1109
|
+
SUI_DEPLOYMENT_DEV,
|
|
1110
|
+
SUI_POOLS_DEV,
|
|
1032
1111
|
SVM_DEPLOYMENT_DEV,
|
|
1112
|
+
SVM_POOLS_DEV,
|
|
1033
1113
|
SdkError,
|
|
1034
1114
|
SkateGatewayAddress,
|
|
1115
|
+
SuiDeploymentFor,
|
|
1035
1116
|
SvmDeploymentFor,
|
|
1036
1117
|
TaskPhase,
|
|
1037
1118
|
VM,
|