@steerprotocol/sdk 3.3.1 → 3.4.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/README.md +11 -3
- package/dist/index.browser.mjs +4001 -80
- package/dist/index.browser.mjs.map +1 -1
- package/dist/index.cjs +4088 -78
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.mts +1679 -20
- package/dist/index.d.mts.map +1 -1
- package/dist/index.mjs +4001 -80
- package/dist/index.mjs.map +1 -1
- package/package.json +2 -1
package/dist/index.d.mts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import * as _$viem from "viem";
|
|
2
|
-
import { Address, Client, Hash, Hex, PublicClient, TestClient, WalletClient } from "viem";
|
|
2
|
+
import { Address, Client, Hash, Hex, PublicClient, TestClient, TransactionReceipt, WalletClient } from "viem";
|
|
3
3
|
import { Campaign, createClient } from "@steerprotocol/api-sdk";
|
|
4
4
|
import { Pool } from "@uniswap/v3-sdk";
|
|
5
5
|
import { Decimal } from "decimal.js";
|
|
@@ -8873,15 +8873,199 @@ interface TokensFromLpResponse {
|
|
|
8873
8873
|
token1Val: bigint;
|
|
8874
8874
|
}
|
|
8875
8875
|
//#endregion
|
|
8876
|
+
//#region src/pool-lifecycle/capabilities/v4.d.ts
|
|
8877
|
+
interface V4LifecycleDeploymentProvenance {
|
|
8878
|
+
readonly source: 'sdk-config' | 'official-deployment' | 'verified-explorer';
|
|
8879
|
+
readonly urls: readonly `https://${string}`[];
|
|
8880
|
+
}
|
|
8881
|
+
type V4LifecycleDeploymentId = `uniswap-v4:${number}:${Protocol.UniswapV4}:${Lowercase<Address>}:${Lowercase<Address>}:pool-manager-initialize-v1:v1`;
|
|
8882
|
+
type V4LifecycleDeploymentByIdRegistry = Readonly<Partial<Record<string, V4LifecycleDeployment>>>;
|
|
8883
|
+
/** A PoolManager/StateView pair explicitly approved for lifecycle writes. */
|
|
8884
|
+
interface V4LifecycleDeployment {
|
|
8885
|
+
readonly supported: true;
|
|
8886
|
+
readonly schemaVersion: 1;
|
|
8887
|
+
readonly deploymentId: V4LifecycleDeploymentId;
|
|
8888
|
+
readonly chainId: number;
|
|
8889
|
+
readonly protocol: Protocol.UniswapV4;
|
|
8890
|
+
readonly family: 'uniswap-v4';
|
|
8891
|
+
readonly adapter: 'pool-manager-initialize-v1';
|
|
8892
|
+
readonly version: 1;
|
|
8893
|
+
readonly poolManager: Address;
|
|
8894
|
+
readonly stateView: Address;
|
|
8895
|
+
readonly provenance: V4LifecycleDeploymentProvenance;
|
|
8896
|
+
/** Earliest PoolManager event block from the official V4 subgraph manifest. */
|
|
8897
|
+
readonly startBlock: bigint;
|
|
8898
|
+
}
|
|
8899
|
+
interface ResolveV4LifecycleDeploymentParams {
|
|
8900
|
+
readonly chainId: number;
|
|
8901
|
+
readonly protocol: SupportedProtocol;
|
|
8902
|
+
}
|
|
8903
|
+
declare function getV4LifecycleDeploymentId(params: {
|
|
8904
|
+
readonly chainId: number;
|
|
8905
|
+
readonly protocol: Protocol.UniswapV4;
|
|
8906
|
+
readonly poolManager: Address;
|
|
8907
|
+
readonly stateView: Address;
|
|
8908
|
+
readonly adapter: 'pool-manager-initialize-v1';
|
|
8909
|
+
readonly version: 1;
|
|
8910
|
+
}): V4LifecycleDeploymentId;
|
|
8911
|
+
/**
|
|
8912
|
+
* Explicit lifecycle-write registry. Entries are not inferred from discovery
|
|
8913
|
+
* configuration so a newly discovered deployment remains unsupported until it
|
|
8914
|
+
* is deliberately reviewed and versioned here.
|
|
8915
|
+
*/
|
|
8916
|
+
declare const CURRENT_V4_LIFECYCLE_DEPLOYMENTS: readonly V4LifecycleDeployment[];
|
|
8917
|
+
/**
|
|
8918
|
+
* Every approved V4 deployment, including historical managers. When a current
|
|
8919
|
+
* deployment changes, retain the former entry here so existing plans remain
|
|
8920
|
+
* independently resolvable by deploymentId.
|
|
8921
|
+
*/
|
|
8922
|
+
declare const V4_LIFECYCLE_DEPLOYMENTS: readonly V4LifecycleDeployment[];
|
|
8923
|
+
declare const V4_LIFECYCLE_DEPLOYMENTS_BY_ID: V4LifecycleDeploymentByIdRegistry;
|
|
8924
|
+
/** Resolve the explicitly selected current-default deployment for a chain/protocol pair. */
|
|
8925
|
+
declare function resolveCurrentV4LifecycleDeployment(params: ResolveV4LifecycleDeploymentParams): V4LifecycleDeployment | undefined;
|
|
8926
|
+
/** Backwards-compatible alias; prefer the name that makes current-default semantics explicit. */
|
|
8927
|
+
declare const resolveV4LifecycleDeployment: typeof resolveCurrentV4LifecycleDeployment;
|
|
8928
|
+
/** Resolve an exact current or historical deployment without consulting defaults. */
|
|
8929
|
+
declare function resolveV4LifecycleDeploymentById(deploymentId: string): V4LifecycleDeployment | undefined;
|
|
8930
|
+
/**
|
|
8931
|
+
* Validate capability metadata supplied across a UI/CLI boundary and return
|
|
8932
|
+
* the canonical frozen registry entry.
|
|
8933
|
+
*/
|
|
8934
|
+
declare function validateV4LifecycleDeployment(value: unknown): V4LifecycleDeployment;
|
|
8935
|
+
//#endregion
|
|
8936
|
+
//#region src/pool-lifecycle/types.d.ts
|
|
8937
|
+
/** A signer-neutral EVM transaction that can be consumed by a UI or CLI. */
|
|
8938
|
+
interface EncodedEvmTransaction {
|
|
8939
|
+
readonly chainId: number;
|
|
8940
|
+
readonly to: Address;
|
|
8941
|
+
readonly data: Hex;
|
|
8942
|
+
readonly value: bigint;
|
|
8943
|
+
}
|
|
8944
|
+
/** Common envelope around a protocol-specific pool lifecycle action. */
|
|
8945
|
+
interface PreparedPoolAction<Kind extends string, Identity, Expected, Preflight> {
|
|
8946
|
+
readonly schemaVersion: 1;
|
|
8947
|
+
readonly kind: Kind;
|
|
8948
|
+
readonly protocol: SupportedProtocol;
|
|
8949
|
+
readonly transaction: EncodedEvmTransaction;
|
|
8950
|
+
readonly identity: Identity;
|
|
8951
|
+
readonly expected: Expected;
|
|
8952
|
+
readonly preflight: Preflight;
|
|
8953
|
+
}
|
|
8954
|
+
interface PoolActionSimulation {
|
|
8955
|
+
readonly transaction: EncodedEvmTransaction;
|
|
8956
|
+
readonly blockNumber: bigint;
|
|
8957
|
+
readonly returnData: Hex | null;
|
|
8958
|
+
readonly gasEstimate: bigint;
|
|
8959
|
+
}
|
|
8960
|
+
type PoolActionOutcome = 'created' | 'created-and-initialized' | 'initialized-existing' | 'already-initialized-matching' | 'already-initialized-different-price' | 'initialized-then-price-moved' | 'not-initialized' | 'wrong-deployment' | 'verification-unavailable' | 'reverted';
|
|
8961
|
+
interface PoolActionVerification<Identity, State, Evidence> {
|
|
8962
|
+
readonly verified: boolean;
|
|
8963
|
+
readonly outcome: PoolActionOutcome;
|
|
8964
|
+
readonly blockNumber: bigint;
|
|
8965
|
+
readonly identity: Identity;
|
|
8966
|
+
readonly state: State | null;
|
|
8967
|
+
readonly evidence: Evidence;
|
|
8968
|
+
readonly warnings: readonly string[];
|
|
8969
|
+
}
|
|
8970
|
+
declare const PREPARED_POOL_ACTION_SERIALIZATION_VERSION: 1;
|
|
8971
|
+
type AnyPreparedPoolAction = PreparedPoolAction<string, unknown, unknown, unknown>;
|
|
8972
|
+
/**
|
|
8973
|
+
* Serialize a prepared action in a versioned JSON envelope. Bigints use an
|
|
8974
|
+
* explicit tag so ordinary decimal strings remain distinguishable on decode.
|
|
8975
|
+
*/
|
|
8976
|
+
declare function serializePreparedPoolAction(action: AnyPreparedPoolAction, space?: number): string;
|
|
8977
|
+
/** Parse a versioned serialized action; protocol adapters must validate its shape. */
|
|
8978
|
+
declare function deserializePreparedPoolAction(serialized: string): unknown;
|
|
8979
|
+
//#endregion
|
|
8980
|
+
//#region src/pool-lifecycle/v4/types.d.ts
|
|
8981
|
+
interface V4PoolKeyInput {
|
|
8982
|
+
readonly currencyA: Address;
|
|
8983
|
+
readonly currencyB: Address;
|
|
8984
|
+
readonly fee: number;
|
|
8985
|
+
readonly tickSpacing: number;
|
|
8986
|
+
readonly hooks: Address;
|
|
8987
|
+
}
|
|
8988
|
+
interface V4PoolKey {
|
|
8989
|
+
readonly currency0: Address;
|
|
8990
|
+
readonly currency1: Address;
|
|
8991
|
+
readonly fee: number;
|
|
8992
|
+
readonly tickSpacing: number;
|
|
8993
|
+
readonly hooks: Address;
|
|
8994
|
+
}
|
|
8995
|
+
/** A Q64.96 price explicitly bound to the canonical V4 currency order. */
|
|
8996
|
+
interface V4InitialPrice {
|
|
8997
|
+
readonly currency0: Address;
|
|
8998
|
+
readonly currency1: Address;
|
|
8999
|
+
readonly sqrtPriceX96: bigint;
|
|
9000
|
+
}
|
|
9001
|
+
interface V4PoolSnapshotBase {
|
|
9002
|
+
readonly schemaVersion: 1;
|
|
9003
|
+
readonly blockNumber: bigint;
|
|
9004
|
+
readonly deployment: V4LifecycleDeployment;
|
|
9005
|
+
readonly key: V4PoolKey;
|
|
9006
|
+
readonly poolId: Hex;
|
|
9007
|
+
readonly tick: number;
|
|
9008
|
+
readonly protocolFee: number;
|
|
9009
|
+
readonly lpFee: number;
|
|
9010
|
+
}
|
|
9011
|
+
interface V4UninitializedPoolSnapshot extends V4PoolSnapshotBase {
|
|
9012
|
+
readonly status: 'uninitialized';
|
|
9013
|
+
readonly sqrtPriceX96: 0n;
|
|
9014
|
+
readonly tick: 0;
|
|
9015
|
+
readonly protocolFee: 0;
|
|
9016
|
+
readonly lpFee: 0;
|
|
9017
|
+
}
|
|
9018
|
+
interface V4InitializedPoolSnapshot extends V4PoolSnapshotBase {
|
|
9019
|
+
readonly status: 'initialized';
|
|
9020
|
+
readonly sqrtPriceX96: bigint;
|
|
9021
|
+
}
|
|
9022
|
+
type V4PoolSnapshot = V4UninitializedPoolSnapshot | V4InitializedPoolSnapshot;
|
|
9023
|
+
interface V4PoolIdentity {
|
|
9024
|
+
readonly family: 'uniswap-v4';
|
|
9025
|
+
readonly adapter: 'pool-manager-initialize-v1';
|
|
9026
|
+
readonly version: 1;
|
|
9027
|
+
readonly deploymentId: V4LifecycleDeployment['deploymentId'];
|
|
9028
|
+
readonly chainId: number;
|
|
9029
|
+
readonly poolManager: Address;
|
|
9030
|
+
readonly stateView: Address;
|
|
9031
|
+
readonly poolId: Hex;
|
|
9032
|
+
readonly key: V4PoolKey;
|
|
9033
|
+
}
|
|
9034
|
+
interface V4InitializeExpectation extends V4InitialPrice {}
|
|
9035
|
+
interface V4UninitializedPreflightSummary {
|
|
9036
|
+
readonly blockNumber: bigint;
|
|
9037
|
+
readonly deploymentId: V4LifecycleDeployment['deploymentId'];
|
|
9038
|
+
readonly status: 'uninitialized';
|
|
9039
|
+
readonly poolId: Hex;
|
|
9040
|
+
readonly sqrtPriceX96: 0n;
|
|
9041
|
+
}
|
|
9042
|
+
type PreparedV4InitializePoolAction = PreparedPoolAction<'v4-initialize', V4PoolIdentity, V4InitializeExpectation, V4UninitializedPreflightSummary> & {
|
|
9043
|
+
readonly preflight: V4UninitializedPreflightSummary;
|
|
9044
|
+
};
|
|
9045
|
+
type PreparedV4PoolAction = PreparedV4InitializePoolAction;
|
|
9046
|
+
interface V4PoolActionSimulation extends PoolActionSimulation {
|
|
9047
|
+
readonly returnedTick: number;
|
|
9048
|
+
}
|
|
9049
|
+
interface V4InitializeEvidence {
|
|
9050
|
+
readonly poolId: Hex;
|
|
9051
|
+
readonly currency0: Address;
|
|
9052
|
+
readonly currency1: Address;
|
|
9053
|
+
readonly fee: number;
|
|
9054
|
+
readonly tickSpacing: number;
|
|
9055
|
+
readonly hooks: Address;
|
|
9056
|
+
readonly sqrtPriceX96: bigint;
|
|
9057
|
+
readonly tick: number;
|
|
9058
|
+
readonly logIndex: number;
|
|
9059
|
+
}
|
|
9060
|
+
interface V4ReceiptEvidence {
|
|
9061
|
+
readonly receiptStatus: 'success' | 'reverted';
|
|
9062
|
+
readonly initializations: readonly V4InitializeEvidence[];
|
|
9063
|
+
}
|
|
9064
|
+
type V4PoolActionVerification = PoolActionVerification<V4PoolIdentity, V4PoolSnapshot, V4ReceiptEvidence>;
|
|
9065
|
+
//#endregion
|
|
8876
9066
|
//#region src/base/vault/execution-context.d.ts
|
|
8877
9067
|
type VaultExecutionPoolFamily = 'uniswap-v3-compatible' | 'algebra' | 'algebra-integral' | 'algebra-directional' | 'aerodrome-cl' | 'uniswap-v4';
|
|
8878
|
-
|
|
8879
|
-
currency0: Address;
|
|
8880
|
-
currency1: Address;
|
|
8881
|
-
fee: number;
|
|
8882
|
-
tickSpacing: number;
|
|
8883
|
-
hooks: Address;
|
|
8884
|
-
}
|
|
9068
|
+
type VaultExecutionPoolKey = V4PoolKey;
|
|
8885
9069
|
interface GetVaultExecutionContextParams {
|
|
8886
9070
|
publicClient: PublicClient;
|
|
8887
9071
|
vaultAddress: Address;
|
|
@@ -10180,19 +10364,19 @@ interface PoolFilter$1 {
|
|
|
10180
10364
|
*
|
|
10181
10365
|
* @example
|
|
10182
10366
|
* ```typescript
|
|
10183
|
-
* import { createPublicClient,
|
|
10367
|
+
* import { createPublicClient, http } from 'viem';
|
|
10184
10368
|
* import { mainnet } from 'viem/chains';
|
|
10185
10369
|
* import { PoolClient } from '@steerprotocol/sdk';
|
|
10186
10370
|
*
|
|
10187
10371
|
* const client = createPublicClient({
|
|
10188
10372
|
* chain: mainnet,
|
|
10189
10373
|
* transport: http()
|
|
10190
|
-
* })
|
|
10374
|
+
* });
|
|
10191
10375
|
*
|
|
10192
10376
|
* const poolClient = new PoolClient(client, 'your-subgraph-studio-key');
|
|
10193
10377
|
*
|
|
10194
10378
|
* // Fetch top pools
|
|
10195
|
-
* const topPools = await poolClient.getTopPools(100, Protocol.
|
|
10379
|
+
* const topPools = await poolClient.getTopPools(100, Protocol.Uniswap, 1);
|
|
10196
10380
|
* ```
|
|
10197
10381
|
*
|
|
10198
10382
|
* @extends SubgraphClient
|
|
@@ -10210,7 +10394,7 @@ declare class PoolClient extends SubgraphClient {
|
|
|
10210
10394
|
/**
|
|
10211
10395
|
* Creates a new PoolClient instance
|
|
10212
10396
|
*
|
|
10213
|
-
* @param client -
|
|
10397
|
+
* @param client - Public client for read-only blockchain interactions
|
|
10214
10398
|
* @param subgraphStudioKey - Optional Subgraph Studio API key for higher rate limits
|
|
10215
10399
|
*
|
|
10216
10400
|
* @example
|
|
@@ -10218,7 +10402,7 @@ declare class PoolClient extends SubgraphClient {
|
|
|
10218
10402
|
* const poolClient = new PoolClient(client, 'your-api-key');
|
|
10219
10403
|
* ```
|
|
10220
10404
|
*/
|
|
10221
|
-
constructor(client: PublicClient
|
|
10405
|
+
constructor(client: PublicClient, subgraphStudioKey?: string);
|
|
10222
10406
|
/**
|
|
10223
10407
|
* Resets the API call counter for metrics tracking
|
|
10224
10408
|
*
|
|
@@ -10275,7 +10459,7 @@ declare class PoolClient extends SubgraphClient {
|
|
|
10275
10459
|
* @example
|
|
10276
10460
|
* ```typescript
|
|
10277
10461
|
* // Get top 100 Uniswap V3 pools on Ethereum
|
|
10278
|
-
* const topPools = await poolClient.getTopPools(100, Protocol.
|
|
10462
|
+
* const topPools = await poolClient.getTopPools(100, Protocol.Uniswap, 1);
|
|
10279
10463
|
* if (topPools.success) {
|
|
10280
10464
|
* console.log(`Found ${topPools.data.length} pools`);
|
|
10281
10465
|
* }
|
|
@@ -10297,7 +10481,7 @@ declare class PoolClient extends SubgraphClient {
|
|
|
10297
10481
|
* // Get specific pool details
|
|
10298
10482
|
* const poolDetails = await poolClient.getPoolById(
|
|
10299
10483
|
* '0x88e6a0c2ddd26feeb64f039a2c41296fcb3f5640',
|
|
10300
|
-
* Protocol.
|
|
10484
|
+
* Protocol.Uniswap,
|
|
10301
10485
|
* 1
|
|
10302
10486
|
* );
|
|
10303
10487
|
* if (poolDetails.success && poolDetails.data) {
|
|
@@ -10326,7 +10510,7 @@ declare class PoolClient extends SubgraphClient {
|
|
|
10326
10510
|
* ];
|
|
10327
10511
|
* const pools = await poolClient.fetchPoolsForTokensBatch(
|
|
10328
10512
|
* tokenAddresses,
|
|
10329
|
-
* Protocol.
|
|
10513
|
+
* Protocol.Uniswap,
|
|
10330
10514
|
* 1,
|
|
10331
10515
|
* 5
|
|
10332
10516
|
* );
|
|
@@ -10348,7 +10532,7 @@ declare class PoolClient extends SubgraphClient {
|
|
|
10348
10532
|
* // Get all USDC pools on Uniswap V3
|
|
10349
10533
|
* const usdcPools = await poolClient.fetchPoolsForToken(
|
|
10350
10534
|
* '0xa0b86a33e6f8b07b71c3a39ef77a6b6e8f1b7b7e',
|
|
10351
|
-
* Protocol.
|
|
10535
|
+
* Protocol.Uniswap,
|
|
10352
10536
|
* 1
|
|
10353
10537
|
* );
|
|
10354
10538
|
* if (usdcPools.success) {
|
|
@@ -10661,8 +10845,8 @@ declare class StakingClient extends SubgraphClient {
|
|
|
10661
10845
|
* const summary = await steerClient.rewards.getRewardSummary(userAddress, chainId);
|
|
10662
10846
|
*
|
|
10663
10847
|
* // Use pool data functionality
|
|
10664
|
-
* const topPools = await steerClient.pools.getTopPools(100, Protocol.
|
|
10665
|
-
* const poolDetails = await steerClient.pools.getPoolById(poolId, Protocol.
|
|
10848
|
+
* const topPools = await steerClient.pools.getTopPools(100, Protocol.Uniswap, 1);
|
|
10849
|
+
* const poolDetails = await steerClient.pools.getPoolById(poolId, Protocol.Uniswap, 1);
|
|
10666
10850
|
*
|
|
10667
10851
|
* // Use staking functionality
|
|
10668
10852
|
* const stakingPools = await steerClient.staking.getStakingPools(1);
|
|
@@ -10762,5 +10946,1480 @@ declare class FeeManagerClient extends SubgraphClient {
|
|
|
10762
10946
|
}[]>>;
|
|
10763
10947
|
}
|
|
10764
10948
|
//#endregion
|
|
10765
|
-
|
|
10949
|
+
//#region src/pool-lifecycle/errors.d.ts
|
|
10950
|
+
type PoolLifecycleErrorCode = 'INVALID_INPUT' | 'UNSUPPORTED_DEPLOYMENT' | 'CHAIN_MISMATCH' | 'CONTRACT_NOT_DEPLOYED' | 'DEPLOYMENT_MISMATCH' | 'DISABLED_FEE' | 'POOL_STATE_MISMATCH' | 'SIMULATION_FAILED';
|
|
10951
|
+
/** Error thrown when a pool lifecycle primitive cannot safely continue. */
|
|
10952
|
+
declare class PoolLifecycleError extends Error {
|
|
10953
|
+
readonly code: PoolLifecycleErrorCode;
|
|
10954
|
+
readonly causeValue?: unknown;
|
|
10955
|
+
constructor(code: PoolLifecycleErrorCode, message: string, causeValue?: unknown);
|
|
10956
|
+
}
|
|
10957
|
+
//#endregion
|
|
10958
|
+
//#region src/pool-lifecycle/math.d.ts
|
|
10959
|
+
/** The smallest sqrt price accepted by Uniswap TickMath, inclusive. */
|
|
10960
|
+
declare const MIN_SQRT_RATIO = 4295128739n;
|
|
10961
|
+
/** The largest TickMath sqrt-price boundary, which is not itself valid. */
|
|
10962
|
+
declare const MAX_SQRT_RATIO = 1461446703485210103287273052203988822378723970342n;
|
|
10963
|
+
/**
|
|
10964
|
+
* An exact fraction representation. {@link parseExactDecimal} returns a
|
|
10965
|
+
* reduced, non-negative value; initial-price inputs must also be positive.
|
|
10966
|
+
*/
|
|
10967
|
+
interface ExactFraction {
|
|
10968
|
+
readonly numerator: bigint;
|
|
10969
|
+
readonly denominator: bigint;
|
|
10970
|
+
}
|
|
10971
|
+
/**
|
|
10972
|
+
* A human-unit price expressed as quote-token units per one base-token unit.
|
|
10973
|
+
*
|
|
10974
|
+
* For example, a value of 2_500 / 1 means 2,500 quote tokens per base token.
|
|
10975
|
+
* Token decimals are applied exactly by {@link encodeInitialSqrtPriceX96}; a
|
|
10976
|
+
* JavaScript floating-point number is deliberately not part of this type.
|
|
10977
|
+
*/
|
|
10978
|
+
interface ExactPrice {
|
|
10979
|
+
readonly baseToken: string;
|
|
10980
|
+
readonly quoteToken: string;
|
|
10981
|
+
readonly baseTokenDecimals: number;
|
|
10982
|
+
readonly quoteTokenDecimals: number;
|
|
10983
|
+
readonly quotePerBase: ExactFraction;
|
|
10984
|
+
}
|
|
10985
|
+
/**
|
|
10986
|
+
* A human-unit price for an EVM currency pair. Unlike {@link ExactPrice}, the
|
|
10987
|
+
* zero address is accepted and represents the native currency used by
|
|
10988
|
+
* Uniswap V4. Callers are responsible for supplying 18 decimals for the
|
|
10989
|
+
* native currency on EVM chains.
|
|
10990
|
+
*/
|
|
10991
|
+
interface ExactCurrencyPrice {
|
|
10992
|
+
readonly baseCurrency: string;
|
|
10993
|
+
readonly quoteCurrency: string;
|
|
10994
|
+
readonly baseCurrencyDecimals: number;
|
|
10995
|
+
readonly quoteCurrencyDecimals: number;
|
|
10996
|
+
readonly quotePerBase: ExactFraction;
|
|
10997
|
+
}
|
|
10998
|
+
/** A validated, checksummed ERC20 pair in canonical address order. */
|
|
10999
|
+
interface CanonicalErc20Pair {
|
|
11000
|
+
readonly token0: Address;
|
|
11001
|
+
readonly token1: Address;
|
|
11002
|
+
}
|
|
11003
|
+
/** A canonical EVM currency pair; currency0 may be the native zero address. */
|
|
11004
|
+
interface CanonicalCurrencyPair {
|
|
11005
|
+
readonly currency0: Address;
|
|
11006
|
+
readonly currency1: Address;
|
|
11007
|
+
}
|
|
11008
|
+
/**
|
|
11009
|
+
* The canonical raw-token ratio and its TickMath-compatible Q64.96 encoding.
|
|
11010
|
+
*/
|
|
11011
|
+
interface CanonicalInitialPrice extends CanonicalErc20Pair {
|
|
11012
|
+
readonly amount0Raw: bigint;
|
|
11013
|
+
readonly amount1Raw: bigint;
|
|
11014
|
+
readonly sqrtPriceX96: bigint;
|
|
11015
|
+
readonly baseTokenIsToken0: boolean;
|
|
11016
|
+
}
|
|
11017
|
+
/** A canonical raw-currency ratio and its Q64.96 initialization price. */
|
|
11018
|
+
interface CanonicalCurrencyInitialPrice extends CanonicalCurrencyPair {
|
|
11019
|
+
readonly amount0Raw: bigint;
|
|
11020
|
+
readonly amount1Raw: bigint;
|
|
11021
|
+
readonly sqrtPriceX96: bigint;
|
|
11022
|
+
readonly baseCurrencyIsCurrency0: boolean;
|
|
11023
|
+
}
|
|
11024
|
+
/**
|
|
11025
|
+
* Parses an unsigned, fixed-point decimal string without converting through a
|
|
11026
|
+
* JavaScript number. Signs, exponent notation, whitespace, and omitted whole
|
|
11027
|
+
* or fractional digits are rejected. The returned fraction is reduced.
|
|
11028
|
+
*/
|
|
11029
|
+
declare function parseExactDecimal(value: string): ExactFraction;
|
|
11030
|
+
/**
|
|
11031
|
+
* Validates, checksums, and sorts two distinct non-zero ERC20 addresses.
|
|
11032
|
+
*/
|
|
11033
|
+
declare function sortErc20Pair(tokenA: string, tokenB: string): CanonicalErc20Pair;
|
|
11034
|
+
/**
|
|
11035
|
+
* Validates, checksums, and sorts two distinct EVM currencies. The zero
|
|
11036
|
+
* address is allowed and, when present, necessarily sorts as currency0.
|
|
11037
|
+
*/
|
|
11038
|
+
declare function sortEvmCurrencyPair(currencyA: string, currencyB: string): CanonicalCurrencyPair;
|
|
11039
|
+
/**
|
|
11040
|
+
* Returns floor(sqrt(value)) using bigint arithmetic only.
|
|
11041
|
+
*/
|
|
11042
|
+
declare function integerSqrt(value: bigint): bigint;
|
|
11043
|
+
/**
|
|
11044
|
+
* Enforces the Uniswap TickMath interval: MIN is inclusive and MAX exclusive.
|
|
11045
|
+
* Returns the input so it can be composed with transaction builders.
|
|
11046
|
+
*/
|
|
11047
|
+
declare function validateSqrtPriceX96(sqrtPriceX96: bigint): bigint;
|
|
11048
|
+
/**
|
|
11049
|
+
* Encode an exact raw token1/token0 amount ratio without token metadata.
|
|
11050
|
+
* The result matches the canonical V3 floor-rounding operation.
|
|
11051
|
+
*/
|
|
11052
|
+
declare function encodeSqrtRatioX96(amount1Raw: bigint, amount0Raw: bigint): bigint;
|
|
11053
|
+
/**
|
|
11054
|
+
* Converts an exact quote-per-base human price into the canonical raw-token
|
|
11055
|
+
* ratio and sqrtPriceX96 expected by concentrated-liquidity initializers.
|
|
11056
|
+
*
|
|
11057
|
+
* Address sorting and reciprocal orientation happen before the only lossy
|
|
11058
|
+
* operation. The final encoding is exactly:
|
|
11059
|
+
*
|
|
11060
|
+
* floor(sqrt((amount1Raw << 192) / amount0Raw))
|
|
11061
|
+
*/
|
|
11062
|
+
declare function encodeInitialSqrtPriceX96(price: ExactPrice): CanonicalInitialPrice;
|
|
11063
|
+
/**
|
|
11064
|
+
* Currency-aware counterpart to {@link encodeInitialSqrtPriceX96}. It keeps
|
|
11065
|
+
* the same exact orientation and floor-rounding rules while permitting the
|
|
11066
|
+
* native zero-address currency required by Uniswap V4.
|
|
11067
|
+
*/
|
|
11068
|
+
declare function encodeCurrencyInitialSqrtPriceX96(price: ExactCurrencyPrice): CanonicalCurrencyInitialPrice;
|
|
11069
|
+
//#endregion
|
|
11070
|
+
//#region src/pool-lifecycle/capabilities/algebra.d.ts
|
|
11071
|
+
type AlgebraLifecycleVariant = 'legacy' | 'directional' | 'integral-v1' | 'integral-v2';
|
|
11072
|
+
type AlgebraLifecycleAdapter = 'algebra-legacy-pair-v1' | 'algebra-directional-pair-v1' | 'algebra-integral-pair-v1' | 'algebra-integral-plugin-data-v2';
|
|
11073
|
+
interface AlgebraLifecycleProvenance {
|
|
11074
|
+
readonly source: 'sdk-config' | 'official-deployment' | 'verified-explorer';
|
|
11075
|
+
readonly urls: readonly [`https://${string}`, ...`https://${string}`[]];
|
|
11076
|
+
}
|
|
11077
|
+
interface AlgebraLifecycleDeployment {
|
|
11078
|
+
readonly supported: true;
|
|
11079
|
+
readonly schemaVersion: 1;
|
|
11080
|
+
readonly chainId: number;
|
|
11081
|
+
readonly protocol: SupportedProtocol;
|
|
11082
|
+
readonly family: 'algebra';
|
|
11083
|
+
readonly variant: AlgebraLifecycleVariant;
|
|
11084
|
+
readonly adapter: AlgebraLifecycleAdapter;
|
|
11085
|
+
readonly version: 1 | 2;
|
|
11086
|
+
readonly factory: Address;
|
|
11087
|
+
readonly createPool: 'pair' | 'pair-with-plugin-data';
|
|
11088
|
+
readonly state: 'legacy-global-state' | 'directional-global-state' | 'integral-global-state';
|
|
11089
|
+
/**
|
|
11090
|
+
* Metadata only. An EOA must not call this entry point directly: the
|
|
11091
|
+
* authoritative contract requires msg.sender to equal the custom deployer.
|
|
11092
|
+
*/
|
|
11093
|
+
readonly customPoolEntryPoint?: Address;
|
|
11094
|
+
readonly customPoolCreation: 'not-configured' | 'adapter-specific-deployer-required';
|
|
11095
|
+
readonly provenance: AlgebraLifecycleProvenance;
|
|
11096
|
+
}
|
|
11097
|
+
/**
|
|
11098
|
+
* Explicit lifecycle capabilities for every Algebra-family protocol/chain pair
|
|
11099
|
+
* currently present in the SDK AMM registry. Subgraph presence is never used as
|
|
11100
|
+
* a runtime fallback.
|
|
11101
|
+
*/
|
|
11102
|
+
declare const ALGEBRA_LIFECYCLE_DEPLOYMENTS: readonly AlgebraLifecycleDeployment[];
|
|
11103
|
+
declare function resolveAlgebraLifecycleDeployment(params: {
|
|
11104
|
+
readonly chainId: number;
|
|
11105
|
+
readonly protocol: SupportedProtocol;
|
|
11106
|
+
}): AlgebraLifecycleDeployment | undefined;
|
|
11107
|
+
/** Validate external capability metadata and return its canonical frozen entry. */
|
|
11108
|
+
declare function validateAlgebraLifecycleDeployment(value: unknown): AlgebraLifecycleDeployment;
|
|
11109
|
+
//#endregion
|
|
11110
|
+
//#region src/pool-lifecycle/capabilities/v3.d.ts
|
|
11111
|
+
type V3LifecycleDeploymentProvenance = {
|
|
11112
|
+
readonly source: 'sdk-config' | 'official-deployment' | 'verified-explorer';
|
|
11113
|
+
readonly urls: readonly `https://${string}`[];
|
|
11114
|
+
};
|
|
11115
|
+
type V3LifecycleDeploymentCommon = {
|
|
11116
|
+
readonly supported: true;
|
|
11117
|
+
readonly schemaVersion: 1;
|
|
11118
|
+
readonly chainId: number;
|
|
11119
|
+
readonly protocol: SupportedProtocol;
|
|
11120
|
+
readonly family: 'uniswap-v3-compatible';
|
|
11121
|
+
readonly version: 1;
|
|
11122
|
+
readonly factory: Address;
|
|
11123
|
+
readonly poolInitCodeHash?: Hex;
|
|
11124
|
+
readonly provenance: V3LifecycleDeploymentProvenance;
|
|
11125
|
+
readonly startBlock?: bigint;
|
|
11126
|
+
};
|
|
11127
|
+
type V3AtomicLifecycleDeployment = V3LifecycleDeploymentCommon & {
|
|
11128
|
+
readonly adapter: 'pool-initializer-v1';
|
|
11129
|
+
readonly initializer: Address;
|
|
11130
|
+
readonly atomicCreateAndInitialize: true;
|
|
11131
|
+
};
|
|
11132
|
+
type V3FactoryLifecycleDeployment = V3LifecycleDeploymentCommon & {
|
|
11133
|
+
readonly adapter: 'v3-factory-v1';
|
|
11134
|
+
readonly initializer: null;
|
|
11135
|
+
readonly atomicCreateAndInitialize: false;
|
|
11136
|
+
};
|
|
11137
|
+
type V3LifecycleDeployment = V3AtomicLifecycleDeployment | V3FactoryLifecycleDeployment;
|
|
11138
|
+
type ResolveV3LifecycleDeploymentParams = {
|
|
11139
|
+
readonly chainId: number;
|
|
11140
|
+
readonly protocol: SupportedProtocol;
|
|
11141
|
+
};
|
|
11142
|
+
/** Explicit, fail-closed V3 create/initialize deployment allowlist. */
|
|
11143
|
+
declare const V3_LIFECYCLE_DEPLOYMENTS: Readonly<Partial<Record<string, V3LifecycleDeployment>>>;
|
|
11144
|
+
/**
|
|
11145
|
+
* Protocols whose current SDK configuration is intentionally inventoried by
|
|
11146
|
+
* the V3 lifecycle registry. Adding a factory for one of these protocols must
|
|
11147
|
+
* also add an explicit lifecycle capability entry.
|
|
11148
|
+
*/
|
|
11149
|
+
declare const V3_CONFIG_PROTOCOLS: readonly SupportedProtocol[];
|
|
11150
|
+
declare function resolveV3LifecycleDeployment(params: ResolveV3LifecycleDeploymentParams): V3LifecycleDeployment | undefined;
|
|
11151
|
+
//#endregion
|
|
11152
|
+
//#region src/pool-lifecycle/capabilities.d.ts
|
|
11153
|
+
type SupportedPoolLifecycleDeployment = V3LifecycleDeployment | V4LifecycleDeployment | AlgebraLifecycleDeployment;
|
|
11154
|
+
type UnsupportedPoolLifecycleDeployment = {
|
|
11155
|
+
readonly supported: false;
|
|
11156
|
+
readonly schemaVersion: 1;
|
|
11157
|
+
readonly family: 'unsupported';
|
|
11158
|
+
readonly chainId: number;
|
|
11159
|
+
readonly protocol: SupportedProtocol;
|
|
11160
|
+
readonly reason: 'deployment-not-configured';
|
|
11161
|
+
};
|
|
11162
|
+
type PoolLifecycleDeploymentResult = SupportedPoolLifecycleDeployment | UnsupportedPoolLifecycleDeployment;
|
|
11163
|
+
type ResolvePoolLifecycleDeploymentParams = {
|
|
11164
|
+
readonly chainId: number;
|
|
11165
|
+
readonly protocol: SupportedProtocol;
|
|
11166
|
+
};
|
|
11167
|
+
type PoolLifecycleDeploymentRegistry = Readonly<Partial<Record<string, SupportedPoolLifecycleDeployment>>>;
|
|
11168
|
+
/**
|
|
11169
|
+
* Collision-checked current-default deployments, independent of discovery.
|
|
11170
|
+
* Historical V4 entries remain available through V4_LIFECYCLE_DEPLOYMENTS and
|
|
11171
|
+
* its deployment-id resolver instead of competing for this chain/protocol key.
|
|
11172
|
+
*/
|
|
11173
|
+
declare const POOL_LIFECYCLE_DEPLOYMENTS: Readonly<Partial<Record<string, SupportedPoolLifecycleDeployment>>>;
|
|
11174
|
+
/**
|
|
11175
|
+
* Resolve only explicitly versioned lifecycle capabilities. Discovery and
|
|
11176
|
+
* subgraph metadata are never an implicit fallback for transaction building.
|
|
11177
|
+
*/
|
|
11178
|
+
declare function resolvePoolLifecycleDeployment(params: ResolvePoolLifecycleDeploymentParams): PoolLifecycleDeploymentResult;
|
|
11179
|
+
//#endregion
|
|
11180
|
+
//#region src/pool-lifecycle/abis/algebra.d.ts
|
|
11181
|
+
declare const algebraPairFactoryAbi: readonly [{
|
|
11182
|
+
readonly name: "Pool";
|
|
11183
|
+
readonly type: "event";
|
|
11184
|
+
readonly inputs: readonly [{
|
|
11185
|
+
readonly type: "address";
|
|
11186
|
+
readonly name: "token0";
|
|
11187
|
+
readonly indexed: true;
|
|
11188
|
+
}, {
|
|
11189
|
+
readonly type: "address";
|
|
11190
|
+
readonly name: "token1";
|
|
11191
|
+
readonly indexed: true;
|
|
11192
|
+
}, {
|
|
11193
|
+
readonly type: "address";
|
|
11194
|
+
readonly name: "pool";
|
|
11195
|
+
}];
|
|
11196
|
+
}, {
|
|
11197
|
+
readonly name: "poolDeployer";
|
|
11198
|
+
readonly type: "function";
|
|
11199
|
+
readonly stateMutability: "view";
|
|
11200
|
+
readonly inputs: readonly [];
|
|
11201
|
+
readonly outputs: readonly [{
|
|
11202
|
+
readonly type: "address";
|
|
11203
|
+
}];
|
|
11204
|
+
}, {
|
|
11205
|
+
readonly name: "poolByPair";
|
|
11206
|
+
readonly type: "function";
|
|
11207
|
+
readonly stateMutability: "view";
|
|
11208
|
+
readonly inputs: readonly [{
|
|
11209
|
+
readonly type: "address";
|
|
11210
|
+
readonly name: "tokenA";
|
|
11211
|
+
}, {
|
|
11212
|
+
readonly type: "address";
|
|
11213
|
+
readonly name: "tokenB";
|
|
11214
|
+
}];
|
|
11215
|
+
readonly outputs: readonly [{
|
|
11216
|
+
readonly type: "address";
|
|
11217
|
+
readonly name: "pool";
|
|
11218
|
+
}];
|
|
11219
|
+
}, {
|
|
11220
|
+
readonly name: "createPool";
|
|
11221
|
+
readonly type: "function";
|
|
11222
|
+
readonly stateMutability: "nonpayable";
|
|
11223
|
+
readonly inputs: readonly [{
|
|
11224
|
+
readonly type: "address";
|
|
11225
|
+
readonly name: "tokenA";
|
|
11226
|
+
}, {
|
|
11227
|
+
readonly type: "address";
|
|
11228
|
+
readonly name: "tokenB";
|
|
11229
|
+
}];
|
|
11230
|
+
readonly outputs: readonly [{
|
|
11231
|
+
readonly type: "address";
|
|
11232
|
+
readonly name: "pool";
|
|
11233
|
+
}];
|
|
11234
|
+
}];
|
|
11235
|
+
declare const algebraIntegralPluginDataFactoryAbi: readonly [{
|
|
11236
|
+
readonly name: "Pool";
|
|
11237
|
+
readonly type: "event";
|
|
11238
|
+
readonly inputs: readonly [{
|
|
11239
|
+
readonly type: "address";
|
|
11240
|
+
readonly name: "token0";
|
|
11241
|
+
readonly indexed: true;
|
|
11242
|
+
}, {
|
|
11243
|
+
readonly type: "address";
|
|
11244
|
+
readonly name: "token1";
|
|
11245
|
+
readonly indexed: true;
|
|
11246
|
+
}, {
|
|
11247
|
+
readonly type: "address";
|
|
11248
|
+
readonly name: "pool";
|
|
11249
|
+
}];
|
|
11250
|
+
}, {
|
|
11251
|
+
readonly name: "CustomPool";
|
|
11252
|
+
readonly type: "event";
|
|
11253
|
+
readonly inputs: readonly [{
|
|
11254
|
+
readonly type: "address";
|
|
11255
|
+
readonly name: "deployer";
|
|
11256
|
+
readonly indexed: true;
|
|
11257
|
+
}, {
|
|
11258
|
+
readonly type: "address";
|
|
11259
|
+
readonly name: "token0";
|
|
11260
|
+
readonly indexed: true;
|
|
11261
|
+
}, {
|
|
11262
|
+
readonly type: "address";
|
|
11263
|
+
readonly name: "token1";
|
|
11264
|
+
readonly indexed: true;
|
|
11265
|
+
}, {
|
|
11266
|
+
readonly type: "address";
|
|
11267
|
+
readonly name: "pool";
|
|
11268
|
+
}];
|
|
11269
|
+
}, {
|
|
11270
|
+
readonly name: "poolDeployer";
|
|
11271
|
+
readonly type: "function";
|
|
11272
|
+
readonly stateMutability: "view";
|
|
11273
|
+
readonly inputs: readonly [];
|
|
11274
|
+
readonly outputs: readonly [{
|
|
11275
|
+
readonly type: "address";
|
|
11276
|
+
}];
|
|
11277
|
+
}, {
|
|
11278
|
+
readonly name: "poolByPair";
|
|
11279
|
+
readonly type: "function";
|
|
11280
|
+
readonly stateMutability: "view";
|
|
11281
|
+
readonly inputs: readonly [{
|
|
11282
|
+
readonly type: "address";
|
|
11283
|
+
readonly name: "tokenA";
|
|
11284
|
+
}, {
|
|
11285
|
+
readonly type: "address";
|
|
11286
|
+
readonly name: "tokenB";
|
|
11287
|
+
}];
|
|
11288
|
+
readonly outputs: readonly [{
|
|
11289
|
+
readonly type: "address";
|
|
11290
|
+
readonly name: "pool";
|
|
11291
|
+
}];
|
|
11292
|
+
}, {
|
|
11293
|
+
readonly name: "createPool";
|
|
11294
|
+
readonly type: "function";
|
|
11295
|
+
readonly stateMutability: "nonpayable";
|
|
11296
|
+
readonly inputs: readonly [{
|
|
11297
|
+
readonly type: "address";
|
|
11298
|
+
readonly name: "tokenA";
|
|
11299
|
+
}, {
|
|
11300
|
+
readonly type: "address";
|
|
11301
|
+
readonly name: "tokenB";
|
|
11302
|
+
}, {
|
|
11303
|
+
readonly type: "bytes";
|
|
11304
|
+
readonly name: "data";
|
|
11305
|
+
}];
|
|
11306
|
+
readonly outputs: readonly [{
|
|
11307
|
+
readonly type: "address";
|
|
11308
|
+
readonly name: "pool";
|
|
11309
|
+
}];
|
|
11310
|
+
}, {
|
|
11311
|
+
readonly name: "defaultConfigurationForPool";
|
|
11312
|
+
readonly type: "function";
|
|
11313
|
+
readonly stateMutability: "view";
|
|
11314
|
+
readonly inputs: readonly [];
|
|
11315
|
+
readonly outputs: readonly [{
|
|
11316
|
+
readonly type: "uint16";
|
|
11317
|
+
readonly name: "communityFee";
|
|
11318
|
+
}, {
|
|
11319
|
+
readonly type: "int24";
|
|
11320
|
+
readonly name: "tickSpacing";
|
|
11321
|
+
}, {
|
|
11322
|
+
readonly type: "uint16";
|
|
11323
|
+
readonly name: "fee";
|
|
11324
|
+
}];
|
|
11325
|
+
}, {
|
|
11326
|
+
readonly name: "defaultPluginFactory";
|
|
11327
|
+
readonly type: "function";
|
|
11328
|
+
readonly stateMutability: "view";
|
|
11329
|
+
readonly inputs: readonly [];
|
|
11330
|
+
readonly outputs: readonly [{
|
|
11331
|
+
readonly type: "address";
|
|
11332
|
+
}];
|
|
11333
|
+
}];
|
|
11334
|
+
declare const algebraIntegralPairFactoryAbi: readonly [{
|
|
11335
|
+
readonly name: "Pool";
|
|
11336
|
+
readonly type: "event";
|
|
11337
|
+
readonly inputs: readonly [{
|
|
11338
|
+
readonly type: "address";
|
|
11339
|
+
readonly name: "token0";
|
|
11340
|
+
readonly indexed: true;
|
|
11341
|
+
}, {
|
|
11342
|
+
readonly type: "address";
|
|
11343
|
+
readonly name: "token1";
|
|
11344
|
+
readonly indexed: true;
|
|
11345
|
+
}, {
|
|
11346
|
+
readonly type: "address";
|
|
11347
|
+
readonly name: "pool";
|
|
11348
|
+
}];
|
|
11349
|
+
}, {
|
|
11350
|
+
readonly name: "CustomPool";
|
|
11351
|
+
readonly type: "event";
|
|
11352
|
+
readonly inputs: readonly [{
|
|
11353
|
+
readonly type: "address";
|
|
11354
|
+
readonly name: "deployer";
|
|
11355
|
+
readonly indexed: true;
|
|
11356
|
+
}, {
|
|
11357
|
+
readonly type: "address";
|
|
11358
|
+
readonly name: "token0";
|
|
11359
|
+
readonly indexed: true;
|
|
11360
|
+
}, {
|
|
11361
|
+
readonly type: "address";
|
|
11362
|
+
readonly name: "token1";
|
|
11363
|
+
readonly indexed: true;
|
|
11364
|
+
}, {
|
|
11365
|
+
readonly type: "address";
|
|
11366
|
+
readonly name: "pool";
|
|
11367
|
+
}];
|
|
11368
|
+
}, {
|
|
11369
|
+
readonly name: "poolDeployer";
|
|
11370
|
+
readonly type: "function";
|
|
11371
|
+
readonly stateMutability: "view";
|
|
11372
|
+
readonly inputs: readonly [];
|
|
11373
|
+
readonly outputs: readonly [{
|
|
11374
|
+
readonly type: "address";
|
|
11375
|
+
}];
|
|
11376
|
+
}, {
|
|
11377
|
+
readonly name: "poolByPair";
|
|
11378
|
+
readonly type: "function";
|
|
11379
|
+
readonly stateMutability: "view";
|
|
11380
|
+
readonly inputs: readonly [{
|
|
11381
|
+
readonly type: "address";
|
|
11382
|
+
readonly name: "tokenA";
|
|
11383
|
+
}, {
|
|
11384
|
+
readonly type: "address";
|
|
11385
|
+
readonly name: "tokenB";
|
|
11386
|
+
}];
|
|
11387
|
+
readonly outputs: readonly [{
|
|
11388
|
+
readonly type: "address";
|
|
11389
|
+
readonly name: "pool";
|
|
11390
|
+
}];
|
|
11391
|
+
}, {
|
|
11392
|
+
readonly name: "createPool";
|
|
11393
|
+
readonly type: "function";
|
|
11394
|
+
readonly stateMutability: "nonpayable";
|
|
11395
|
+
readonly inputs: readonly [{
|
|
11396
|
+
readonly type: "address";
|
|
11397
|
+
readonly name: "tokenA";
|
|
11398
|
+
}, {
|
|
11399
|
+
readonly type: "address";
|
|
11400
|
+
readonly name: "tokenB";
|
|
11401
|
+
}];
|
|
11402
|
+
readonly outputs: readonly [{
|
|
11403
|
+
readonly type: "address";
|
|
11404
|
+
readonly name: "pool";
|
|
11405
|
+
}];
|
|
11406
|
+
}, {
|
|
11407
|
+
readonly name: "defaultTickspacing";
|
|
11408
|
+
readonly type: "function";
|
|
11409
|
+
readonly stateMutability: "view";
|
|
11410
|
+
readonly inputs: readonly [];
|
|
11411
|
+
readonly outputs: readonly [{
|
|
11412
|
+
readonly type: "int24";
|
|
11413
|
+
}];
|
|
11414
|
+
}, {
|
|
11415
|
+
readonly name: "defaultFee";
|
|
11416
|
+
readonly type: "function";
|
|
11417
|
+
readonly stateMutability: "view";
|
|
11418
|
+
readonly inputs: readonly [];
|
|
11419
|
+
readonly outputs: readonly [{
|
|
11420
|
+
readonly type: "uint16";
|
|
11421
|
+
}];
|
|
11422
|
+
}, {
|
|
11423
|
+
readonly name: "defaultPluginFactory";
|
|
11424
|
+
readonly type: "function";
|
|
11425
|
+
readonly stateMutability: "view";
|
|
11426
|
+
readonly inputs: readonly [];
|
|
11427
|
+
readonly outputs: readonly [{
|
|
11428
|
+
readonly type: "address";
|
|
11429
|
+
}];
|
|
11430
|
+
}];
|
|
11431
|
+
declare const algebraPoolBaseAbi: readonly [{
|
|
11432
|
+
readonly name: "Initialize";
|
|
11433
|
+
readonly type: "event";
|
|
11434
|
+
readonly inputs: readonly [{
|
|
11435
|
+
readonly type: "uint160";
|
|
11436
|
+
readonly name: "price";
|
|
11437
|
+
}, {
|
|
11438
|
+
readonly type: "int24";
|
|
11439
|
+
readonly name: "tick";
|
|
11440
|
+
}];
|
|
11441
|
+
}, {
|
|
11442
|
+
readonly name: "factory";
|
|
11443
|
+
readonly type: "function";
|
|
11444
|
+
readonly stateMutability: "view";
|
|
11445
|
+
readonly inputs: readonly [];
|
|
11446
|
+
readonly outputs: readonly [{
|
|
11447
|
+
readonly type: "address";
|
|
11448
|
+
}];
|
|
11449
|
+
}, {
|
|
11450
|
+
readonly name: "token0";
|
|
11451
|
+
readonly type: "function";
|
|
11452
|
+
readonly stateMutability: "view";
|
|
11453
|
+
readonly inputs: readonly [];
|
|
11454
|
+
readonly outputs: readonly [{
|
|
11455
|
+
readonly type: "address";
|
|
11456
|
+
}];
|
|
11457
|
+
}, {
|
|
11458
|
+
readonly name: "token1";
|
|
11459
|
+
readonly type: "function";
|
|
11460
|
+
readonly stateMutability: "view";
|
|
11461
|
+
readonly inputs: readonly [];
|
|
11462
|
+
readonly outputs: readonly [{
|
|
11463
|
+
readonly type: "address";
|
|
11464
|
+
}];
|
|
11465
|
+
}, {
|
|
11466
|
+
readonly name: "tickSpacing";
|
|
11467
|
+
readonly type: "function";
|
|
11468
|
+
readonly stateMutability: "view";
|
|
11469
|
+
readonly inputs: readonly [];
|
|
11470
|
+
readonly outputs: readonly [{
|
|
11471
|
+
readonly type: "int24";
|
|
11472
|
+
}];
|
|
11473
|
+
}, {
|
|
11474
|
+
readonly name: "initialize";
|
|
11475
|
+
readonly type: "function";
|
|
11476
|
+
readonly stateMutability: "nonpayable";
|
|
11477
|
+
readonly inputs: readonly [{
|
|
11478
|
+
readonly type: "uint160";
|
|
11479
|
+
readonly name: "initialPrice";
|
|
11480
|
+
}];
|
|
11481
|
+
readonly outputs: readonly [];
|
|
11482
|
+
}];
|
|
11483
|
+
declare const algebraLegacyPoolStateAbi: readonly [{
|
|
11484
|
+
readonly name: "globalState";
|
|
11485
|
+
readonly type: "function";
|
|
11486
|
+
readonly stateMutability: "view";
|
|
11487
|
+
readonly inputs: readonly [];
|
|
11488
|
+
readonly outputs: readonly [{
|
|
11489
|
+
readonly type: "uint160";
|
|
11490
|
+
readonly name: "price";
|
|
11491
|
+
}, {
|
|
11492
|
+
readonly type: "int24";
|
|
11493
|
+
readonly name: "tick";
|
|
11494
|
+
}, {
|
|
11495
|
+
readonly type: "int24";
|
|
11496
|
+
readonly name: "prevInitializedTick";
|
|
11497
|
+
}, {
|
|
11498
|
+
readonly type: "uint16";
|
|
11499
|
+
readonly name: "fee";
|
|
11500
|
+
}, {
|
|
11501
|
+
readonly type: "uint16";
|
|
11502
|
+
readonly name: "timepointIndex";
|
|
11503
|
+
}, {
|
|
11504
|
+
readonly type: "uint8";
|
|
11505
|
+
readonly name: "communityFee";
|
|
11506
|
+
}, {
|
|
11507
|
+
readonly type: "bool";
|
|
11508
|
+
readonly name: "unlocked";
|
|
11509
|
+
}];
|
|
11510
|
+
}];
|
|
11511
|
+
declare const algebraDirectionalPoolStateAbi: readonly [{
|
|
11512
|
+
readonly name: "globalState";
|
|
11513
|
+
readonly type: "function";
|
|
11514
|
+
readonly stateMutability: "view";
|
|
11515
|
+
readonly inputs: readonly [];
|
|
11516
|
+
readonly outputs: readonly [{
|
|
11517
|
+
readonly type: "uint160";
|
|
11518
|
+
readonly name: "price";
|
|
11519
|
+
}, {
|
|
11520
|
+
readonly type: "int24";
|
|
11521
|
+
readonly name: "tick";
|
|
11522
|
+
}, {
|
|
11523
|
+
readonly type: "uint16";
|
|
11524
|
+
readonly name: "feeZto";
|
|
11525
|
+
}, {
|
|
11526
|
+
readonly type: "uint16";
|
|
11527
|
+
readonly name: "feeOtz";
|
|
11528
|
+
}, {
|
|
11529
|
+
readonly type: "uint16";
|
|
11530
|
+
readonly name: "timepointIndex";
|
|
11531
|
+
}, {
|
|
11532
|
+
readonly type: "uint8";
|
|
11533
|
+
readonly name: "communityFeeToken0";
|
|
11534
|
+
}, {
|
|
11535
|
+
readonly type: "uint8";
|
|
11536
|
+
readonly name: "communityFeeToken1";
|
|
11537
|
+
}, {
|
|
11538
|
+
readonly type: "bool";
|
|
11539
|
+
readonly name: "unlocked";
|
|
11540
|
+
}];
|
|
11541
|
+
}];
|
|
11542
|
+
declare const algebraIntegralPoolStateAbi: readonly [{
|
|
11543
|
+
readonly name: "globalState";
|
|
11544
|
+
readonly type: "function";
|
|
11545
|
+
readonly stateMutability: "view";
|
|
11546
|
+
readonly inputs: readonly [];
|
|
11547
|
+
readonly outputs: readonly [{
|
|
11548
|
+
readonly type: "uint160";
|
|
11549
|
+
readonly name: "price";
|
|
11550
|
+
}, {
|
|
11551
|
+
readonly type: "int24";
|
|
11552
|
+
readonly name: "tick";
|
|
11553
|
+
}, {
|
|
11554
|
+
readonly type: "uint16";
|
|
11555
|
+
readonly name: "lastFee";
|
|
11556
|
+
}, {
|
|
11557
|
+
readonly type: "uint8";
|
|
11558
|
+
readonly name: "pluginConfig";
|
|
11559
|
+
}, {
|
|
11560
|
+
readonly type: "uint16";
|
|
11561
|
+
readonly name: "communityFee";
|
|
11562
|
+
}, {
|
|
11563
|
+
readonly type: "bool";
|
|
11564
|
+
readonly name: "unlocked";
|
|
11565
|
+
}];
|
|
11566
|
+
}, {
|
|
11567
|
+
readonly name: "plugin";
|
|
11568
|
+
readonly type: "function";
|
|
11569
|
+
readonly stateMutability: "view";
|
|
11570
|
+
readonly inputs: readonly [];
|
|
11571
|
+
readonly outputs: readonly [{
|
|
11572
|
+
readonly type: "address";
|
|
11573
|
+
}];
|
|
11574
|
+
}];
|
|
11575
|
+
/**
|
|
11576
|
+
* Kept separate from standard pool creation. Calling this directly from an EOA
|
|
11577
|
+
* is invalid because the entry point requires msg.sender == deployer.
|
|
11578
|
+
*/
|
|
11579
|
+
declare const algebraCustomPoolEntryPointAbi: readonly [{
|
|
11580
|
+
readonly name: "factory";
|
|
11581
|
+
readonly type: "function";
|
|
11582
|
+
readonly stateMutability: "view";
|
|
11583
|
+
readonly inputs: readonly [];
|
|
11584
|
+
readonly outputs: readonly [{
|
|
11585
|
+
readonly type: "address";
|
|
11586
|
+
}];
|
|
11587
|
+
}, {
|
|
11588
|
+
readonly name: "createCustomPool";
|
|
11589
|
+
readonly type: "function";
|
|
11590
|
+
readonly stateMutability: "nonpayable";
|
|
11591
|
+
readonly inputs: readonly [{
|
|
11592
|
+
readonly type: "address";
|
|
11593
|
+
readonly name: "deployer";
|
|
11594
|
+
}, {
|
|
11595
|
+
readonly type: "address";
|
|
11596
|
+
readonly name: "creator";
|
|
11597
|
+
}, {
|
|
11598
|
+
readonly type: "address";
|
|
11599
|
+
readonly name: "tokenA";
|
|
11600
|
+
}, {
|
|
11601
|
+
readonly type: "address";
|
|
11602
|
+
readonly name: "tokenB";
|
|
11603
|
+
}, {
|
|
11604
|
+
readonly type: "bytes";
|
|
11605
|
+
readonly name: "data";
|
|
11606
|
+
}];
|
|
11607
|
+
readonly outputs: readonly [{
|
|
11608
|
+
readonly type: "address";
|
|
11609
|
+
readonly name: "customPool";
|
|
11610
|
+
}];
|
|
11611
|
+
}];
|
|
11612
|
+
//#endregion
|
|
11613
|
+
//#region src/pool-lifecycle/abis/v3.d.ts
|
|
11614
|
+
/** Minimal canonical Uniswap V3-compatible factory ABI used by pool lifecycle flows. */
|
|
11615
|
+
declare const v3FactoryAbi: readonly [{
|
|
11616
|
+
readonly type: "function";
|
|
11617
|
+
readonly name: "createPool";
|
|
11618
|
+
readonly stateMutability: "nonpayable";
|
|
11619
|
+
readonly inputs: readonly [{
|
|
11620
|
+
readonly name: "tokenA";
|
|
11621
|
+
readonly type: "address";
|
|
11622
|
+
}, {
|
|
11623
|
+
readonly name: "tokenB";
|
|
11624
|
+
readonly type: "address";
|
|
11625
|
+
}, {
|
|
11626
|
+
readonly name: "fee";
|
|
11627
|
+
readonly type: "uint24";
|
|
11628
|
+
}];
|
|
11629
|
+
readonly outputs: readonly [{
|
|
11630
|
+
readonly name: "pool";
|
|
11631
|
+
readonly type: "address";
|
|
11632
|
+
}];
|
|
11633
|
+
}, {
|
|
11634
|
+
readonly type: "function";
|
|
11635
|
+
readonly name: "getPool";
|
|
11636
|
+
readonly stateMutability: "view";
|
|
11637
|
+
readonly inputs: readonly [{
|
|
11638
|
+
readonly name: "tokenA";
|
|
11639
|
+
readonly type: "address";
|
|
11640
|
+
}, {
|
|
11641
|
+
readonly name: "tokenB";
|
|
11642
|
+
readonly type: "address";
|
|
11643
|
+
}, {
|
|
11644
|
+
readonly name: "fee";
|
|
11645
|
+
readonly type: "uint24";
|
|
11646
|
+
}];
|
|
11647
|
+
readonly outputs: readonly [{
|
|
11648
|
+
readonly name: "pool";
|
|
11649
|
+
readonly type: "address";
|
|
11650
|
+
}];
|
|
11651
|
+
}, {
|
|
11652
|
+
readonly type: "function";
|
|
11653
|
+
readonly name: "feeAmountTickSpacing";
|
|
11654
|
+
readonly stateMutability: "view";
|
|
11655
|
+
readonly inputs: readonly [{
|
|
11656
|
+
readonly name: "fee";
|
|
11657
|
+
readonly type: "uint24";
|
|
11658
|
+
}];
|
|
11659
|
+
readonly outputs: readonly [{
|
|
11660
|
+
readonly name: "tickSpacing";
|
|
11661
|
+
readonly type: "int24";
|
|
11662
|
+
}];
|
|
11663
|
+
}, {
|
|
11664
|
+
readonly type: "event";
|
|
11665
|
+
readonly name: "PoolCreated";
|
|
11666
|
+
readonly inputs: readonly [{
|
|
11667
|
+
readonly name: "token0";
|
|
11668
|
+
readonly type: "address";
|
|
11669
|
+
readonly indexed: true;
|
|
11670
|
+
}, {
|
|
11671
|
+
readonly name: "token1";
|
|
11672
|
+
readonly type: "address";
|
|
11673
|
+
readonly indexed: true;
|
|
11674
|
+
}, {
|
|
11675
|
+
readonly name: "fee";
|
|
11676
|
+
readonly type: "uint24";
|
|
11677
|
+
readonly indexed: true;
|
|
11678
|
+
}, {
|
|
11679
|
+
readonly name: "tickSpacing";
|
|
11680
|
+
readonly type: "int24";
|
|
11681
|
+
readonly indexed: false;
|
|
11682
|
+
}, {
|
|
11683
|
+
readonly name: "pool";
|
|
11684
|
+
readonly type: "address";
|
|
11685
|
+
readonly indexed: false;
|
|
11686
|
+
}];
|
|
11687
|
+
}];
|
|
11688
|
+
/** Minimal PoolInitializer/NonfungiblePositionManager ABI used for atomic V3 setup. */
|
|
11689
|
+
declare const v3PoolInitializerAbi: readonly [{
|
|
11690
|
+
readonly type: "function";
|
|
11691
|
+
readonly name: "createAndInitializePoolIfNecessary";
|
|
11692
|
+
readonly stateMutability: "payable";
|
|
11693
|
+
readonly inputs: readonly [{
|
|
11694
|
+
readonly name: "token0";
|
|
11695
|
+
readonly type: "address";
|
|
11696
|
+
}, {
|
|
11697
|
+
readonly name: "token1";
|
|
11698
|
+
readonly type: "address";
|
|
11699
|
+
}, {
|
|
11700
|
+
readonly name: "fee";
|
|
11701
|
+
readonly type: "uint24";
|
|
11702
|
+
}, {
|
|
11703
|
+
readonly name: "sqrtPriceX96";
|
|
11704
|
+
readonly type: "uint160";
|
|
11705
|
+
}];
|
|
11706
|
+
readonly outputs: readonly [{
|
|
11707
|
+
readonly name: "pool";
|
|
11708
|
+
readonly type: "address";
|
|
11709
|
+
}];
|
|
11710
|
+
}, {
|
|
11711
|
+
readonly type: "function";
|
|
11712
|
+
readonly name: "factory";
|
|
11713
|
+
readonly stateMutability: "view";
|
|
11714
|
+
readonly inputs: readonly [];
|
|
11715
|
+
readonly outputs: readonly [{
|
|
11716
|
+
readonly name: "";
|
|
11717
|
+
readonly type: "address";
|
|
11718
|
+
}];
|
|
11719
|
+
}];
|
|
11720
|
+
/** Minimal canonical V3 pool ABI needed to initialize and verify a deployment. */
|
|
11721
|
+
declare const v3PoolAbi: readonly [{
|
|
11722
|
+
readonly type: "function";
|
|
11723
|
+
readonly name: "initialize";
|
|
11724
|
+
readonly stateMutability: "nonpayable";
|
|
11725
|
+
readonly inputs: readonly [{
|
|
11726
|
+
readonly name: "sqrtPriceX96";
|
|
11727
|
+
readonly type: "uint160";
|
|
11728
|
+
}];
|
|
11729
|
+
readonly outputs: readonly [];
|
|
11730
|
+
}, {
|
|
11731
|
+
readonly type: "function";
|
|
11732
|
+
readonly name: "factory";
|
|
11733
|
+
readonly stateMutability: "view";
|
|
11734
|
+
readonly inputs: readonly [];
|
|
11735
|
+
readonly outputs: readonly [{
|
|
11736
|
+
readonly name: "";
|
|
11737
|
+
readonly type: "address";
|
|
11738
|
+
}];
|
|
11739
|
+
}, {
|
|
11740
|
+
readonly type: "function";
|
|
11741
|
+
readonly name: "token0";
|
|
11742
|
+
readonly stateMutability: "view";
|
|
11743
|
+
readonly inputs: readonly [];
|
|
11744
|
+
readonly outputs: readonly [{
|
|
11745
|
+
readonly name: "";
|
|
11746
|
+
readonly type: "address";
|
|
11747
|
+
}];
|
|
11748
|
+
}, {
|
|
11749
|
+
readonly type: "function";
|
|
11750
|
+
readonly name: "token1";
|
|
11751
|
+
readonly stateMutability: "view";
|
|
11752
|
+
readonly inputs: readonly [];
|
|
11753
|
+
readonly outputs: readonly [{
|
|
11754
|
+
readonly name: "";
|
|
11755
|
+
readonly type: "address";
|
|
11756
|
+
}];
|
|
11757
|
+
}, {
|
|
11758
|
+
readonly type: "function";
|
|
11759
|
+
readonly name: "fee";
|
|
11760
|
+
readonly stateMutability: "view";
|
|
11761
|
+
readonly inputs: readonly [];
|
|
11762
|
+
readonly outputs: readonly [{
|
|
11763
|
+
readonly name: "";
|
|
11764
|
+
readonly type: "uint24";
|
|
11765
|
+
}];
|
|
11766
|
+
}, {
|
|
11767
|
+
readonly type: "function";
|
|
11768
|
+
readonly name: "tickSpacing";
|
|
11769
|
+
readonly stateMutability: "view";
|
|
11770
|
+
readonly inputs: readonly [];
|
|
11771
|
+
readonly outputs: readonly [{
|
|
11772
|
+
readonly name: "";
|
|
11773
|
+
readonly type: "int24";
|
|
11774
|
+
}];
|
|
11775
|
+
}, {
|
|
11776
|
+
readonly type: "function";
|
|
11777
|
+
readonly name: "slot0";
|
|
11778
|
+
readonly stateMutability: "view";
|
|
11779
|
+
readonly inputs: readonly [];
|
|
11780
|
+
readonly outputs: readonly [{
|
|
11781
|
+
readonly name: "sqrtPriceX96";
|
|
11782
|
+
readonly type: "uint160";
|
|
11783
|
+
}, {
|
|
11784
|
+
readonly name: "tick";
|
|
11785
|
+
readonly type: "int24";
|
|
11786
|
+
}, {
|
|
11787
|
+
readonly name: "observationIndex";
|
|
11788
|
+
readonly type: "uint16";
|
|
11789
|
+
}, {
|
|
11790
|
+
readonly name: "observationCardinality";
|
|
11791
|
+
readonly type: "uint16";
|
|
11792
|
+
}, {
|
|
11793
|
+
readonly name: "observationCardinalityNext";
|
|
11794
|
+
readonly type: "uint16";
|
|
11795
|
+
}, {
|
|
11796
|
+
readonly name: "feeProtocol";
|
|
11797
|
+
readonly type: "uint8";
|
|
11798
|
+
}, {
|
|
11799
|
+
readonly name: "unlocked";
|
|
11800
|
+
readonly type: "bool";
|
|
11801
|
+
}];
|
|
11802
|
+
}, {
|
|
11803
|
+
readonly type: "event";
|
|
11804
|
+
readonly name: "Initialize";
|
|
11805
|
+
readonly inputs: readonly [{
|
|
11806
|
+
readonly name: "sqrtPriceX96";
|
|
11807
|
+
readonly type: "uint160";
|
|
11808
|
+
readonly indexed: false;
|
|
11809
|
+
}, {
|
|
11810
|
+
readonly name: "tick";
|
|
11811
|
+
readonly type: "int24";
|
|
11812
|
+
readonly indexed: false;
|
|
11813
|
+
}];
|
|
11814
|
+
}];
|
|
11815
|
+
//#endregion
|
|
11816
|
+
//#region src/pool-lifecycle/abis/v4.d.ts
|
|
11817
|
+
/** Minimal authoritative IPoolManager surface used by the V4 lifecycle adapter. */
|
|
11818
|
+
declare const v4PoolManagerAbi: readonly [{
|
|
11819
|
+
readonly name: "initialize";
|
|
11820
|
+
readonly type: "function";
|
|
11821
|
+
readonly stateMutability: "nonpayable";
|
|
11822
|
+
readonly inputs: readonly [{
|
|
11823
|
+
readonly type: "tuple";
|
|
11824
|
+
readonly components: readonly [{
|
|
11825
|
+
readonly type: "address";
|
|
11826
|
+
readonly name: "currency0";
|
|
11827
|
+
}, {
|
|
11828
|
+
readonly type: "address";
|
|
11829
|
+
readonly name: "currency1";
|
|
11830
|
+
}, {
|
|
11831
|
+
readonly type: "uint24";
|
|
11832
|
+
readonly name: "fee";
|
|
11833
|
+
}, {
|
|
11834
|
+
readonly type: "int24";
|
|
11835
|
+
readonly name: "tickSpacing";
|
|
11836
|
+
}, {
|
|
11837
|
+
readonly type: "address";
|
|
11838
|
+
readonly name: "hooks";
|
|
11839
|
+
}];
|
|
11840
|
+
readonly name: "key";
|
|
11841
|
+
}, {
|
|
11842
|
+
readonly type: "uint160";
|
|
11843
|
+
readonly name: "sqrtPriceX96";
|
|
11844
|
+
}];
|
|
11845
|
+
readonly outputs: readonly [{
|
|
11846
|
+
readonly type: "int24";
|
|
11847
|
+
readonly name: "tick";
|
|
11848
|
+
}];
|
|
11849
|
+
}, {
|
|
11850
|
+
readonly name: "Initialize";
|
|
11851
|
+
readonly type: "event";
|
|
11852
|
+
readonly inputs: readonly [{
|
|
11853
|
+
readonly type: "bytes32";
|
|
11854
|
+
readonly name: "id";
|
|
11855
|
+
readonly indexed: true;
|
|
11856
|
+
}, {
|
|
11857
|
+
readonly type: "address";
|
|
11858
|
+
readonly name: "currency0";
|
|
11859
|
+
readonly indexed: true;
|
|
11860
|
+
}, {
|
|
11861
|
+
readonly type: "address";
|
|
11862
|
+
readonly name: "currency1";
|
|
11863
|
+
readonly indexed: true;
|
|
11864
|
+
}, {
|
|
11865
|
+
readonly type: "uint24";
|
|
11866
|
+
readonly name: "fee";
|
|
11867
|
+
}, {
|
|
11868
|
+
readonly type: "int24";
|
|
11869
|
+
readonly name: "tickSpacing";
|
|
11870
|
+
}, {
|
|
11871
|
+
readonly type: "address";
|
|
11872
|
+
readonly name: "hooks";
|
|
11873
|
+
}, {
|
|
11874
|
+
readonly type: "uint160";
|
|
11875
|
+
readonly name: "sqrtPriceX96";
|
|
11876
|
+
}, {
|
|
11877
|
+
readonly type: "int24";
|
|
11878
|
+
readonly name: "tick";
|
|
11879
|
+
}];
|
|
11880
|
+
}];
|
|
11881
|
+
/** Minimal StateView/ImmutableState surface used for deployment and state checks. */
|
|
11882
|
+
declare const v4StateViewAbi: readonly [{
|
|
11883
|
+
readonly name: "poolManager";
|
|
11884
|
+
readonly type: "function";
|
|
11885
|
+
readonly stateMutability: "view";
|
|
11886
|
+
readonly inputs: readonly [];
|
|
11887
|
+
readonly outputs: readonly [{
|
|
11888
|
+
readonly type: "address";
|
|
11889
|
+
}];
|
|
11890
|
+
}, {
|
|
11891
|
+
readonly name: "getSlot0";
|
|
11892
|
+
readonly type: "function";
|
|
11893
|
+
readonly stateMutability: "view";
|
|
11894
|
+
readonly inputs: readonly [{
|
|
11895
|
+
readonly type: "bytes32";
|
|
11896
|
+
readonly name: "poolId";
|
|
11897
|
+
}];
|
|
11898
|
+
readonly outputs: readonly [{
|
|
11899
|
+
readonly type: "uint160";
|
|
11900
|
+
readonly name: "sqrtPriceX96";
|
|
11901
|
+
}, {
|
|
11902
|
+
readonly type: "int24";
|
|
11903
|
+
readonly name: "tick";
|
|
11904
|
+
}, {
|
|
11905
|
+
readonly type: "uint24";
|
|
11906
|
+
readonly name: "protocolFee";
|
|
11907
|
+
}, {
|
|
11908
|
+
readonly type: "uint24";
|
|
11909
|
+
readonly name: "lpFee";
|
|
11910
|
+
}];
|
|
11911
|
+
}];
|
|
11912
|
+
//#endregion
|
|
11913
|
+
//#region src/pool-lifecycle/algebra/types.d.ts
|
|
11914
|
+
interface AlgebraPoolKeyInput {
|
|
11915
|
+
readonly tokenA: Address;
|
|
11916
|
+
readonly tokenB: Address;
|
|
11917
|
+
}
|
|
11918
|
+
interface AlgebraPoolKey {
|
|
11919
|
+
readonly token0: Address;
|
|
11920
|
+
readonly token1: Address;
|
|
11921
|
+
}
|
|
11922
|
+
interface AlgebraInitialPrice extends AlgebraPoolKey {
|
|
11923
|
+
readonly sqrtPriceX96: bigint;
|
|
11924
|
+
}
|
|
11925
|
+
interface AlgebraPoolSnapshot {
|
|
11926
|
+
readonly schemaVersion: 1;
|
|
11927
|
+
readonly blockNumber: bigint;
|
|
11928
|
+
readonly deployment: AlgebraLifecycleDeployment;
|
|
11929
|
+
readonly key: AlgebraPoolKey;
|
|
11930
|
+
readonly status: 'absent' | 'uninitialized' | 'initialized';
|
|
11931
|
+
readonly poolAddress: Address | null;
|
|
11932
|
+
readonly sqrtPriceX96: bigint;
|
|
11933
|
+
readonly tick: number | null;
|
|
11934
|
+
readonly tickSpacing: number | null;
|
|
11935
|
+
readonly fee: number | null;
|
|
11936
|
+
readonly directionalFee: Readonly<{
|
|
11937
|
+
zeroToOne: number;
|
|
11938
|
+
oneToZero: number;
|
|
11939
|
+
}> | null;
|
|
11940
|
+
readonly plugin: Address | null;
|
|
11941
|
+
readonly pluginConfig: number | null;
|
|
11942
|
+
readonly unlocked: boolean | null;
|
|
11943
|
+
}
|
|
11944
|
+
interface AlgebraPoolIdentity {
|
|
11945
|
+
readonly family: 'algebra';
|
|
11946
|
+
readonly adapter: AlgebraLifecycleDeployment['adapter'];
|
|
11947
|
+
readonly version: 1 | 2;
|
|
11948
|
+
readonly variant: AlgebraLifecycleDeployment['variant'];
|
|
11949
|
+
readonly chainId: number;
|
|
11950
|
+
readonly factory: Address;
|
|
11951
|
+
readonly key: AlgebraPoolKey;
|
|
11952
|
+
readonly poolAddress: Address | null;
|
|
11953
|
+
}
|
|
11954
|
+
interface AlgebraPreflightSummary {
|
|
11955
|
+
readonly blockNumber: bigint;
|
|
11956
|
+
readonly status: AlgebraPoolSnapshot['status'];
|
|
11957
|
+
readonly poolAddress: Address | null;
|
|
11958
|
+
readonly sqrtPriceX96: bigint;
|
|
11959
|
+
}
|
|
11960
|
+
type PreparedAlgebraCreatePoolAction = PreparedPoolAction<'algebra-create', AlgebraPoolIdentity, {
|
|
11961
|
+
readonly sqrtPriceX96: null;
|
|
11962
|
+
readonly pluginData: Hex;
|
|
11963
|
+
}, AlgebraPreflightSummary>;
|
|
11964
|
+
type PreparedAlgebraInitializePoolAction = PreparedPoolAction<'algebra-initialize', AlgebraPoolIdentity, {
|
|
11965
|
+
readonly sqrtPriceX96: bigint;
|
|
11966
|
+
readonly pluginData: null;
|
|
11967
|
+
}, AlgebraPreflightSummary>;
|
|
11968
|
+
type PreparedAlgebraPoolAction = PreparedAlgebraCreatePoolAction | PreparedAlgebraInitializePoolAction;
|
|
11969
|
+
interface AlgebraPoolActionSimulation extends PoolActionSimulation {
|
|
11970
|
+
readonly returnedPoolAddress: Address | null;
|
|
11971
|
+
}
|
|
11972
|
+
interface AlgebraReceiptEvidence {
|
|
11973
|
+
readonly receiptStatus: 'success' | 'reverted';
|
|
11974
|
+
readonly poolCreated: Readonly<{
|
|
11975
|
+
poolAddress: Address;
|
|
11976
|
+
logIndex: number;
|
|
11977
|
+
}> | null;
|
|
11978
|
+
readonly initialization: Readonly<{
|
|
11979
|
+
poolAddress: Address;
|
|
11980
|
+
sqrtPriceX96: bigint;
|
|
11981
|
+
tick: number;
|
|
11982
|
+
logIndex: number;
|
|
11983
|
+
}> | null;
|
|
11984
|
+
}
|
|
11985
|
+
type AlgebraPoolActionVerification = PoolActionVerification<AlgebraPoolIdentity, AlgebraPoolSnapshot, AlgebraReceiptEvidence>;
|
|
11986
|
+
/** Re-derive target and calldata after a plan crosses a UI/CLI/JSON boundary. */
|
|
11987
|
+
declare function validatePreparedAlgebraPoolAction(value: unknown): AlgebraLifecycleDeployment;
|
|
11988
|
+
declare function deserializePreparedAlgebraPoolAction(serialized: string): PreparedAlgebraPoolAction;
|
|
11989
|
+
//#endregion
|
|
11990
|
+
//#region src/pool-lifecycle/algebra/inspect.d.ts
|
|
11991
|
+
interface InspectAlgebraPoolParams {
|
|
11992
|
+
readonly publicClient: PublicClient;
|
|
11993
|
+
readonly deployment: AlgebraLifecycleDeployment;
|
|
11994
|
+
readonly key: AlgebraPoolKeyInput;
|
|
11995
|
+
readonly blockNumber?: bigint;
|
|
11996
|
+
}
|
|
11997
|
+
interface InspectAlgebraCustomPoolEntryPointParams {
|
|
11998
|
+
readonly publicClient: PublicClient;
|
|
11999
|
+
readonly deployment: AlgebraLifecycleDeployment;
|
|
12000
|
+
readonly blockNumber?: bigint;
|
|
12001
|
+
}
|
|
12002
|
+
/** Verify configured custom-pool routing without claiming a generic deployer ABI. */
|
|
12003
|
+
declare function inspectAlgebraCustomPoolEntryPoint(params: InspectAlgebraCustomPoolEntryPointParams): Promise<{
|
|
12004
|
+
readonly blockNumber: bigint;
|
|
12005
|
+
readonly entryPoint: Address;
|
|
12006
|
+
readonly factory: Address;
|
|
12007
|
+
}>;
|
|
12008
|
+
declare function inspectAlgebraPool(params: InspectAlgebraPoolParams): Promise<AlgebraPoolSnapshot>;
|
|
12009
|
+
//#endregion
|
|
12010
|
+
//#region src/pool-lifecycle/algebra/actions.d.ts
|
|
12011
|
+
interface BuildBase {
|
|
12012
|
+
readonly deployment: AlgebraLifecycleDeployment;
|
|
12013
|
+
readonly key: AlgebraPoolKeyInput;
|
|
12014
|
+
readonly preflight: AlgebraPoolSnapshot;
|
|
12015
|
+
}
|
|
12016
|
+
interface BuildAlgebraCreatePoolTransactionParams extends BuildBase {
|
|
12017
|
+
readonly pluginData?: Hex;
|
|
12018
|
+
}
|
|
12019
|
+
interface BuildAlgebraInitializePoolTransactionParams extends BuildBase {
|
|
12020
|
+
readonly initialPrice: AlgebraInitialPrice;
|
|
12021
|
+
}
|
|
12022
|
+
/** Build the version-specific standard-pool factory call without signing it. */
|
|
12023
|
+
declare function buildAlgebraCreatePoolTransaction(params: BuildAlgebraCreatePoolTransactionParams): PreparedAlgebraCreatePoolAction;
|
|
12024
|
+
/** Build a direct initialization call bound to an inspected, uninitialized pool. */
|
|
12025
|
+
declare function buildAlgebraInitializePoolTransaction(params: BuildAlgebraInitializePoolTransactionParams): PreparedAlgebraInitializePoolAction;
|
|
12026
|
+
type PrepareAlgebraPoolResult = {
|
|
12027
|
+
readonly status: 'ready-create';
|
|
12028
|
+
readonly snapshot: AlgebraPoolSnapshot;
|
|
12029
|
+
readonly action: PreparedAlgebraCreatePoolAction;
|
|
12030
|
+
} | {
|
|
12031
|
+
readonly status: 'ready-initialize';
|
|
12032
|
+
readonly snapshot: AlgebraPoolSnapshot;
|
|
12033
|
+
readonly action: PreparedAlgebraInitializePoolAction;
|
|
12034
|
+
} | {
|
|
12035
|
+
readonly status: 'already-initialized-matching';
|
|
12036
|
+
readonly snapshot: AlgebraPoolSnapshot;
|
|
12037
|
+
readonly action: null;
|
|
12038
|
+
};
|
|
12039
|
+
/**
|
|
12040
|
+
* Prepare the next honest lifecycle step. Creation and initialization remain
|
|
12041
|
+
* separate when the SDK has no proven atomic initializer deployment.
|
|
12042
|
+
*/
|
|
12043
|
+
declare function prepareAlgebraPool(params: Omit<InspectAlgebraPoolParams, 'blockNumber'> & {
|
|
12044
|
+
readonly initialPrice: AlgebraInitialPrice;
|
|
12045
|
+
readonly pluginData?: Hex;
|
|
12046
|
+
readonly blockNumber?: bigint;
|
|
12047
|
+
}): Promise<PrepareAlgebraPoolResult>;
|
|
12048
|
+
//#endregion
|
|
12049
|
+
//#region src/pool-lifecycle/algebra/key.d.ts
|
|
12050
|
+
declare function canonicalizeAlgebraPoolKey(input: AlgebraPoolKeyInput): AlgebraPoolKey;
|
|
12051
|
+
declare function assertAlgebraInitialPrice(key: AlgebraPoolKey, price: AlgebraInitialPrice): AlgebraInitialPrice;
|
|
12052
|
+
//#endregion
|
|
12053
|
+
//#region src/pool-lifecycle/algebra/simulate.d.ts
|
|
12054
|
+
interface SimulateAlgebraPoolActionParams {
|
|
12055
|
+
readonly publicClient: PublicClient;
|
|
12056
|
+
readonly account: Address;
|
|
12057
|
+
readonly action: PreparedAlgebraPoolAction;
|
|
12058
|
+
readonly blockNumber?: bigint;
|
|
12059
|
+
}
|
|
12060
|
+
declare function simulateAlgebraPoolAction(params: SimulateAlgebraPoolActionParams): Promise<AlgebraPoolActionSimulation>;
|
|
12061
|
+
//#endregion
|
|
12062
|
+
//#region src/pool-lifecycle/algebra/verify.d.ts
|
|
12063
|
+
interface VerifyAlgebraPoolActionParams {
|
|
12064
|
+
readonly publicClient: PublicClient;
|
|
12065
|
+
readonly action: PreparedAlgebraPoolAction;
|
|
12066
|
+
readonly receipt: TransactionReceipt;
|
|
12067
|
+
}
|
|
12068
|
+
declare function decodeAlgebraPoolActionReceipt(action: PreparedAlgebraPoolAction, receipt: TransactionReceipt): AlgebraReceiptEvidence;
|
|
12069
|
+
declare function verifyAlgebraPoolAction(params: VerifyAlgebraPoolActionParams): Promise<AlgebraPoolActionVerification>;
|
|
12070
|
+
//#endregion
|
|
12071
|
+
//#region src/pool-lifecycle/v3/types.d.ts
|
|
12072
|
+
interface V3PoolKeyInput {
|
|
12073
|
+
readonly tokenA: Address;
|
|
12074
|
+
readonly tokenB: Address;
|
|
12075
|
+
readonly fee: number;
|
|
12076
|
+
}
|
|
12077
|
+
interface V3PoolKey {
|
|
12078
|
+
readonly token0: Address;
|
|
12079
|
+
readonly token1: Address;
|
|
12080
|
+
readonly fee: number;
|
|
12081
|
+
}
|
|
12082
|
+
/** A Q64.96 price bound to the canonical V3 token order. */
|
|
12083
|
+
interface V3InitialPrice {
|
|
12084
|
+
readonly token0: Address;
|
|
12085
|
+
readonly token1: Address;
|
|
12086
|
+
readonly sqrtPriceX96: bigint;
|
|
12087
|
+
}
|
|
12088
|
+
type V3PoolStatus = 'absent' | 'uninitialized' | 'initialized';
|
|
12089
|
+
interface V3PoolSnapshotBase {
|
|
12090
|
+
readonly schemaVersion: 1;
|
|
12091
|
+
readonly blockNumber: bigint;
|
|
12092
|
+
readonly deployment: V3LifecycleDeployment;
|
|
12093
|
+
readonly key: V3PoolKey;
|
|
12094
|
+
readonly feeTickSpacing: number;
|
|
12095
|
+
readonly tickSpacing: number;
|
|
12096
|
+
}
|
|
12097
|
+
interface V3AbsentPoolSnapshot extends V3PoolSnapshotBase {
|
|
12098
|
+
readonly status: 'absent';
|
|
12099
|
+
readonly poolAddress: null;
|
|
12100
|
+
readonly sqrtPriceX96: 0n;
|
|
12101
|
+
readonly tick: null;
|
|
12102
|
+
}
|
|
12103
|
+
interface V3ExistingPoolSnapshotBase extends V3PoolSnapshotBase {
|
|
12104
|
+
readonly poolAddress: Address;
|
|
12105
|
+
readonly tick: number;
|
|
12106
|
+
}
|
|
12107
|
+
interface V3UninitializedPoolSnapshot extends V3ExistingPoolSnapshotBase {
|
|
12108
|
+
readonly status: 'uninitialized';
|
|
12109
|
+
readonly sqrtPriceX96: 0n;
|
|
12110
|
+
}
|
|
12111
|
+
interface V3InitializedPoolSnapshot extends V3ExistingPoolSnapshotBase {
|
|
12112
|
+
readonly status: 'initialized';
|
|
12113
|
+
readonly sqrtPriceX96: bigint;
|
|
12114
|
+
}
|
|
12115
|
+
type V3ExistingPoolSnapshot = V3UninitializedPoolSnapshot | V3InitializedPoolSnapshot;
|
|
12116
|
+
/** Pool lifecycle status and its address/price invariants are discriminated. */
|
|
12117
|
+
type V3PoolSnapshot = V3AbsentPoolSnapshot | V3UninitializedPoolSnapshot | V3InitializedPoolSnapshot;
|
|
12118
|
+
type V3PoolActionKind = 'v3-create' | 'v3-initialize' | 'v3-create-and-initialize';
|
|
12119
|
+
interface V3PoolIdentityBase {
|
|
12120
|
+
readonly family: 'uniswap-v3-compatible';
|
|
12121
|
+
readonly adapter: V3LifecycleDeployment['adapter'];
|
|
12122
|
+
readonly version: 1;
|
|
12123
|
+
readonly chainId: number;
|
|
12124
|
+
readonly factory: Address;
|
|
12125
|
+
readonly initializer: Address | null;
|
|
12126
|
+
readonly key: V3PoolKey;
|
|
12127
|
+
}
|
|
12128
|
+
interface V3CreatePoolIdentity extends V3PoolIdentityBase {
|
|
12129
|
+
readonly poolAddress: null;
|
|
12130
|
+
}
|
|
12131
|
+
interface V3ExistingPoolIdentity extends V3PoolIdentityBase {
|
|
12132
|
+
readonly poolAddress: Address;
|
|
12133
|
+
}
|
|
12134
|
+
interface V3PoolIdentity extends V3PoolIdentityBase {
|
|
12135
|
+
readonly poolAddress: Address | null;
|
|
12136
|
+
}
|
|
12137
|
+
interface V3CreateExpectation {
|
|
12138
|
+
readonly sqrtPriceX96: null;
|
|
12139
|
+
}
|
|
12140
|
+
interface V3InitializeExpectation {
|
|
12141
|
+
readonly sqrtPriceX96: bigint;
|
|
12142
|
+
}
|
|
12143
|
+
type V3PreflightSummary = {
|
|
12144
|
+
readonly blockNumber: bigint;
|
|
12145
|
+
readonly status: 'absent';
|
|
12146
|
+
readonly poolAddress: null;
|
|
12147
|
+
readonly sqrtPriceX96: 0n;
|
|
12148
|
+
} | {
|
|
12149
|
+
readonly blockNumber: bigint;
|
|
12150
|
+
readonly status: 'uninitialized';
|
|
12151
|
+
readonly poolAddress: Address;
|
|
12152
|
+
readonly sqrtPriceX96: 0n;
|
|
12153
|
+
} | {
|
|
12154
|
+
readonly blockNumber: bigint;
|
|
12155
|
+
readonly status: 'initialized';
|
|
12156
|
+
readonly poolAddress: Address;
|
|
12157
|
+
readonly sqrtPriceX96: bigint;
|
|
12158
|
+
};
|
|
12159
|
+
type V3AbsentPreflightSummary = Extract<V3PreflightSummary, {
|
|
12160
|
+
status: 'absent';
|
|
12161
|
+
}>;
|
|
12162
|
+
type V3UninitializedPreflightSummary = Extract<V3PreflightSummary, {
|
|
12163
|
+
status: 'uninitialized';
|
|
12164
|
+
}>;
|
|
12165
|
+
type V3InitializedPreflightSummary = Extract<V3PreflightSummary, {
|
|
12166
|
+
status: 'initialized';
|
|
12167
|
+
}>;
|
|
12168
|
+
type PreparedV3CreatePoolAction = PreparedPoolAction<'v3-create', V3CreatePoolIdentity, V3CreateExpectation, V3AbsentPreflightSummary> & {
|
|
12169
|
+
readonly preflight: V3AbsentPreflightSummary;
|
|
12170
|
+
};
|
|
12171
|
+
type PreparedV3InitializePoolAction = PreparedPoolAction<'v3-initialize', V3ExistingPoolIdentity, V3InitializeExpectation, V3UninitializedPreflightSummary> & {
|
|
12172
|
+
readonly preflight: V3UninitializedPreflightSummary;
|
|
12173
|
+
};
|
|
12174
|
+
type PreparedV3CreateAndInitializeAction = PreparedPoolAction<'v3-create-and-initialize', V3PoolIdentity, V3InitializeExpectation, V3AbsentPreflightSummary | V3UninitializedPreflightSummary> & {
|
|
12175
|
+
readonly preflight: V3AbsentPreflightSummary | V3UninitializedPreflightSummary;
|
|
12176
|
+
};
|
|
12177
|
+
type PreparedV3PoolAction = PreparedV3CreatePoolAction | PreparedV3InitializePoolAction | PreparedV3CreateAndInitializeAction;
|
|
12178
|
+
interface V3PoolActionSimulation extends PoolActionSimulation {
|
|
12179
|
+
readonly returnedPoolAddress: Address | null;
|
|
12180
|
+
}
|
|
12181
|
+
interface V3PoolCreatedEvidence {
|
|
12182
|
+
readonly poolAddress: Address;
|
|
12183
|
+
readonly token0: Address;
|
|
12184
|
+
readonly token1: Address;
|
|
12185
|
+
readonly fee: number;
|
|
12186
|
+
readonly tickSpacing: number;
|
|
12187
|
+
readonly logIndex: number;
|
|
12188
|
+
}
|
|
12189
|
+
interface V3PoolInitializedEvidence {
|
|
12190
|
+
readonly poolAddress: Address;
|
|
12191
|
+
readonly sqrtPriceX96: bigint;
|
|
12192
|
+
readonly tick: number;
|
|
12193
|
+
readonly logIndex: number;
|
|
12194
|
+
}
|
|
12195
|
+
interface V3ReceiptEvidence {
|
|
12196
|
+
readonly receiptStatus: 'success' | 'reverted';
|
|
12197
|
+
readonly poolCreated: V3PoolCreatedEvidence | null;
|
|
12198
|
+
readonly initializations: readonly V3PoolInitializedEvidence[];
|
|
12199
|
+
}
|
|
12200
|
+
type V3PoolActionVerification = PoolActionVerification<V3PoolIdentity, V3PoolSnapshot, V3ReceiptEvidence>;
|
|
12201
|
+
/**
|
|
12202
|
+
* Runtime validation for plans crossing JSON, UI/CLI, or signer boundaries.
|
|
12203
|
+
* It re-derives the exact target, value, and calldata from trusted capability
|
|
12204
|
+
* metadata plus the declared kind, key, and expectation.
|
|
12205
|
+
*/
|
|
12206
|
+
declare function validatePreparedV3PoolAction(value: unknown): V3LifecycleDeployment;
|
|
12207
|
+
/** Assertion-form companion for consumers that need TypeScript narrowing. */
|
|
12208
|
+
declare function assertPreparedV3PoolAction(value: unknown): asserts value is PreparedV3PoolAction;
|
|
12209
|
+
/** Deserialize and fully validate a versioned V3 prepared action. */
|
|
12210
|
+
declare function deserializePreparedV3PoolAction(serialized: string): PreparedV3PoolAction;
|
|
12211
|
+
//#endregion
|
|
12212
|
+
//#region src/pool-lifecycle/v3/key.d.ts
|
|
12213
|
+
/** Validate and canonicalize a V3 key without assuming a hard-coded fee tier. */
|
|
12214
|
+
declare function canonicalizeV3PoolKey(input: V3PoolKeyInput): V3PoolKey;
|
|
12215
|
+
/** Ensure an initial price is bound to the same canonical token pair as a V3 key. */
|
|
12216
|
+
declare function assertV3InitialPrice(key: V3PoolKey, price: V3InitialPrice): V3InitialPrice;
|
|
12217
|
+
//#endregion
|
|
12218
|
+
//#region src/pool-lifecycle/v3/inspect.d.ts
|
|
12219
|
+
interface InspectV3PoolParams {
|
|
12220
|
+
publicClient: PublicClient;
|
|
12221
|
+
deployment: V3LifecycleDeployment;
|
|
12222
|
+
key: V3PoolKeyInput;
|
|
12223
|
+
blockNumber?: bigint;
|
|
12224
|
+
}
|
|
12225
|
+
/**
|
|
12226
|
+
* Read a block-consistent V3 deployment and pool snapshot before building or
|
|
12227
|
+
* verifying a lifecycle transaction.
|
|
12228
|
+
*/
|
|
12229
|
+
declare function inspectV3Pool(params: InspectV3PoolParams): Promise<V3PoolSnapshot>;
|
|
12230
|
+
//#endregion
|
|
12231
|
+
//#region src/pool-lifecycle/v3/actions.d.ts
|
|
12232
|
+
interface V3BuildBaseParams {
|
|
12233
|
+
deployment: V3LifecycleDeployment;
|
|
12234
|
+
key: V3PoolKeyInput;
|
|
12235
|
+
}
|
|
12236
|
+
interface BuildV3CreatePoolTransactionParams extends V3BuildBaseParams {
|
|
12237
|
+
readonly preflight: V3AbsentPoolSnapshot;
|
|
12238
|
+
}
|
|
12239
|
+
interface BuildV3InitializePoolTransactionParams extends V3BuildBaseParams {
|
|
12240
|
+
readonly preflight: V3UninitializedPoolSnapshot;
|
|
12241
|
+
readonly initialPrice: V3InitialPrice;
|
|
12242
|
+
}
|
|
12243
|
+
interface BuildV3CreateAndInitializeTransactionParams extends Omit<V3BuildBaseParams, 'deployment'> {
|
|
12244
|
+
readonly deployment: V3AtomicLifecycleDeployment;
|
|
12245
|
+
readonly preflight: V3AbsentPoolSnapshot | V3UninitializedPoolSnapshot;
|
|
12246
|
+
readonly initialPrice: V3InitialPrice;
|
|
12247
|
+
}
|
|
12248
|
+
interface PrepareV3CreateAndInitializeParams extends Omit<InspectV3PoolParams, 'deployment' | 'blockNumber'> {
|
|
12249
|
+
readonly deployment: V3AtomicLifecycleDeployment;
|
|
12250
|
+
initialPrice: V3InitialPrice;
|
|
12251
|
+
blockNumber?: bigint;
|
|
12252
|
+
}
|
|
12253
|
+
interface PrepareV3CreatePoolParams extends Omit<InspectV3PoolParams, 'blockNumber'> {
|
|
12254
|
+
blockNumber?: bigint;
|
|
12255
|
+
}
|
|
12256
|
+
interface PrepareV3InitializePoolParams extends Omit<InspectV3PoolParams, 'blockNumber'> {
|
|
12257
|
+
initialPrice: V3InitialPrice;
|
|
12258
|
+
blockNumber?: bigint;
|
|
12259
|
+
}
|
|
12260
|
+
type PrepareV3CreateAndInitializeResult = {
|
|
12261
|
+
readonly status: 'ready';
|
|
12262
|
+
readonly snapshot: V3PoolSnapshot;
|
|
12263
|
+
readonly action: PreparedV3CreateAndInitializeAction;
|
|
12264
|
+
} | {
|
|
12265
|
+
readonly status: 'already-initialized-matching';
|
|
12266
|
+
readonly snapshot: V3PoolSnapshot;
|
|
12267
|
+
readonly action: null;
|
|
12268
|
+
};
|
|
12269
|
+
type PrepareV3CreatePoolResult = {
|
|
12270
|
+
readonly status: 'ready';
|
|
12271
|
+
readonly snapshot: V3PoolSnapshot;
|
|
12272
|
+
readonly action: PreparedV3CreatePoolAction;
|
|
12273
|
+
} | {
|
|
12274
|
+
readonly status: 'already-exists';
|
|
12275
|
+
readonly snapshot: Exclude<V3PoolSnapshot, {
|
|
12276
|
+
status: 'absent';
|
|
12277
|
+
}>;
|
|
12278
|
+
readonly action: null;
|
|
12279
|
+
};
|
|
12280
|
+
type PrepareV3InitializePoolResult = {
|
|
12281
|
+
readonly status: 'ready';
|
|
12282
|
+
readonly snapshot: V3UninitializedPoolSnapshot;
|
|
12283
|
+
readonly action: PreparedV3InitializePoolAction;
|
|
12284
|
+
} | {
|
|
12285
|
+
readonly status: 'already-initialized-matching';
|
|
12286
|
+
readonly snapshot: Extract<V3PoolSnapshot, {
|
|
12287
|
+
status: 'initialized';
|
|
12288
|
+
}>;
|
|
12289
|
+
readonly action: null;
|
|
12290
|
+
};
|
|
12291
|
+
/** Build the low-level V3 factory create transaction without signing it. */
|
|
12292
|
+
declare function buildV3CreatePoolTransaction(params: BuildV3CreatePoolTransactionParams): PreparedV3CreatePoolAction;
|
|
12293
|
+
/** Build a direct one-time V3 pool initialize transaction without signing it. */
|
|
12294
|
+
declare function buildV3InitializePoolTransaction(params: BuildV3InitializePoolTransactionParams): PreparedV3InitializePoolAction;
|
|
12295
|
+
/** Build the canonical atomic create-and-initialize V3 periphery transaction. */
|
|
12296
|
+
declare function buildV3CreateAndInitializeTransaction(params: BuildV3CreateAndInitializeTransactionParams): PreparedV3CreateAndInitializeAction;
|
|
12297
|
+
/**
|
|
12298
|
+
* Prepare only the factory-creation step. This is the first stage for
|
|
12299
|
+
* deployments without a configured atomic initializer and deliberately does
|
|
12300
|
+
* not claim that the irreversible initial price has been set.
|
|
12301
|
+
*/
|
|
12302
|
+
declare function prepareV3CreatePool(params: PrepareV3CreatePoolParams): Promise<PrepareV3CreatePoolResult>;
|
|
12303
|
+
/**
|
|
12304
|
+
* Prepare only the direct, one-time pool initialization step. Callers using a
|
|
12305
|
+
* factory-only deployment must mine and verify creation, re-inspect the pool,
|
|
12306
|
+
* and then call this function; the SDK does not conceal the intervening race.
|
|
12307
|
+
*/
|
|
12308
|
+
declare function prepareV3InitializePool(params: PrepareV3InitializePoolParams): Promise<PrepareV3InitializePoolResult>;
|
|
12309
|
+
/**
|
|
12310
|
+
* Safe default preparation flow for UI and CLI consumers. It returns no
|
|
12311
|
+
* transaction for an already initialized pool only when the exact price
|
|
12312
|
+
* matches, and rejects a conflicting existing price.
|
|
12313
|
+
*/
|
|
12314
|
+
declare function prepareV3CreateAndInitialize(params: PrepareV3CreateAndInitializeParams): Promise<PrepareV3CreateAndInitializeResult>;
|
|
12315
|
+
//#endregion
|
|
12316
|
+
//#region src/pool-lifecycle/v3/simulate.d.ts
|
|
12317
|
+
interface SimulateV3PoolActionParams {
|
|
12318
|
+
publicClient: PublicClient;
|
|
12319
|
+
account: Address;
|
|
12320
|
+
action: PreparedV3PoolAction;
|
|
12321
|
+
/** Defaults to the current block. Historical simulation must be explicit. */
|
|
12322
|
+
blockNumber?: bigint;
|
|
12323
|
+
}
|
|
12324
|
+
/** Simulate and estimate a prepared action with the exact eventual sender. */
|
|
12325
|
+
declare function simulateV3PoolAction(params: SimulateV3PoolActionParams): Promise<V3PoolActionSimulation>;
|
|
12326
|
+
//#endregion
|
|
12327
|
+
//#region src/pool-lifecycle/v3/verify.d.ts
|
|
12328
|
+
interface VerifyV3PoolActionParams {
|
|
12329
|
+
publicClient: PublicClient;
|
|
12330
|
+
action: PreparedV3PoolAction;
|
|
12331
|
+
receipt: TransactionReceipt;
|
|
12332
|
+
}
|
|
12333
|
+
/** Decode receipt evidence without making any RPC reads. */
|
|
12334
|
+
declare function decodeV3PoolActionReceipt(action: PreparedV3PoolAction, receipt: TransactionReceipt): V3ReceiptEvidence;
|
|
12335
|
+
/** Compose receipt decoding with receipt-block deployment and state verification. */
|
|
12336
|
+
declare function verifyV3PoolAction(params: VerifyV3PoolActionParams): Promise<V3PoolActionVerification>;
|
|
12337
|
+
//#endregion
|
|
12338
|
+
//#region src/pool-lifecycle/v4/key.d.ts
|
|
12339
|
+
declare const V4_DYNAMIC_FEE_FLAG = 8388608;
|
|
12340
|
+
declare const V4_MAX_STATIC_FEE = 1000000;
|
|
12341
|
+
declare const V4_MAX_TICK_SPACING = 32767;
|
|
12342
|
+
declare const V4_ALL_HOOK_MASK: bigint;
|
|
12343
|
+
declare const V4_ZERO_ADDRESS: `0x${string}`;
|
|
12344
|
+
/** Validate a complete PoolKey whose currencies are already canonically ordered. */
|
|
12345
|
+
declare function validateV4PoolKey(value: V4PoolKey): V4PoolKey;
|
|
12346
|
+
/**
|
|
12347
|
+
* Validate and sort two currencies. Address zero is deliberately accepted and
|
|
12348
|
+
* sorts first because V4 represents the native currency as address(0).
|
|
12349
|
+
*/
|
|
12350
|
+
declare function canonicalizeV4PoolKey(value: V4PoolKeyInput): V4PoolKey;
|
|
12351
|
+
/** Return the exact PoolId used by PoolIdLibrary.toId. */
|
|
12352
|
+
declare function getV4PoolId(key: V4PoolKey): Hex;
|
|
12353
|
+
declare function v4PoolKeysEqual(left: V4PoolKey, right: V4PoolKey): boolean;
|
|
12354
|
+
/** Validate price bounds and bind the price to the canonical PoolKey order. */
|
|
12355
|
+
declare function assertV4InitialPrice(key: V4PoolKey, value: V4InitialPrice): V4InitialPrice;
|
|
12356
|
+
//#endregion
|
|
12357
|
+
//#region src/pool-lifecycle/v4/inspect.d.ts
|
|
12358
|
+
interface InspectV4PoolParams {
|
|
12359
|
+
readonly publicClient: PublicClient;
|
|
12360
|
+
readonly deployment: V4LifecycleDeployment;
|
|
12361
|
+
readonly key: V4PoolKeyInput;
|
|
12362
|
+
readonly blockNumber?: bigint;
|
|
12363
|
+
}
|
|
12364
|
+
/** Read PoolManager identity and pool state at one pinned block. */
|
|
12365
|
+
declare function inspectV4Pool(params: InspectV4PoolParams): Promise<V4PoolSnapshot>;
|
|
12366
|
+
//#endregion
|
|
12367
|
+
//#region src/pool-lifecycle/v4/actions.d.ts
|
|
12368
|
+
interface BuildV4InitializePoolTransactionParams {
|
|
12369
|
+
readonly deployment: V4LifecycleDeployment;
|
|
12370
|
+
readonly key: V4PoolKeyInput;
|
|
12371
|
+
readonly initialPrice: V4InitialPrice;
|
|
12372
|
+
readonly preflight: V4UninitializedPoolSnapshot;
|
|
12373
|
+
}
|
|
12374
|
+
interface PrepareV4InitializeParams extends Omit<InspectV4PoolParams, 'blockNumber'> {
|
|
12375
|
+
readonly initialPrice: V4InitialPrice;
|
|
12376
|
+
readonly blockNumber?: bigint;
|
|
12377
|
+
}
|
|
12378
|
+
type PrepareV4InitializeResult = {
|
|
12379
|
+
readonly status: 'ready';
|
|
12380
|
+
readonly snapshot: V4UninitializedPoolSnapshot;
|
|
12381
|
+
readonly action: PreparedV4InitializePoolAction;
|
|
12382
|
+
} | {
|
|
12383
|
+
readonly status: 'already-initialized-matching';
|
|
12384
|
+
readonly snapshot: V4InitializedPoolSnapshot;
|
|
12385
|
+
readonly action: null;
|
|
12386
|
+
};
|
|
12387
|
+
/** Build a direct PoolManager.initialize transaction without signing it. */
|
|
12388
|
+
declare function buildV4InitializePoolTransaction(params: BuildV4InitializePoolTransactionParams): PreparedV4InitializePoolAction;
|
|
12389
|
+
/** Inspect first, then return either a safe unsigned plan or a matching no-op. */
|
|
12390
|
+
declare function prepareV4Initialize(params: PrepareV4InitializeParams): Promise<PrepareV4InitializeResult>;
|
|
12391
|
+
//#endregion
|
|
12392
|
+
//#region src/pool-lifecycle/v4/integrity.d.ts
|
|
12393
|
+
/**
|
|
12394
|
+
* Fully validate a signer-boundary V4 action and return its canonical frozen
|
|
12395
|
+
* capability. The target, value, PoolId, and calldata are all re-derived.
|
|
12396
|
+
*/
|
|
12397
|
+
declare function validatePreparedV4PoolAction(value: unknown): V4LifecycleDeployment;
|
|
12398
|
+
declare function assertPreparedV4PoolAction(value: unknown): asserts value is PreparedV4PoolAction;
|
|
12399
|
+
/** Deserialize the shared versioned envelope, then perform adapter validation. */
|
|
12400
|
+
declare function deserializePreparedV4PoolAction(serialized: string): PreparedV4PoolAction;
|
|
12401
|
+
//#endregion
|
|
12402
|
+
//#region src/pool-lifecycle/v4/simulate.d.ts
|
|
12403
|
+
interface SimulateV4PoolActionParams {
|
|
12404
|
+
readonly publicClient: PublicClient;
|
|
12405
|
+
readonly account: Address;
|
|
12406
|
+
readonly action: PreparedV4PoolAction;
|
|
12407
|
+
/** Defaults to fresh state; historical simulation must be explicit. */
|
|
12408
|
+
readonly blockNumber?: bigint;
|
|
12409
|
+
}
|
|
12410
|
+
/** Re-inspect, call, and estimate with the exact eventual sender and envelope. */
|
|
12411
|
+
declare function simulateV4PoolAction(params: SimulateV4PoolActionParams): Promise<V4PoolActionSimulation>;
|
|
12412
|
+
//#endregion
|
|
12413
|
+
//#region src/pool-lifecycle/v4/verify.d.ts
|
|
12414
|
+
interface VerifyV4PoolActionParams {
|
|
12415
|
+
readonly publicClient: PublicClient;
|
|
12416
|
+
readonly action: PreparedV4PoolAction;
|
|
12417
|
+
readonly receipt: TransactionReceipt;
|
|
12418
|
+
}
|
|
12419
|
+
/** Decode transaction-attributed PoolManager Initialize evidence without RPC reads. */
|
|
12420
|
+
declare function decodeV4PoolActionReceipt(action: PreparedV4PoolAction, receipt: TransactionReceipt): V4ReceiptEvidence;
|
|
12421
|
+
/** Verify exact calldata, canonical receipt/event, and receipt-block StateView state. */
|
|
12422
|
+
declare function verifyV4PoolAction(params: VerifyV4PoolActionParams): Promise<V4PoolActionVerification>;
|
|
12423
|
+
//#endregion
|
|
12424
|
+
export { AERODROME_PROTOCOLS, ALGEBRA_INTEGRAL_PROTOCOLS, ALGEBRA_INTEGRAL_V_2_0_PROTOCOLS, ALGEBRA_LIFECYCLE_DEPLOYMENTS, ALGEBRA_PROTOCOLS, AMMConfigType, AMMType, API_URLS, AlgebgraHookBeacons, AlgebraInitialPrice, AlgebraIntegral21QuoteParams, AlgebraLifecycleAdapter, AlgebraLifecycleDeployment, AlgebraLifecycleProvenance, AlgebraLifecycleVariant, AlgebraPoolActionSimulation, AlgebraPoolActionVerification, AlgebraPoolIdentity, AlgebraPoolKey, AlgebraPoolKeyInput, AlgebraPoolSnapshot, AlgebraPreflightSummary, AlgebraQuoteParams, AlgebraReceiptEvidence, AlgebraVaultDetails, ApiPageInfo, ApiVaultFilter, AprFilter, AprResponse, BaseQuoteParams, BaseVaultDetails, BlackholeAprDetailedParams, BlackholeAprDetailedResponse, BlackholeSnapshotAnalysis, BuildAlgebraCreatePoolTransactionParams, BuildAlgebraInitializePoolTransactionParams, BuildV3CreateAndInitializeTransactionParams, BuildV3CreatePoolTransactionParams, BuildV3InitializePoolTransactionParams, BuildV4InitializePoolTransactionParams, CURRENT_V4_LIFECYCLE_DEPLOYMENTS, CalculateLimitPriceParams, CalculateSwapAmountParams, CanonicalCurrencyInitialPrice, CanonicalCurrencyPair, CanonicalErc20Pair, CanonicalInitialPrice, Chain, ChainId, ClaimProofEdge, ClaimProofNode, ClaimProofsPageInfo, ClaimProofsResponse, ClaimRewardEdge, ClaimRewardNode, ClaimRewardParams, ClaimRewardsConnection, ClaimRewardsParams, Contract, ContractAddresses, ContractName, DIRECTIONAL_ALGEBRA_PROTOCOLS, DefaultFeeManagerConfigParams, DeprecationData, EncodedEvmTransaction, EstimateLpTokensParams, ExactCurrencyPrice, ExactFraction, ExactPrice, FEE_MANAGER_ABI, Fee, FeeManagerClient, FeeManagerConfigParams, FeeWithdrawalParams, FormattedRoute, GetRewardParams, GetSupportedChainsOptions, GetVaultExecutionContextParams, GlobalStateABI, type GraphQLPoolData, type GraphQLTokenData, InspectAlgebraCustomPoolEntryPointParams, InspectAlgebraPoolParams, InspectV3PoolParams, InspectV4PoolParams, LimitPoolState, LpPriceResponse, LpTokenEstimationResponse, MAX_SQRT_RATIO, MIN_SQRT_RATIO, MultiPositionManagers, MultiVaultFeeWithdrawalParams, MultipleFeeWithdrawalParams, NetworkConfig, NetworkData, Networks, POOLSHARK_PROTOCOLS, POOL_LIFECYCLE_DEPLOYMENTS, PREPARED_POOL_ACTION_SERIALIZATION_VERSION, PageInfo, PendingRewardsParams, PendingRewardsResponse, PoolActionOutcome, PoolActionSimulation, PoolActionVerification, PoolClient, PoolData, PoolEdge, PoolFilter, PoolLifecycleDeploymentRegistry, PoolLifecycleDeploymentResult, PoolLifecycleError, PoolLifecycleErrorCode, PoolNode, PoolSharkGlobalState, PoolSlot0, PoolsConnection, PoolsharkStructs, PrepareAlgebraPoolResult, PrepareV3CreateAndInitializeParams, PrepareV3CreateAndInitializeResult, PrepareV3CreatePoolParams, PrepareV3CreatePoolResult, PrepareV3InitializePoolParams, PrepareV3InitializePoolResult, PrepareV4InitializeParams, PrepareV4InitializeResult, PreparedAlgebraCreatePoolAction, PreparedAlgebraInitializePoolAction, PreparedAlgebraPoolAction, PreparedPoolAction, PreparedV3CreateAndInitializeAction, PreparedV3CreatePoolAction, PreparedV3InitializePoolAction, PreparedV3PoolAction, PreparedV4InitializePoolAction, PreparedV4PoolAction, Protocol, ProtocolContractAddresses, ProtocolDetails, ProtocolInfo, QuickSwapQuoterV2, QuoteParams, QuoterFunctionArgs, QuoterV2ABI, QuoterV2AlgebgraIntegral, QuoterV2AlgebgraIntegral21, QuoterV2Factory, QuoterV2Shadow, QuoterV2Thick, ResolvePoolLifecycleDeploymentParams, ResolveV3LifecycleDeploymentParams, ResolveV4LifecycleDeploymentParams, Reward, RewardBalance, RewardSummary, RouteShortcut, SHADOW_PROTOCOLS, ShadowQuoteParams, SimulateAlgebraPoolActionParams, SimulateSwapParams, SimulateV3PoolActionParams, SimulateV4PoolActionParams, SingleAssetDepositClient, SingleAssetDepositParams, SingleAssetDepositPreview, Slot0, SmartRewarderContract, SmartRewards, StabilityVaultInfo, StakeParams, Staking, StakingClient, StakingPool, StakingPoolFilter, StakingProtocol, SteerClient, SteerConfig, SteerResponse, SteerSupportedChains, StrykePositionManagers, SubgraphClient, SubgraphResponse, SubgraphVaultClient, SubgraphVaultDetails, SubgraphVaultDetailsWithLpData, SubgraphVaultPosition, SupportedChain, SupportedChainFeatures, SupportedChainsFeature, SupportedChainsInclude, SupportedPoolLifecycleDeployment, SupportedProtocol, SwapAmountResponse, SwapSimulationResponse, TEST_UNISWAP_JIT_HOOK_BEACON, ThickQuoteParams, Token0, Token1, TokenData, TokenEdge, TokenFilter, TokenNode, TokenValueParams, TokenValueResponse, TokensConnection, UNISWAP_V4_BEACON_NAMES, UNISWAP_V4_HOOK_BEACON_NAMES, UNISWAP_V4_NO_ORACLE_BEACON, UniswapHookBeacons, UniswapQuoteParams, UniswapV3PoolABI, UniswapV3QuoterABI, UniswapV4Beacons, UnsupportedPoolLifecycleDeployment, V3AbsentPoolSnapshot, V3AbsentPreflightSummary, V3AtomicLifecycleDeployment, V3CreateExpectation, V3CreatePoolIdentity, V3ExistingPoolIdentity, V3ExistingPoolSnapshot, V3FactoryLifecycleDeployment, V3InitialPrice, V3InitializeExpectation, V3InitializedPoolSnapshot, V3InitializedPreflightSummary, V3LifecycleDeployment, V3LifecycleDeploymentProvenance, V3PoolActionKind, V3PoolActionSimulation, V3PoolActionVerification, V3PoolCreatedEvidence, V3PoolIdentity, V3PoolInitializedEvidence, V3PoolKey, V3PoolKeyInput, V3PoolSnapshot, V3PoolStatus, V3PreflightSummary, V3ReceiptEvidence, V3UninitializedPoolSnapshot, V3UninitializedPreflightSummary, V3_CONFIG_PROTOCOLS, V3_LIFECYCLE_DEPLOYMENTS, V4InitialPrice, V4InitializeEvidence, V4InitializeExpectation, V4InitializedPoolSnapshot, V4LifecycleDeployment, V4LifecycleDeploymentByIdRegistry, V4LifecycleDeploymentId, V4LifecycleDeploymentProvenance, V4PoolActionSimulation, V4PoolActionVerification, V4PoolIdentity, V4PoolKey, V4PoolKeyInput, V4PoolSnapshot, V4ReceiptEvidence, V4UninitializedPoolSnapshot, V4UninitializedPreflightSummary, V4_ALL_HOOK_MASK, V4_DYNAMIC_FEE_FLAG, V4_LIFECYCLE_DEPLOYMENTS, V4_LIFECYCLE_DEPLOYMENTS_BY_ID, V4_MAX_STATIC_FEE, V4_MAX_TICK_SPACING, V4_ZERO_ADDRESS, VAULT_FEES_ABI, VaultAllowanceParams, VaultApproveParams, VaultApr, VaultBalanceParams, VaultClient, VaultDetails, VaultDetailsResponse, VaultEdge, VaultExecutionContext, VaultExecutionDataProvenance, VaultExecutionPoolFamily, VaultExecutionPoolKey, VaultExecutionPosition, VaultFetchOptions, VaultFilter, VaultNode, VaultTokens, VaultsConnection, VerifyAlgebraPoolActionParams, VerifyV3PoolActionParams, VerifyV4PoolActionParams, WithdrawParams, abis, algebraCustomPoolEntryPointAbi, algebraDirectionalPoolStateAbi, algebraIntegralPairFactoryAbi, algebraIntegralPluginDataFactoryAbi, algebraIntegralPoolStateAbi, algebraLegacyPoolStateAbi, algebraPairFactoryAbi, algebraPoolBaseAbi, apechainAddresses, arbitrumAddresses, arbitrumgoerliAddresses, arthswapConfig, assertAlgebraInitialPrice, assertPreparedV3PoolAction, assertPreparedV4PoolAction, assertV3InitialPrice, assertV4InitialPrice, astarAddresses, astarzkevmAddresses, avalancheAddresses, bartiotestAddresses, baseAddresses, baseSwapConfig, basexConfig, beraAddresses, bittensorAddresses, bittensorUniV3Config, blastAddresses, bscAddresses, buildAlgebraCreatePoolTransaction, buildAlgebraInitializePoolTransaction, buildV3CreateAndInitializeTransaction, buildV3CreatePoolTransaction, buildV3InitializePoolTransaction, buildV4InitializePoolTransaction, calculateLimitPrice, calculateSwapAmount, camelotConfig, canonicalizeAlgebraPoolKey, canonicalizeV3PoolKey, canonicalizeV4PoolKey, celoAddresses, chainIdToName, chainNameToId, crustConfig, decodeAlgebraPoolActionReceipt, decodeV3PoolActionReceipt, decodeV4PoolActionReceipt, deprecatedBundlesURL, deserializePreparedAlgebraPoolAction, deserializePreparedPoolAction, deserializePreparedV3PoolAction, deserializePreparedV4PoolAction, determineSwapDirection, encodeCurrencyInitialSqrtPriceX96, encodeInitialSqrtPriceX96, encodeSqrtRatioX96, equilibreConfig, erc1155Abi, erc20Abi, erc721Abi, estimateLpTokens, ethAddresses, evmosAddresses, fantomAddresses, fenixConfig, filecoinAddresses, flareAddresses, forgeConfig, fusionxConfig, getAmmConfig, getAmmConfigByChainId, getApiUrl, getBeaconNameByProtocol, getContractAddressByChainIdAndContractName, getExpectedParamType, getFactoryAddress, getInitCodeHash, getNFTManagerAddress, getNetworkByChainId, getPoolHelperByChainId, getPoolSlot0, getProtcolTypeByAmmType, getProtocolBySubgraph, getProtocolConfigByBeacon, getProtocolContractAddresses, getProtocolInfoByChainId, getProtocolInfoByName, getProtocolSubgraphURL, getProtocolTypeByBeacon, getProtocolsForChainId, getQuoterV2Address, getStabilityVaultsPeripheryAddress, getStabilityVaultsSubgraphUrl, getSubgraphUrlByChainId, getSupportedChainByChainId, getSupportedChainIds, getSupportedChains, getSwapRouterAddress, getTheGraphResolverUrl, getTickLensAddress, getUniswapV4BeaconSupportedChains, getV4LifecycleDeploymentId, getV4PoolId, getVaultExecutionContext, getVaultReserves, glyphConfig, goerliAddresses, hemiAddresses, henjinConfig, herculesConfig, horizaConfig, inspectAlgebraCustomPoolEntryPoint, inspectAlgebraPool, inspectV3Pool, inspectV4Pool, integerSqrt, isAerodromeVault, isAlgebraDirectionProtocol, isAlgebraIntegral21QuoteParams, isAlgebraIntegralProtocol, isAlgebraIntegralV2Protocol, isAlgebraProtocol, isAlgebraProtocolBySubgraph, isAlgebraQuoteParams, isPoolSharkProtocol, isShadowProtocol, isShadowQuoteParams, isSingleAssetDepositSupported, isThickQuoteParams, isThickV2Protocol, isUniswapQuoteParams, isUniswapV4Beacon, isUniswapV4BeaconAvailableOnChain, isUniswapV4HookBeacon, isValidStakingProtocol, katanaAddresses, katanaConfig, kavaAddresses, kimConfig, kinetixConfig, lineaAddresses, linehubConfig, localhostAddresses, lynexConfig, maiaConfig, mantaAddresses, mantleAddresses, metaVaultConfig, metisAddresses, modeAddresses, moonbeamAddresses, mumbaiAddresses, nestVaultConfig, networks, normalizeProtocol, novaswapConfig, okxtestnetAddresses, optimismAddresses, optimismgoerliAddresses, pancakeSwapConfig, parseExactDecimal, polygonAddresses, polyzkevmAddresses, poolsharkConfig, prepareAlgebraPool, prepareV3CreateAndInitialize, prepareV3CreatePool, prepareV3InitializePool, prepareV4Initialize, quickSwapAlgebraConfig, quickSwapConfig, quickSwapIntegralConfig, quickSwapUniv3Config, resolveAlgebraLifecycleDeployment, resolveCurrentV4LifecycleDeployment, resolvePoolLifecycleDeployment, resolveV3LifecycleDeployment, resolveV4LifecycleDeployment, resolveV4LifecycleDeploymentById, retroConfig, robinhoodAddresses, rootstockAddresses, sagaAddresses, scrollAddresses, seiAddresses, serializePreparedPoolAction, shadowConfig, shouldValidateUniswapV4VaultHook, simulateAlgebraPoolAction, simulateSwap, simulateV3PoolAction, simulateV4PoolAction, singleTokenDepositAbi, soneiumAddresses, sonicAddresses, sortErc20Pair, sortEvmCurrencyPair, spark32Config, sparkConfig, stabilityVaultsConfig, steerSubgraphConfig, supswapConfig, sushiConfig, swapmodeConfig, swapsicleConfig, taikoAddresses, telosAddresses, thenaConfig, thickConfig, thrusterConfig, thundercoreAddresses, uniAddresses, uniswapConfig, v3FactoryAbi, v3PoolAbi, v3PoolInitializerAbi, v4PoolKeysEqual, v4PoolManagerAbi, v4StateViewAbi, validateAlgebraLifecycleDeployment, validatePreparedAlgebraPoolAction, validatePreparedV3PoolAction, validatePreparedV4PoolAction, validateQuoteParams, validateSqrtPriceX96, validateSwapParams, validateV4LifecycleDeployment, validateV4PoolKey, verifyAlgebraPoolAction, verifyV3PoolAction, verifyV4PoolAction, xlayerAddresses, zetaAddresses, zircuitAddresses };
|
|
10766
12425
|
//# sourceMappingURL=index.d.mts.map
|