boing-sdk 0.3.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +26 -0
- package/README.md +191 -0
- package/dist/accessList.d.ts +22 -0
- package/dist/accessList.d.ts.map +1 -0
- package/dist/accessList.js +45 -0
- package/dist/bincode.d.ts +92 -0
- package/dist/bincode.d.ts.map +1 -0
- package/dist/bincode.js +154 -0
- package/dist/callAbi.d.ts +119 -0
- package/dist/callAbi.d.ts.map +1 -0
- package/dist/callAbi.js +156 -0
- package/dist/calldata.d.ts +35 -0
- package/dist/calldata.d.ts.map +1 -0
- package/dist/calldata.js +93 -0
- package/dist/canonicalDeployArtifacts.d.ts +154 -0
- package/dist/canonicalDeployArtifacts.d.ts.map +1 -0
- package/dist/canonicalDeployArtifacts.js +271 -0
- package/dist/canonicalTestnet.d.ts +15 -0
- package/dist/canonicalTestnet.d.ts.map +1 -0
- package/dist/canonicalTestnet.js +15 -0
- package/dist/canonicalTestnetDex.d.ts +17 -0
- package/dist/canonicalTestnetDex.d.ts.map +1 -0
- package/dist/canonicalTestnetDex.js +17 -0
- package/dist/chainIds.d.ts +18 -0
- package/dist/chainIds.d.ts.map +1 -0
- package/dist/chainIds.js +56 -0
- package/dist/client.d.ts +223 -0
- package/dist/client.d.ts.map +1 -0
- package/dist/client.js +659 -0
- package/dist/connectionMonitor.d.ts +47 -0
- package/dist/connectionMonitor.d.ts.map +1 -0
- package/dist/connectionMonitor.js +93 -0
- package/dist/create2.d.ts +94 -0
- package/dist/create2.d.ts.map +1 -0
- package/dist/create2.js +225 -0
- package/dist/dappDeploy.d.ts +100 -0
- package/dist/dappDeploy.d.ts.map +1 -0
- package/dist/dappDeploy.js +140 -0
- package/dist/dappUiHelpers.d.ts +28 -0
- package/dist/dappUiHelpers.d.ts.map +1 -0
- package/dist/dappUiHelpers.js +69 -0
- package/dist/defaultReferenceFungibleSecuredRuntimeBytecodeHex.d.ts +6 -0
- package/dist/defaultReferenceFungibleSecuredRuntimeBytecodeHex.d.ts.map +1 -0
- package/dist/defaultReferenceFungibleSecuredRuntimeBytecodeHex.js +5 -0
- package/dist/defaultReferenceFungibleSecuredTemplateBytecodeHex.d.ts +6 -0
- package/dist/defaultReferenceFungibleSecuredTemplateBytecodeHex.d.ts.map +1 -0
- package/dist/defaultReferenceFungibleSecuredTemplateBytecodeHex.js +5 -0
- package/dist/defaultReferenceFungibleTemplateBytecodeHex.d.ts +6 -0
- package/dist/defaultReferenceFungibleTemplateBytecodeHex.d.ts.map +1 -0
- package/dist/defaultReferenceFungibleTemplateBytecodeHex.js +5 -0
- package/dist/defaultReferenceNftCollectionTemplateBytecodeHex.d.ts +7 -0
- package/dist/defaultReferenceNftCollectionTemplateBytecodeHex.d.ts.map +1 -0
- package/dist/defaultReferenceNftCollectionTemplateBytecodeHex.js +6 -0
- package/dist/dexIntegration.d.ts +61 -0
- package/dist/dexIntegration.d.ts.map +1 -0
- package/dist/dexIntegration.js +193 -0
- package/dist/erc721Logs.d.ts +21 -0
- package/dist/erc721Logs.d.ts.map +1 -0
- package/dist/erc721Logs.js +69 -0
- package/dist/errors.d.ts +60 -0
- package/dist/errors.d.ts.map +1 -0
- package/dist/errors.js +153 -0
- package/dist/hex.d.ts +27 -0
- package/dist/hex.d.ts.map +1 -0
- package/dist/hex.js +82 -0
- package/dist/index.d.ts +83 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +78 -0
- package/dist/indexerBatch.d.ts +111 -0
- package/dist/indexerBatch.d.ts.map +1 -0
- package/dist/indexerBatch.js +253 -0
- package/dist/indexerGaps.d.ts +50 -0
- package/dist/indexerGaps.d.ts.map +1 -0
- package/dist/indexerGaps.js +117 -0
- package/dist/indexerSync.d.ts +61 -0
- package/dist/indexerSync.d.ts.map +1 -0
- package/dist/indexerSync.js +100 -0
- package/dist/nativeAmm.d.ts +64 -0
- package/dist/nativeAmm.d.ts.map +1 -0
- package/dist/nativeAmm.js +174 -0
- package/dist/nativeAmmLogs.d.ts +48 -0
- package/dist/nativeAmmLogs.d.ts.map +1 -0
- package/dist/nativeAmmLogs.js +114 -0
- package/dist/nativeAmmLpVault.d.ts +94 -0
- package/dist/nativeAmmLpVault.d.ts.map +1 -0
- package/dist/nativeAmmLpVault.js +205 -0
- package/dist/nativeAmmPool.d.ts +124 -0
- package/dist/nativeAmmPool.d.ts.map +1 -0
- package/dist/nativeAmmPool.js +245 -0
- package/dist/nativeContractSubmit.d.ts +26 -0
- package/dist/nativeContractSubmit.d.ts.map +1 -0
- package/dist/nativeContractSubmit.js +23 -0
- package/dist/nativeDexDirectory.d.ts +83 -0
- package/dist/nativeDexDirectory.d.ts.map +1 -0
- package/dist/nativeDexDirectory.js +147 -0
- package/dist/nativeDexDirectoryApi.d.ts +121 -0
- package/dist/nativeDexDirectoryApi.d.ts.map +1 -0
- package/dist/nativeDexDirectoryApi.js +408 -0
- package/dist/nativeDexFactory.d.ts +25 -0
- package/dist/nativeDexFactory.d.ts.map +1 -0
- package/dist/nativeDexFactory.js +72 -0
- package/dist/nativeDexFactoryLogs.d.ts +19 -0
- package/dist/nativeDexFactoryLogs.d.ts.map +1 -0
- package/dist/nativeDexFactoryLogs.js +61 -0
- package/dist/nativeDexFactoryPool.d.ts +61 -0
- package/dist/nativeDexFactoryPool.d.ts.map +1 -0
- package/dist/nativeDexFactoryPool.js +120 -0
- package/dist/nativeDexIndexerStats.d.ts +96 -0
- package/dist/nativeDexIndexerStats.d.ts.map +1 -0
- package/dist/nativeDexIndexerStats.js +448 -0
- package/dist/nativeDexLedgerRouter.d.ts +67 -0
- package/dist/nativeDexLedgerRouter.d.ts.map +1 -0
- package/dist/nativeDexLedgerRouter.js +108 -0
- package/dist/nativeDexLpPositions.d.ts +39 -0
- package/dist/nativeDexLpPositions.d.ts.map +1 -0
- package/dist/nativeDexLpPositions.js +69 -0
- package/dist/nativeDexNftIndexer.d.ts +26 -0
- package/dist/nativeDexNftIndexer.d.ts.map +1 -0
- package/dist/nativeDexNftIndexer.js +50 -0
- package/dist/nativeDexPoolHistory.d.ts +40 -0
- package/dist/nativeDexPoolHistory.d.ts.map +1 -0
- package/dist/nativeDexPoolHistory.js +110 -0
- package/dist/nativeDexReceiptArchive.d.ts +25 -0
- package/dist/nativeDexReceiptArchive.d.ts.map +1 -0
- package/dist/nativeDexReceiptArchive.js +47 -0
- package/dist/nativeDexRouting.d.ts +160 -0
- package/dist/nativeDexRouting.d.ts.map +1 -0
- package/dist/nativeDexRouting.js +345 -0
- package/dist/nativeDexSeamless.d.ts +86 -0
- package/dist/nativeDexSeamless.d.ts.map +1 -0
- package/dist/nativeDexSeamless.js +131 -0
- package/dist/nativeDexSwap2Router.d.ts +45 -0
- package/dist/nativeDexSwap2Router.d.ts.map +1 -0
- package/dist/nativeDexSwap2Router.js +276 -0
- package/dist/nativeLpShareToken.d.ts +54 -0
- package/dist/nativeLpShareToken.d.ts.map +1 -0
- package/dist/nativeLpShareToken.js +135 -0
- package/dist/nativeTokenSecurity.d.ts +59 -0
- package/dist/nativeTokenSecurity.d.ts.map +1 -0
- package/dist/nativeTokenSecurity.js +59 -0
- package/dist/networkProfile.d.ts +8 -0
- package/dist/networkProfile.d.ts.map +1 -0
- package/dist/networkProfile.js +29 -0
- package/dist/newHeadsWs.d.ts +43 -0
- package/dist/newHeadsWs.d.ts.map +1 -0
- package/dist/newHeadsWs.js +139 -0
- package/dist/preflightGate.d.ts +16 -0
- package/dist/preflightGate.d.ts.map +1 -0
- package/dist/preflightGate.js +29 -0
- package/dist/receiptLogs.d.ts +29 -0
- package/dist/receiptLogs.d.ts.map +1 -0
- package/dist/receiptLogs.js +66 -0
- package/dist/referenceFungibleSecuredDeployBytecode.d.ts +54 -0
- package/dist/referenceFungibleSecuredDeployBytecode.d.ts.map +1 -0
- package/dist/referenceFungibleSecuredDeployBytecode.js +274 -0
- package/dist/referenceNft.d.ts +14 -0
- package/dist/referenceNft.d.ts.map +1 -0
- package/dist/referenceNft.js +34 -0
- package/dist/referenceToken.d.ts +14 -0
- package/dist/referenceToken.d.ts.map +1 -0
- package/dist/referenceToken.js +29 -0
- package/dist/retryAfter.d.ts +6 -0
- package/dist/retryAfter.d.ts.map +1 -0
- package/dist/retryAfter.js +24 -0
- package/dist/rpcCapabilities.d.ts +43 -0
- package/dist/rpcCapabilities.d.ts.map +1 -0
- package/dist/rpcCapabilities.js +159 -0
- package/dist/rpcDoctor.d.ts +27 -0
- package/dist/rpcDoctor.d.ts.map +1 -0
- package/dist/rpcDoctor.js +66 -0
- package/dist/rpcSurfaceUi.d.ts +32 -0
- package/dist/rpcSurfaceUi.d.ts.map +1 -0
- package/dist/rpcSurfaceUi.js +49 -0
- package/dist/submitFlow.d.ts +70 -0
- package/dist/submitFlow.d.ts.map +1 -0
- package/dist/submitFlow.js +121 -0
- package/dist/transactionBuilder.d.ts +55 -0
- package/dist/transactionBuilder.d.ts.map +1 -0
- package/dist/transactionBuilder.js +100 -0
- package/dist/types.d.ts +436 -0
- package/dist/types.d.ts.map +1 -0
- package/dist/types.js +4 -0
- package/dist/walletProvider.d.ts +46 -0
- package/dist/walletProvider.d.ts.map +1 -0
- package/dist/walletProvider.js +126 -0
- package/package.json +44 -0
|
@@ -0,0 +1,47 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Polling “connection” snapshot for dApp headers / settings screens (framework-agnostic).
|
|
3
|
+
* Wire **`onUpdate`** into React/Vue/Svelte setState, or read **`getSnapshot()`** from a timer.
|
|
4
|
+
*/
|
|
5
|
+
import type { BoingClient } from './client.js';
|
|
6
|
+
import type { BoingHealth, BoingHealthRpcSurface, NetworkInfo } from './types.js';
|
|
7
|
+
export interface BoingConnectionSnapshot {
|
|
8
|
+
baseUrl: string;
|
|
9
|
+
updatedAtMs: number;
|
|
10
|
+
loading: boolean;
|
|
11
|
+
health: BoingHealth | null;
|
|
12
|
+
networkInfo: NetworkInfo | null;
|
|
13
|
+
chainId: number | null;
|
|
14
|
+
headHeight: number | null;
|
|
15
|
+
rpcSurface: BoingHealthRpcSurface | null;
|
|
16
|
+
lastError: unknown;
|
|
17
|
+
/** From the last successful JSON-RPC **`POST /`** on the client, when exposed. */
|
|
18
|
+
lastRequestId: string | undefined;
|
|
19
|
+
}
|
|
20
|
+
export interface BoingConnectionMonitorOptions {
|
|
21
|
+
/** Default **12_000** ms. */
|
|
22
|
+
pollIntervalMs?: number;
|
|
23
|
+
/** Also fetch **`boing_getNetworkInfo`** each tick (default **true**). */
|
|
24
|
+
includeNetworkInfo?: boolean;
|
|
25
|
+
/** Called after each **`refresh`** completes (success or partial failure). */
|
|
26
|
+
onUpdate?: (snap: BoingConnectionSnapshot) => void;
|
|
27
|
+
}
|
|
28
|
+
/**
|
|
29
|
+
* Polls **`boing_health`** and optionally **`boing_getNetworkInfo`**, merges **`rpc_surface`**, and exposes **`lastRequestId`**.
|
|
30
|
+
*/
|
|
31
|
+
export declare class BoingConnectionMonitor {
|
|
32
|
+
private readonly client;
|
|
33
|
+
private readonly options;
|
|
34
|
+
private snap;
|
|
35
|
+
private timer;
|
|
36
|
+
private readonly pollIntervalMs;
|
|
37
|
+
private readonly includeNetworkInfo;
|
|
38
|
+
constructor(client: BoingClient, options?: BoingConnectionMonitorOptions);
|
|
39
|
+
getSnapshot(): BoingConnectionSnapshot;
|
|
40
|
+
/** Single refresh; safe to call manually (e.g. on “Retry”). */
|
|
41
|
+
refresh(): Promise<void>;
|
|
42
|
+
/** Start periodic **`refresh`**. */
|
|
43
|
+
start(): void;
|
|
44
|
+
/** Stop polling (does not clear last snapshot). */
|
|
45
|
+
stop(): void;
|
|
46
|
+
}
|
|
47
|
+
//# sourceMappingURL=connectionMonitor.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"connectionMonitor.d.ts","sourceRoot":"","sources":["../src/connectionMonitor.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,aAAa,CAAC;AAC/C,OAAO,KAAK,EAAE,WAAW,E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|
|
2
|
+
* Polling “connection” snapshot for dApp headers / settings screens (framework-agnostic).
|
|
3
|
+
* Wire **`onUpdate`** into React/Vue/Svelte setState, or read **`getSnapshot()`** from a timer.
|
|
4
|
+
*/
|
|
5
|
+
import { mergeRpcSurface } from './rpcSurfaceUi.js';
|
|
6
|
+
function emptySnapshot(baseUrl) {
|
|
7
|
+
return {
|
|
8
|
+
baseUrl,
|
|
9
|
+
updatedAtMs: 0,
|
|
10
|
+
loading: false,
|
|
11
|
+
health: null,
|
|
12
|
+
networkInfo: null,
|
|
13
|
+
chainId: null,
|
|
14
|
+
headHeight: null,
|
|
15
|
+
rpcSurface: null,
|
|
16
|
+
lastError: undefined,
|
|
17
|
+
lastRequestId: undefined,
|
|
18
|
+
};
|
|
19
|
+
}
|
|
20
|
+
/**
|
|
21
|
+
* Polls **`boing_health`** and optionally **`boing_getNetworkInfo`**, merges **`rpc_surface`**, and exposes **`lastRequestId`**.
|
|
22
|
+
*/
|
|
23
|
+
export class BoingConnectionMonitor {
|
|
24
|
+
constructor(client, options = {}) {
|
|
25
|
+
this.client = client;
|
|
26
|
+
this.options = options;
|
|
27
|
+
this.timer = null;
|
|
28
|
+
this.pollIntervalMs = Math.max(2000, options.pollIntervalMs ?? 12000);
|
|
29
|
+
this.includeNetworkInfo = options.includeNetworkInfo !== false;
|
|
30
|
+
this.snap = emptySnapshot(client.getBaseUrl());
|
|
31
|
+
}
|
|
32
|
+
getSnapshot() {
|
|
33
|
+
return { ...this.snap, loading: this.snap.loading };
|
|
34
|
+
}
|
|
35
|
+
/** Single refresh; safe to call manually (e.g. on “Retry”). */
|
|
36
|
+
async refresh() {
|
|
37
|
+
this.snap.loading = true;
|
|
38
|
+
this.snap.baseUrl = this.client.getBaseUrl();
|
|
39
|
+
this.options.onUpdate?.({ ...this.snap });
|
|
40
|
+
let health = null;
|
|
41
|
+
let networkInfo = null;
|
|
42
|
+
let lastErr;
|
|
43
|
+
let networkInfoAttempted = false;
|
|
44
|
+
try {
|
|
45
|
+
health = await this.client.health();
|
|
46
|
+
}
|
|
47
|
+
catch (e) {
|
|
48
|
+
lastErr = e;
|
|
49
|
+
}
|
|
50
|
+
if (this.includeNetworkInfo) {
|
|
51
|
+
networkInfoAttempted = true;
|
|
52
|
+
try {
|
|
53
|
+
networkInfo = await this.client.getNetworkInfo();
|
|
54
|
+
}
|
|
55
|
+
catch (e) {
|
|
56
|
+
lastErr = lastErr ?? e;
|
|
57
|
+
}
|
|
58
|
+
}
|
|
59
|
+
const surface = mergeRpcSurface(health, networkInfo);
|
|
60
|
+
const chainId = networkInfo?.chain_id ?? health?.chain_id ?? null;
|
|
61
|
+
const headHeight = networkInfo?.head_height ?? health?.head_height ?? null;
|
|
62
|
+
const failed = health == null || (networkInfoAttempted && networkInfo == null);
|
|
63
|
+
this.snap = {
|
|
64
|
+
baseUrl: this.client.getBaseUrl(),
|
|
65
|
+
updatedAtMs: Date.now(),
|
|
66
|
+
loading: false,
|
|
67
|
+
health,
|
|
68
|
+
networkInfo,
|
|
69
|
+
chainId,
|
|
70
|
+
headHeight,
|
|
71
|
+
rpcSurface: surface,
|
|
72
|
+
lastError: failed ? lastErr : undefined,
|
|
73
|
+
lastRequestId: this.client.getLastXRequestId(),
|
|
74
|
+
};
|
|
75
|
+
this.options.onUpdate?.(this.getSnapshot());
|
|
76
|
+
}
|
|
77
|
+
/** Start periodic **`refresh`**. */
|
|
78
|
+
start() {
|
|
79
|
+
if (this.timer != null)
|
|
80
|
+
return;
|
|
81
|
+
void this.refresh();
|
|
82
|
+
this.timer = setInterval(() => {
|
|
83
|
+
void this.refresh();
|
|
84
|
+
}, this.pollIntervalMs);
|
|
85
|
+
}
|
|
86
|
+
/** Stop polling (does not clear last snapshot). */
|
|
87
|
+
stop() {
|
|
88
|
+
if (this.timer != null) {
|
|
89
|
+
clearInterval(this.timer);
|
|
90
|
+
this.timer = null;
|
|
91
|
+
}
|
|
92
|
+
}
|
|
93
|
+
}
|
|
@@ -0,0 +1,94 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Predict CREATE2 contract `AccountId` (matches `boing_primitives::create2_contract_address`).
|
|
3
|
+
*/
|
|
4
|
+
/** Same bytes as `boing_execution::native_amm::NATIVE_CP_POOL_CREATE2_SALT_V1`. */
|
|
5
|
+
export declare const NATIVE_CP_POOL_CREATE2_SALT_V1: Uint8Array<ArrayBuffer>;
|
|
6
|
+
/** Same bytes as `boing_execution::native_amm::NATIVE_CP_POOL_CREATE2_SALT_V2` (token-hook pool bytecode). */
|
|
7
|
+
export declare const NATIVE_CP_POOL_CREATE2_SALT_V2: Uint8Array<ArrayBuffer>;
|
|
8
|
+
/** Same bytes as `boing_execution::native_amm::NATIVE_CP_POOL_CREATE2_SALT_V3` (ledger-only + configurable swap fee). */
|
|
9
|
+
export declare const NATIVE_CP_POOL_CREATE2_SALT_V3: Uint8Array<ArrayBuffer>;
|
|
10
|
+
/** Same bytes as `boing_execution::native_amm::NATIVE_CP_POOL_CREATE2_SALT_V4` (v2 hooks + configurable fee). */
|
|
11
|
+
export declare const NATIVE_CP_POOL_CREATE2_SALT_V4: Uint8Array<ArrayBuffer>;
|
|
12
|
+
/** Same bytes as `boing_execution::native_amm::NATIVE_CP_POOL_CREATE2_SALT_V5` (v4 + `swap_to` recipient). */
|
|
13
|
+
export declare const NATIVE_CP_POOL_CREATE2_SALT_V5: Uint8Array<ArrayBuffer>;
|
|
14
|
+
/** Same bytes as `native_dex_factory::NATIVE_DEX_FACTORY_CREATE2_SALT_V1`. */
|
|
15
|
+
export declare const NATIVE_DEX_FACTORY_CREATE2_SALT_V1: Uint8Array<ArrayBuffer>;
|
|
16
|
+
/** Same bytes as `native_dex_ledger_router::NATIVE_DEX_LEDGER_ROUTER_CREATE2_SALT_V1`. */
|
|
17
|
+
export declare const NATIVE_DEX_LEDGER_ROUTER_CREATE2_SALT_V1: Uint8Array<ArrayBuffer>;
|
|
18
|
+
/** Same bytes as `native_dex_ledger_router::NATIVE_DEX_LEDGER_ROUTER_CREATE2_SALT_V2`. */
|
|
19
|
+
export declare const NATIVE_DEX_LEDGER_ROUTER_CREATE2_SALT_V2: Uint8Array<ArrayBuffer>;
|
|
20
|
+
/** Same bytes as `native_dex_ledger_router::NATIVE_DEX_LEDGER_ROUTER_CREATE2_SALT_V3`. */
|
|
21
|
+
export declare const NATIVE_DEX_LEDGER_ROUTER_CREATE2_SALT_V3: Uint8Array<ArrayBuffer>;
|
|
22
|
+
/** Same bytes as `native_dex_multihop_swap_router::NATIVE_DEX_MULTIHOP_SWAP_ROUTER_CREATE2_SALT_V1`. */
|
|
23
|
+
export declare const NATIVE_DEX_MULTIHOP_SWAP_ROUTER_CREATE2_SALT_V1: Uint8Array<ArrayBuffer>;
|
|
24
|
+
/**
|
|
25
|
+
* @deprecated Same bytes as {@link NATIVE_DEX_MULTIHOP_SWAP_ROUTER_CREATE2_SALT_V1} (Rust
|
|
26
|
+
* `NATIVE_DEX_SWAP2_ROUTER_CREATE2_SALT_V1` alias).
|
|
27
|
+
*/
|
|
28
|
+
export declare const NATIVE_DEX_SWAP2_ROUTER_CREATE2_SALT_V1: Uint8Array<ArrayBuffer>;
|
|
29
|
+
/** Same bytes as `native_lp_share_token::NATIVE_LP_SHARE_TOKEN_CREATE2_SALT_V1`. */
|
|
30
|
+
export declare const NATIVE_LP_SHARE_TOKEN_CREATE2_SALT_V1: Uint8Array<ArrayBuffer>;
|
|
31
|
+
/** Same bytes as `native_amm_lp_vault::NATIVE_AMM_LP_VAULT_CREATE2_SALT_V1`. */
|
|
32
|
+
export declare const NATIVE_AMM_LP_VAULT_CREATE2_SALT_V1: Uint8Array<ArrayBuffer>;
|
|
33
|
+
/** `0x` + 64 hex for {@link NATIVE_CP_POOL_CREATE2_SALT_V1}. */
|
|
34
|
+
export declare function nativeCpPoolCreate2SaltV1Hex(): string;
|
|
35
|
+
/** `0x` + 64 hex for {@link NATIVE_CP_POOL_CREATE2_SALT_V2}. */
|
|
36
|
+
export declare function nativeCpPoolCreate2SaltV2Hex(): string;
|
|
37
|
+
/** `0x` + 64 hex for {@link NATIVE_CP_POOL_CREATE2_SALT_V3}. */
|
|
38
|
+
export declare function nativeCpPoolCreate2SaltV3Hex(): string;
|
|
39
|
+
/** `0x` + 64 hex for {@link NATIVE_CP_POOL_CREATE2_SALT_V4}. */
|
|
40
|
+
export declare function nativeCpPoolCreate2SaltV4Hex(): string;
|
|
41
|
+
/** `0x` + 64 hex for {@link NATIVE_CP_POOL_CREATE2_SALT_V5}. */
|
|
42
|
+
export declare function nativeCpPoolCreate2SaltV5Hex(): string;
|
|
43
|
+
/**
|
|
44
|
+
* Nonce-derived contract `AccountId`: `BLAKE3(sender_32 || deploy_tx_nonce_le_u64)`.
|
|
45
|
+
* Matches `boing_primitives::nonce_derived_contract_address` (deploy with `create2_salt: null`).
|
|
46
|
+
*/
|
|
47
|
+
export declare function predictNonceDerivedContractAddress(senderHex: string, deployTxNonce: bigint): string;
|
|
48
|
+
/**
|
|
49
|
+
* `BLAKE3(domain || deployer_32 || salt_32 || BLAKE3(bytecode))`.
|
|
50
|
+
*/
|
|
51
|
+
export declare function predictCreate2ContractAddress(deployerHex: string, salt32: Uint8Array, bytecode: Uint8Array): string;
|
|
52
|
+
/** Pool address for native CP bytecode + documented v1 salt (deployer = future deployer account). */
|
|
53
|
+
export declare function predictNativeCpPoolCreate2Address(deployerHex: string, poolBytecode: Uint8Array): string;
|
|
54
|
+
/** **v2** pool (token `CALL` hooks) + documented v2 salt. */
|
|
55
|
+
export declare function predictNativeCpPoolV2Create2Address(deployerHex: string, poolBytecodeV2: Uint8Array): string;
|
|
56
|
+
/** **v3** pool (ledger-only + on-chain swap fee bps) + documented v3 salt. */
|
|
57
|
+
export declare function predictNativeCpPoolV3Create2Address(deployerHex: string, poolBytecodeV3: Uint8Array): string;
|
|
58
|
+
/** **v4** pool (v2 hooks + configurable fee) + documented v4 salt. */
|
|
59
|
+
export declare function predictNativeCpPoolV4Create2Address(deployerHex: string, poolBytecodeV4: Uint8Array): string;
|
|
60
|
+
/** **v5** pool (v4 + explicit swap output recipient) + documented v5 salt. */
|
|
61
|
+
export declare function predictNativeCpPoolV5Create2Address(deployerHex: string, poolBytecodeV5: Uint8Array): string;
|
|
62
|
+
/** Pair-directory contract (`native_dex_factory_bytecode`) + documented salt. */
|
|
63
|
+
export declare function predictNativeDexFactoryCreate2Address(deployerHex: string, factoryBytecode: Uint8Array): string;
|
|
64
|
+
/** Ledger router (`native_dex_ledger_router_bytecode`) + documented salt. */
|
|
65
|
+
export declare function predictNativeDexLedgerRouterCreate2Address(deployerHex: string, routerBytecode: Uint8Array): string;
|
|
66
|
+
/** Ledger router v2 (`native_dex_ledger_router_bytecode_v2`) + documented salt. */
|
|
67
|
+
export declare function predictNativeDexLedgerRouterV2Create2Address(deployerHex: string, routerBytecodeV2: Uint8Array): string;
|
|
68
|
+
/** Ledger router v3 (`native_dex_ledger_router_bytecode_v3`) + documented salt. */
|
|
69
|
+
export declare function predictNativeDexLedgerRouterV3Create2Address(deployerHex: string, routerBytecodeV3: Uint8Array): string;
|
|
70
|
+
/** Multihop swap router (`native_dex_multihop_swap_router_bytecode`) + documented salt. */
|
|
71
|
+
export declare function predictNativeDexMultihopSwapRouterCreate2Address(deployerHex: string, routerBytecode: Uint8Array): string;
|
|
72
|
+
/** @deprecated Use {@link predictNativeDexMultihopSwapRouterCreate2Address}. */
|
|
73
|
+
export declare function predictNativeDexSwap2RouterCreate2Address(deployerHex: string, swap2RouterBytecode: Uint8Array): string;
|
|
74
|
+
/** LP share token (`lp_share_token_bytecode`) + documented salt. */
|
|
75
|
+
export declare function predictNativeLpShareTokenCreate2Address(deployerHex: string, bytecode: Uint8Array): string;
|
|
76
|
+
/** Native AMM LP vault (`native_amm_lp_vault_bytecode`) + documented salt. */
|
|
77
|
+
export declare function predictNativeAmmLpVaultCreate2Address(deployerHex: string, bytecode: Uint8Array): string;
|
|
78
|
+
/** `0x` + 64 hex for {@link NATIVE_DEX_FACTORY_CREATE2_SALT_V1}. */
|
|
79
|
+
export declare function nativeDexFactoryCreate2SaltV1Hex(): string;
|
|
80
|
+
/** `0x` + 64 hex for {@link NATIVE_DEX_LEDGER_ROUTER_CREATE2_SALT_V1}. */
|
|
81
|
+
export declare function nativeDexLedgerRouterCreate2SaltV1Hex(): string;
|
|
82
|
+
/** `0x` + 64 hex for {@link NATIVE_DEX_LEDGER_ROUTER_CREATE2_SALT_V2}. */
|
|
83
|
+
export declare function nativeDexLedgerRouterCreate2SaltV2Hex(): string;
|
|
84
|
+
/** `0x` + 64 hex for {@link NATIVE_DEX_LEDGER_ROUTER_CREATE2_SALT_V3}. */
|
|
85
|
+
export declare function nativeDexLedgerRouterCreate2SaltV3Hex(): string;
|
|
86
|
+
/** `0x` + 64 hex for {@link NATIVE_DEX_MULTIHOP_SWAP_ROUTER_CREATE2_SALT_V1}. */
|
|
87
|
+
export declare function nativeDexMultihopSwapRouterCreate2SaltV1Hex(): string;
|
|
88
|
+
/** @deprecated Alias for {@link nativeDexMultihopSwapRouterCreate2SaltV1Hex}. */
|
|
89
|
+
export declare function nativeDexSwap2RouterCreate2SaltV1Hex(): string;
|
|
90
|
+
/** `0x` + 64 hex for {@link NATIVE_LP_SHARE_TOKEN_CREATE2_SALT_V1}. */
|
|
91
|
+
export declare function nativeLpShareTokenCreate2SaltV1Hex(): string;
|
|
92
|
+
/** `0x` + 64 hex for {@link NATIVE_AMM_LP_VAULT_CREATE2_SALT_V1}. */
|
|
93
|
+
export declare function nativeAmmLpVaultCreate2SaltV1Hex(): string;
|
|
94
|
+
//# sourceMappingURL=create2.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"create2.d.ts","sourceRoot":"","sources":["../src/create2.ts"],"names":[],"mappings":"AAAA;;GAEG;AASH,mFAAmF;AACnF,eAAO,MAAM,8BAA8B,yBAKvC,CAAC;AAEL,8GAA8G;AAC9G,eAAO,MAAM,8BAA8B,yBAKvC,CAAC;AAEL,yHAAyH;AACzH,eAAO,MAAM,8BAA8B,yBAKvC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AAI,MAAM,CAEzD;AAED,0EAA0E;AAC1E,wBAAgB,qCAAqC,IAAI,MAAM,CAE9D;AAED,0EAA0E;AAC1E,wBAAgB,qCAAqC,IAAI,MAAM,CAE9D;AAED,0EAA0E;AAC1E,wBAAgB,qCAAqC,IAAI,MAAM,CAE9D;AAED,iFAAiF;AACjF,wBAAgB,2CAA2C,IAAI,MAAM,CAEpE;AAED,iFAAiF;AACjF,wBAAgB,oCAAoC,IAAI,MAAM,CAE7D;AAED,uEAAuE;AACvE,wBAAgB,kCAAkC,IAAI,MAAM,CAE3D;AAED,qEAAqE;AACrE,wBAAgB,gCAAgC,IAAI,MAAM,CAEzD"}
|
package/dist/create2.js
ADDED
|
@@ -0,0 +1,225 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Predict CREATE2 contract `AccountId` (matches `boing_primitives::create2_contract_address`).
|
|
3
|
+
*/
|
|
4
|
+
import { blake3 } from '@noble/hashes/blake3';
|
|
5
|
+
import { concatBytes, writeU64Le } from './bincode.js';
|
|
6
|
+
import { bytesToHex, hexToBytes, validateHex32 } from './hex.js';
|
|
7
|
+
/** Domain separator: `b"boing.create2.v1\\0"` in Rust. */
|
|
8
|
+
const CREATE2_DOMAIN = concatBytes(new TextEncoder().encode('boing.create2.v1'), new Uint8Array([0]));
|
|
9
|
+
/** Same bytes as `boing_execution::native_amm::NATIVE_CP_POOL_CREATE2_SALT_V1`. */
|
|
10
|
+
export const NATIVE_CP_POOL_CREATE2_SALT_V1 = (() => {
|
|
11
|
+
const label = new TextEncoder().encode('BOING_NATIVECP_C2V1');
|
|
12
|
+
const out = new Uint8Array(32);
|
|
13
|
+
out.set(label);
|
|
14
|
+
return out;
|
|
15
|
+
})();
|
|
16
|
+
/** Same bytes as `boing_execution::native_amm::NATIVE_CP_POOL_CREATE2_SALT_V2` (token-hook pool bytecode). */
|
|
17
|
+
export const NATIVE_CP_POOL_CREATE2_SALT_V2 = (() => {
|
|
18
|
+
const label = new TextEncoder().encode('BOING_NATIVECP_C2V2');
|
|
19
|
+
const out = new Uint8Array(32);
|
|
20
|
+
out.set(label);
|
|
21
|
+
return out;
|
|
22
|
+
})();
|
|
23
|
+
/** Same bytes as `boing_execution::native_amm::NATIVE_CP_POOL_CREATE2_SALT_V3` (ledger-only + configurable swap fee). */
|
|
24
|
+
export const NATIVE_CP_POOL_CREATE2_SALT_V3 = (() => {
|
|
25
|
+
const label = new TextEncoder().encode('BOING_NATIVECP_C2V3');
|
|
26
|
+
const out = new Uint8Array(32);
|
|
27
|
+
out.set(label);
|
|
28
|
+
return out;
|
|
29
|
+
})();
|
|
30
|
+
/** Same bytes as `boing_execution::native_amm::NATIVE_CP_POOL_CREATE2_SALT_V4` (v2 hooks + configurable fee). */
|
|
31
|
+
export const NATIVE_CP_POOL_CREATE2_SALT_V4 = (() => {
|
|
32
|
+
const label = new TextEncoder().encode('BOING_NATIVECP_C2V4');
|
|
33
|
+
const out = new Uint8Array(32);
|
|
34
|
+
out.set(label);
|
|
35
|
+
return out;
|
|
36
|
+
})();
|
|
37
|
+
/** Same bytes as `boing_execution::native_amm::NATIVE_CP_POOL_CREATE2_SALT_V5` (v4 + `swap_to` recipient). */
|
|
38
|
+
export const NATIVE_CP_POOL_CREATE2_SALT_V5 = (() => {
|
|
39
|
+
const label = new TextEncoder().encode('BOING_NATIVECP_C2V5');
|
|
40
|
+
const out = new Uint8Array(32);
|
|
41
|
+
out.set(label);
|
|
42
|
+
return out;
|
|
43
|
+
})();
|
|
44
|
+
/** Same bytes as `native_dex_factory::NATIVE_DEX_FACTORY_CREATE2_SALT_V1`. */
|
|
45
|
+
export const NATIVE_DEX_FACTORY_CREATE2_SALT_V1 = (() => {
|
|
46
|
+
const label = new TextEncoder().encode('BOING_NATIVEDEX_FACTORY_V1');
|
|
47
|
+
const out = new Uint8Array(32);
|
|
48
|
+
out.set(label);
|
|
49
|
+
return out;
|
|
50
|
+
})();
|
|
51
|
+
/** Same bytes as `native_dex_ledger_router::NATIVE_DEX_LEDGER_ROUTER_CREATE2_SALT_V1`. */
|
|
52
|
+
export const NATIVE_DEX_LEDGER_ROUTER_CREATE2_SALT_V1 = (() => {
|
|
53
|
+
const label = new TextEncoder().encode('BOING_NATIVEDEX_LROUTER_V1');
|
|
54
|
+
const out = new Uint8Array(32);
|
|
55
|
+
out.set(label);
|
|
56
|
+
return out;
|
|
57
|
+
})();
|
|
58
|
+
/** Same bytes as `native_dex_ledger_router::NATIVE_DEX_LEDGER_ROUTER_CREATE2_SALT_V2`. */
|
|
59
|
+
export const NATIVE_DEX_LEDGER_ROUTER_CREATE2_SALT_V2 = (() => {
|
|
60
|
+
const label = new TextEncoder().encode('BOING_NATIVEDEX_LROUTER_V2');
|
|
61
|
+
const out = new Uint8Array(32);
|
|
62
|
+
out.set(label);
|
|
63
|
+
return out;
|
|
64
|
+
})();
|
|
65
|
+
/** Same bytes as `native_dex_ledger_router::NATIVE_DEX_LEDGER_ROUTER_CREATE2_SALT_V3`. */
|
|
66
|
+
export const NATIVE_DEX_LEDGER_ROUTER_CREATE2_SALT_V3 = (() => {
|
|
67
|
+
const label = new TextEncoder().encode('BOING_NATIVEDEX_LROUTER_V3');
|
|
68
|
+
const out = new Uint8Array(32);
|
|
69
|
+
out.set(label);
|
|
70
|
+
return out;
|
|
71
|
+
})();
|
|
72
|
+
/** Same bytes as `native_dex_multihop_swap_router::NATIVE_DEX_MULTIHOP_SWAP_ROUTER_CREATE2_SALT_V1`. */
|
|
73
|
+
export const NATIVE_DEX_MULTIHOP_SWAP_ROUTER_CREATE2_SALT_V1 = (() => {
|
|
74
|
+
const label = new TextEncoder().encode('BOING_NATIVEDEX_MHOP_V1');
|
|
75
|
+
const out = new Uint8Array(32);
|
|
76
|
+
out.set(label);
|
|
77
|
+
return out;
|
|
78
|
+
})();
|
|
79
|
+
/**
|
|
80
|
+
* @deprecated Same bytes as {@link NATIVE_DEX_MULTIHOP_SWAP_ROUTER_CREATE2_SALT_V1} (Rust
|
|
81
|
+
* `NATIVE_DEX_SWAP2_ROUTER_CREATE2_SALT_V1` alias).
|
|
82
|
+
*/
|
|
83
|
+
export const NATIVE_DEX_SWAP2_ROUTER_CREATE2_SALT_V1 = NATIVE_DEX_MULTIHOP_SWAP_ROUTER_CREATE2_SALT_V1;
|
|
84
|
+
/** Same bytes as `native_lp_share_token::NATIVE_LP_SHARE_TOKEN_CREATE2_SALT_V1`. */
|
|
85
|
+
export const NATIVE_LP_SHARE_TOKEN_CREATE2_SALT_V1 = (() => {
|
|
86
|
+
const label = new TextEncoder().encode('BOING_LP_SHARE_TOKEN_V1');
|
|
87
|
+
const out = new Uint8Array(32);
|
|
88
|
+
out.set(label);
|
|
89
|
+
return out;
|
|
90
|
+
})();
|
|
91
|
+
/** Same bytes as `native_amm_lp_vault::NATIVE_AMM_LP_VAULT_CREATE2_SALT_V1`. */
|
|
92
|
+
export const NATIVE_AMM_LP_VAULT_CREATE2_SALT_V1 = (() => {
|
|
93
|
+
const label = new TextEncoder().encode('BOING_AMM_LP_VAULT_V1');
|
|
94
|
+
const out = new Uint8Array(32);
|
|
95
|
+
out.set(label);
|
|
96
|
+
return out;
|
|
97
|
+
})();
|
|
98
|
+
/** `0x` + 64 hex for {@link NATIVE_CP_POOL_CREATE2_SALT_V1}. */
|
|
99
|
+
export function nativeCpPoolCreate2SaltV1Hex() {
|
|
100
|
+
return validateHex32(bytesToHex(NATIVE_CP_POOL_CREATE2_SALT_V1));
|
|
101
|
+
}
|
|
102
|
+
/** `0x` + 64 hex for {@link NATIVE_CP_POOL_CREATE2_SALT_V2}. */
|
|
103
|
+
export function nativeCpPoolCreate2SaltV2Hex() {
|
|
104
|
+
return validateHex32(bytesToHex(NATIVE_CP_POOL_CREATE2_SALT_V2));
|
|
105
|
+
}
|
|
106
|
+
/** `0x` + 64 hex for {@link NATIVE_CP_POOL_CREATE2_SALT_V3}. */
|
|
107
|
+
export function nativeCpPoolCreate2SaltV3Hex() {
|
|
108
|
+
return validateHex32(bytesToHex(NATIVE_CP_POOL_CREATE2_SALT_V3));
|
|
109
|
+
}
|
|
110
|
+
/** `0x` + 64 hex for {@link NATIVE_CP_POOL_CREATE2_SALT_V4}. */
|
|
111
|
+
export function nativeCpPoolCreate2SaltV4Hex() {
|
|
112
|
+
return validateHex32(bytesToHex(NATIVE_CP_POOL_CREATE2_SALT_V4));
|
|
113
|
+
}
|
|
114
|
+
/** `0x` + 64 hex for {@link NATIVE_CP_POOL_CREATE2_SALT_V5}. */
|
|
115
|
+
export function nativeCpPoolCreate2SaltV5Hex() {
|
|
116
|
+
return validateHex32(bytesToHex(NATIVE_CP_POOL_CREATE2_SALT_V5));
|
|
117
|
+
}
|
|
118
|
+
/**
|
|
119
|
+
* Nonce-derived contract `AccountId`: `BLAKE3(sender_32 || deploy_tx_nonce_le_u64)`.
|
|
120
|
+
* Matches `boing_primitives::nonce_derived_contract_address` (deploy with `create2_salt: null`).
|
|
121
|
+
*/
|
|
122
|
+
export function predictNonceDerivedContractAddress(senderHex, deployTxNonce) {
|
|
123
|
+
const sender = hexToBytes(validateHex32(senderHex));
|
|
124
|
+
if (deployTxNonce < 0n || deployTxNonce > 0xffffffffffffffffn) {
|
|
125
|
+
throw new Error('deployTxNonce must fit u64');
|
|
126
|
+
}
|
|
127
|
+
const preimage = concatBytes(sender, writeU64Le(deployTxNonce));
|
|
128
|
+
return validateHex32(bytesToHex(blake3(preimage)));
|
|
129
|
+
}
|
|
130
|
+
/**
|
|
131
|
+
* `BLAKE3(domain || deployer_32 || salt_32 || BLAKE3(bytecode))`.
|
|
132
|
+
*/
|
|
133
|
+
export function predictCreate2ContractAddress(deployerHex, salt32, bytecode) {
|
|
134
|
+
if (salt32.length !== 32) {
|
|
135
|
+
throw new Error('create2 salt must be exactly 32 bytes');
|
|
136
|
+
}
|
|
137
|
+
const deployer = hexToBytes(validateHex32(deployerHex));
|
|
138
|
+
const codeHash = blake3(bytecode);
|
|
139
|
+
const preimage = concatBytes(CREATE2_DOMAIN, deployer, salt32, codeHash);
|
|
140
|
+
return validateHex32(bytesToHex(blake3(preimage)));
|
|
141
|
+
}
|
|
142
|
+
/** Pool address for native CP bytecode + documented v1 salt (deployer = future deployer account). */
|
|
143
|
+
export function predictNativeCpPoolCreate2Address(deployerHex, poolBytecode) {
|
|
144
|
+
return predictCreate2ContractAddress(deployerHex, NATIVE_CP_POOL_CREATE2_SALT_V1, poolBytecode);
|
|
145
|
+
}
|
|
146
|
+
/** **v2** pool (token `CALL` hooks) + documented v2 salt. */
|
|
147
|
+
export function predictNativeCpPoolV2Create2Address(deployerHex, poolBytecodeV2) {
|
|
148
|
+
return predictCreate2ContractAddress(deployerHex, NATIVE_CP_POOL_CREATE2_SALT_V2, poolBytecodeV2);
|
|
149
|
+
}
|
|
150
|
+
/** **v3** pool (ledger-only + on-chain swap fee bps) + documented v3 salt. */
|
|
151
|
+
export function predictNativeCpPoolV3Create2Address(deployerHex, poolBytecodeV3) {
|
|
152
|
+
return predictCreate2ContractAddress(deployerHex, NATIVE_CP_POOL_CREATE2_SALT_V3, poolBytecodeV3);
|
|
153
|
+
}
|
|
154
|
+
/** **v4** pool (v2 hooks + configurable fee) + documented v4 salt. */
|
|
155
|
+
export function predictNativeCpPoolV4Create2Address(deployerHex, poolBytecodeV4) {
|
|
156
|
+
return predictCreate2ContractAddress(deployerHex, NATIVE_CP_POOL_CREATE2_SALT_V4, poolBytecodeV4);
|
|
157
|
+
}
|
|
158
|
+
/** **v5** pool (v4 + explicit swap output recipient) + documented v5 salt. */
|
|
159
|
+
export function predictNativeCpPoolV5Create2Address(deployerHex, poolBytecodeV5) {
|
|
160
|
+
return predictCreate2ContractAddress(deployerHex, NATIVE_CP_POOL_CREATE2_SALT_V5, poolBytecodeV5);
|
|
161
|
+
}
|
|
162
|
+
/** Pair-directory contract (`native_dex_factory_bytecode`) + documented salt. */
|
|
163
|
+
export function predictNativeDexFactoryCreate2Address(deployerHex, factoryBytecode) {
|
|
164
|
+
return predictCreate2ContractAddress(deployerHex, NATIVE_DEX_FACTORY_CREATE2_SALT_V1, factoryBytecode);
|
|
165
|
+
}
|
|
166
|
+
/** Ledger router (`native_dex_ledger_router_bytecode`) + documented salt. */
|
|
167
|
+
export function predictNativeDexLedgerRouterCreate2Address(deployerHex, routerBytecode) {
|
|
168
|
+
return predictCreate2ContractAddress(deployerHex, NATIVE_DEX_LEDGER_ROUTER_CREATE2_SALT_V1, routerBytecode);
|
|
169
|
+
}
|
|
170
|
+
/** Ledger router v2 (`native_dex_ledger_router_bytecode_v2`) + documented salt. */
|
|
171
|
+
export function predictNativeDexLedgerRouterV2Create2Address(deployerHex, routerBytecodeV2) {
|
|
172
|
+
return predictCreate2ContractAddress(deployerHex, NATIVE_DEX_LEDGER_ROUTER_CREATE2_SALT_V2, routerBytecodeV2);
|
|
173
|
+
}
|
|
174
|
+
/** Ledger router v3 (`native_dex_ledger_router_bytecode_v3`) + documented salt. */
|
|
175
|
+
export function predictNativeDexLedgerRouterV3Create2Address(deployerHex, routerBytecodeV3) {
|
|
176
|
+
return predictCreate2ContractAddress(deployerHex, NATIVE_DEX_LEDGER_ROUTER_CREATE2_SALT_V3, routerBytecodeV3);
|
|
177
|
+
}
|
|
178
|
+
/** Multihop swap router (`native_dex_multihop_swap_router_bytecode`) + documented salt. */
|
|
179
|
+
export function predictNativeDexMultihopSwapRouterCreate2Address(deployerHex, routerBytecode) {
|
|
180
|
+
return predictCreate2ContractAddress(deployerHex, NATIVE_DEX_MULTIHOP_SWAP_ROUTER_CREATE2_SALT_V1, routerBytecode);
|
|
181
|
+
}
|
|
182
|
+
/** @deprecated Use {@link predictNativeDexMultihopSwapRouterCreate2Address}. */
|
|
183
|
+
export function predictNativeDexSwap2RouterCreate2Address(deployerHex, swap2RouterBytecode) {
|
|
184
|
+
return predictNativeDexMultihopSwapRouterCreate2Address(deployerHex, swap2RouterBytecode);
|
|
185
|
+
}
|
|
186
|
+
/** LP share token (`lp_share_token_bytecode`) + documented salt. */
|
|
187
|
+
export function predictNativeLpShareTokenCreate2Address(deployerHex, bytecode) {
|
|
188
|
+
return predictCreate2ContractAddress(deployerHex, NATIVE_LP_SHARE_TOKEN_CREATE2_SALT_V1, bytecode);
|
|
189
|
+
}
|
|
190
|
+
/** Native AMM LP vault (`native_amm_lp_vault_bytecode`) + documented salt. */
|
|
191
|
+
export function predictNativeAmmLpVaultCreate2Address(deployerHex, bytecode) {
|
|
192
|
+
return predictCreate2ContractAddress(deployerHex, NATIVE_AMM_LP_VAULT_CREATE2_SALT_V1, bytecode);
|
|
193
|
+
}
|
|
194
|
+
/** `0x` + 64 hex for {@link NATIVE_DEX_FACTORY_CREATE2_SALT_V1}. */
|
|
195
|
+
export function nativeDexFactoryCreate2SaltV1Hex() {
|
|
196
|
+
return validateHex32(bytesToHex(NATIVE_DEX_FACTORY_CREATE2_SALT_V1));
|
|
197
|
+
}
|
|
198
|
+
/** `0x` + 64 hex for {@link NATIVE_DEX_LEDGER_ROUTER_CREATE2_SALT_V1}. */
|
|
199
|
+
export function nativeDexLedgerRouterCreate2SaltV1Hex() {
|
|
200
|
+
return validateHex32(bytesToHex(NATIVE_DEX_LEDGER_ROUTER_CREATE2_SALT_V1));
|
|
201
|
+
}
|
|
202
|
+
/** `0x` + 64 hex for {@link NATIVE_DEX_LEDGER_ROUTER_CREATE2_SALT_V2}. */
|
|
203
|
+
export function nativeDexLedgerRouterCreate2SaltV2Hex() {
|
|
204
|
+
return validateHex32(bytesToHex(NATIVE_DEX_LEDGER_ROUTER_CREATE2_SALT_V2));
|
|
205
|
+
}
|
|
206
|
+
/** `0x` + 64 hex for {@link NATIVE_DEX_LEDGER_ROUTER_CREATE2_SALT_V3}. */
|
|
207
|
+
export function nativeDexLedgerRouterCreate2SaltV3Hex() {
|
|
208
|
+
return validateHex32(bytesToHex(NATIVE_DEX_LEDGER_ROUTER_CREATE2_SALT_V3));
|
|
209
|
+
}
|
|
210
|
+
/** `0x` + 64 hex for {@link NATIVE_DEX_MULTIHOP_SWAP_ROUTER_CREATE2_SALT_V1}. */
|
|
211
|
+
export function nativeDexMultihopSwapRouterCreate2SaltV1Hex() {
|
|
212
|
+
return validateHex32(bytesToHex(NATIVE_DEX_MULTIHOP_SWAP_ROUTER_CREATE2_SALT_V1));
|
|
213
|
+
}
|
|
214
|
+
/** @deprecated Alias for {@link nativeDexMultihopSwapRouterCreate2SaltV1Hex}. */
|
|
215
|
+
export function nativeDexSwap2RouterCreate2SaltV1Hex() {
|
|
216
|
+
return nativeDexMultihopSwapRouterCreate2SaltV1Hex();
|
|
217
|
+
}
|
|
218
|
+
/** `0x` + 64 hex for {@link NATIVE_LP_SHARE_TOKEN_CREATE2_SALT_V1}. */
|
|
219
|
+
export function nativeLpShareTokenCreate2SaltV1Hex() {
|
|
220
|
+
return validateHex32(bytesToHex(NATIVE_LP_SHARE_TOKEN_CREATE2_SALT_V1));
|
|
221
|
+
}
|
|
222
|
+
/** `0x` + 64 hex for {@link NATIVE_AMM_LP_VAULT_CREATE2_SALT_V1}. */
|
|
223
|
+
export function nativeAmmLpVaultCreate2SaltV1Hex() {
|
|
224
|
+
return validateHex32(bytesToHex(NATIVE_AMM_LP_VAULT_CREATE2_SALT_V1));
|
|
225
|
+
}
|
|
@@ -0,0 +1,100 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* dApp deploy helpers: QA preflight for **`contract_deploy_meta`** payloads (wizard “review” steps).
|
|
3
|
+
*
|
|
4
|
+
* See [BOING-CANONICAL-DEPLOY-ARTIFACTS.md](../../docs/BOING-CANONICAL-DEPLOY-ARTIFACTS.md),
|
|
5
|
+
* [BOING-DAPP-INTEGRATION.md](../../docs/BOING-DAPP-INTEGRATION.md).
|
|
6
|
+
*/
|
|
7
|
+
import type { BoingClient } from './client.js';
|
|
8
|
+
import type { BuildNativeConstantProductPoolDeployMetaTxInput, BuildReferenceFungibleDeployMetaTxInput, BuildReferenceFungibleSecuredDeployMetaTxInput, BuildReferenceNftCollectionDeployMetaTxInput, ContractDeployMetaTxObject } from './canonicalDeployArtifacts.js';
|
|
9
|
+
import type { QaCheckResponse, QaCheckResult } from './types.js';
|
|
10
|
+
/**
|
|
11
|
+
* When **`boing_qaCheck`** needs **`asset_name` / `asset_symbol`** but the wizard has no description
|
|
12
|
+
* commitment yet, the RPC allows a **placeholder** 32-byte hash ([RPC-API-SPEC.md](../../docs/RPC-API-SPEC.md) § **boing_qaCheck**).
|
|
13
|
+
*/
|
|
14
|
+
export declare const BOING_QA_PLACEHOLDER_DESCRIPTION_HASH_HEX: `0x${string}`;
|
|
15
|
+
/**
|
|
16
|
+
* Run **`boing_qaCheck`** using the same fields as a **`contract_deploy_meta`** tx object.
|
|
17
|
+
* Use on the **review** step of a deploy wizard so users see **allow / reject / unsure** before signing.
|
|
18
|
+
*/
|
|
19
|
+
export declare function preflightContractDeployMetaQa(client: BoingClient, tx: ContractDeployMetaTxObject): Promise<QaCheckResponse>;
|
|
20
|
+
/** UI hints for a **`boing_qaCheck`** result (toasts, banners, review step). */
|
|
21
|
+
export type DeployMetaQaUiOutcome = {
|
|
22
|
+
result: QaCheckResult;
|
|
23
|
+
/**
|
|
24
|
+
* Whether the primary action (“Sign” / “Deploy”) should stay enabled.
|
|
25
|
+
* For **`unsure`**, signing may still be valid (pool path); surface {@link DeployMetaQaUiOutcome.detail} first.
|
|
26
|
+
*/
|
|
27
|
+
readyToSign: boolean;
|
|
28
|
+
/** Short line for banners / toasts. */
|
|
29
|
+
headline: string;
|
|
30
|
+
/** Longer copy for modals or inline help. */
|
|
31
|
+
detail: string;
|
|
32
|
+
/** Suggested semantic tone for styling. */
|
|
33
|
+
tone: 'positive' | 'neutral' | 'warning' | 'destructive';
|
|
34
|
+
};
|
|
35
|
+
/**
|
|
36
|
+
* Map a **`boing_qaCheck`** response to user-facing copy (preflight or post-error messaging).
|
|
37
|
+
* Use with **`preflightContractDeployMetaQa`** on the review step, or after submit failures parsed as QA.
|
|
38
|
+
*/
|
|
39
|
+
export declare function describeContractDeployMetaQaResponse(qa: QaCheckResponse): DeployMetaQaUiOutcome;
|
|
40
|
+
export type PreflightContractDeployMetaWithUiResult = {
|
|
41
|
+
qa: QaCheckResponse;
|
|
42
|
+
ui: DeployMetaQaUiOutcome;
|
|
43
|
+
};
|
|
44
|
+
/**
|
|
45
|
+
* Run **`preflightContractDeployMetaQa`** and attach {@link describeContractDeployMetaQaResponse} for one-shot UI wiring.
|
|
46
|
+
*/
|
|
47
|
+
export declare function preflightContractDeployMetaWithUi(client: BoingClient, tx: ContractDeployMetaTxObject): Promise<PreflightContractDeployMetaWithUiResult>;
|
|
48
|
+
export type BuildAndPreflightReferenceFungibleResult = PreflightContractDeployMetaWithUiResult & {
|
|
49
|
+
tx: ContractDeployMetaTxObject;
|
|
50
|
+
};
|
|
51
|
+
/**
|
|
52
|
+
* **Wizard shortcut:** build pinned fungible **`contract_deploy_meta`** and run QA preflight with UI copy.
|
|
53
|
+
* Use the returned **`tx`** with **`boing_sendTransaction`** only when **`ui.readyToSign`** fits your product rules for **`unsure`**.
|
|
54
|
+
*/
|
|
55
|
+
export declare function buildAndPreflightReferenceFungibleDeploy(client: BoingClient, input: BuildReferenceFungibleDeployMetaTxInput): Promise<BuildAndPreflightReferenceFungibleResult>;
|
|
56
|
+
export type BuildAndPreflightReferenceNftCollectionResult = PreflightContractDeployMetaWithUiResult & {
|
|
57
|
+
tx: ContractDeployMetaTxObject;
|
|
58
|
+
};
|
|
59
|
+
/**
|
|
60
|
+
* Same as {@link buildAndPreflightReferenceFungibleDeploy} for the reference NFT collection template.
|
|
61
|
+
*/
|
|
62
|
+
export declare function buildAndPreflightReferenceNftCollectionDeployMeta(client: BoingClient, input: BuildReferenceNftCollectionDeployMetaTxInput): Promise<BuildAndPreflightReferenceNftCollectionResult>;
|
|
63
|
+
/** Which Boing deploy wizard / integration path is in use (drives bytecode + default `purpose_category`). */
|
|
64
|
+
export type BoingDeployIntegrationKind = 'token' | 'nft' | 'liquidity_pool';
|
|
65
|
+
/**
|
|
66
|
+
* Single input shape for dApps: pick **`kind`** and the fields for that path; QA preflight uses the
|
|
67
|
+
* resulting **`contract_deploy_meta`** automatically (placeholder `description_hash` when omitted).
|
|
68
|
+
*/
|
|
69
|
+
export type BoingIntegrationDeployInput = ({
|
|
70
|
+
kind: 'token';
|
|
71
|
+
} & BuildReferenceFungibleSecuredDeployMetaTxInput) | ({
|
|
72
|
+
kind: 'nft';
|
|
73
|
+
} & BuildReferenceNftCollectionDeployMetaTxInput) | ({
|
|
74
|
+
kind: 'liquidity_pool';
|
|
75
|
+
} & BuildNativeConstantProductPoolDeployMetaTxInput);
|
|
76
|
+
/** Default mempool QA **`purpose_category`** per integration kind (pool → **`dapp`** per native AMM docs). */
|
|
77
|
+
export declare function defaultPurposeCategoryForBoingDeployKind(kind: BoingDeployIntegrationKind): string;
|
|
78
|
+
/**
|
|
79
|
+
* Build **`contract_deploy_meta`** for token, NFT collection, or native CP pool — correct bytecode
|
|
80
|
+
* resolution and **`purpose_category`** for each **`kind`**.
|
|
81
|
+
*/
|
|
82
|
+
export declare function buildBoingIntegrationDeployMetaTx(input: BoingIntegrationDeployInput): ContractDeployMetaTxObject;
|
|
83
|
+
export type PreflightBoingIntegrationDeployResult = PreflightContractDeployMetaWithUiResult & {
|
|
84
|
+
tx: ContractDeployMetaTxObject;
|
|
85
|
+
};
|
|
86
|
+
/**
|
|
87
|
+
* **One call:** build the meta tx for the chosen **`kind`**, run **`boing_qaCheck`**, return **`{ tx, qa, ui }`**
|
|
88
|
+
* (same as {@link preflightContractDeployMetaWithUi} plus the signed-ready payload).
|
|
89
|
+
*/
|
|
90
|
+
export declare function preflightBoingIntegrationDeploy(client: BoingClient, input: BoingIntegrationDeployInput): Promise<PreflightBoingIntegrationDeployResult>;
|
|
91
|
+
/** Alias of {@link preflightBoingIntegrationDeploy} — same “build + QA UI” one-shot naming as token/NFT helpers. */
|
|
92
|
+
export declare const buildAndPreflightBoingIntegrationDeploy: typeof preflightBoingIntegrationDeploy;
|
|
93
|
+
export type BuildAndPreflightNativeConstantProductPoolResult = PreflightContractDeployMetaWithUiResult & {
|
|
94
|
+
tx: ContractDeployMetaTxObject;
|
|
95
|
+
};
|
|
96
|
+
/**
|
|
97
|
+
* **Wizard shortcut** for native CP pool: build meta tx (default **`purpose_category: dapp`**) + QA preflight.
|
|
98
|
+
*/
|
|
99
|
+
export declare function buildAndPreflightNativeConstantProductPoolDeploy(client: BoingClient, input: BuildNativeConstantProductPoolDeployMetaTxInput): Promise<BuildAndPreflightNativeConstantProductPoolResult>;
|
|
100
|
+
//# sourceMappingURL=dappDeploy.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"dappDeploy.d.ts","sourceRoot":"","sources":["../src/dappDeploy.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAEH,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,aAAa,CAAC;AAC/C,OAAO,KAAK,EACV,+CAA+C,EAC/C,uCAAuC,EACvC,8CAA8C,EAC9C,4CAA4C,EAC5C,0BAA0B,EAC3B,MAAM,+BAA+B,CAAC;AAOvC,OAAO,KAAK,EAAE,eAAe,EAAE,aAAa,EAAE,MAAM,YAAY,CAAC;AAEjE;;;GAGG;AACH,eAAO,MAAM,yCAAyC,eAAkC,CAAC;AAEzF;;;GAGG;AACH,wBAAsB,6BAA6B,CACjD,MAAM,EAAE,WAAW,EACnB,EAAE,EAAE,0BAA0B,GAC7B,OAAO,CAAC,eAAe,CAAC,CAY1B;AAED,gFAAgF;AAChF,MAAM,MAAM,qBAAqB,GAAG;IAClC,MAAM,EAAE,aAAa,CAAC;IACtB;;;OAGG;IACH,WAAW,EAAE,OAAO,CAAC;IACrB,uCAAuC;IACvC,QAAQ,EAAE,MAAM,CAAC;IACjB,6CAA6C;IAC7C,MAAM,EAAE,MAAM,CAAC;IACf,2CAA2C;IAC3C,IAAI,EAAE,UAAU,GAAG,SAAS,GAAG,SAAS,GAAG,aAAa,CAAC;CAC1D,CAAC;AAEF;;;GAGG;AACH,wBAAgB,oCAAoC,CAAC,EAAE,EAAE,eAAe,GAAG,qBAAqB,CAuC/F;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