import type { Address } from 'viem'; /** * Currency type - address(0) represents native token */ export type Currency = Address; /** * Pool key uniquely identifies a pool */ export interface PoolKey { currency0: Currency; currency1: Currency; fee: number; tickSpacing: number; hooks: Address; } /** * Balance delta represents changes in token balances * Positive = user owes pool, Negative = pool owes user */ export interface BalanceDelta { amount0: bigint; amount1: bigint; } /** * Swap parameters */ export interface SwapParams { zeroForOne: boolean; amountSpecified: bigint; sqrtPriceLimitX96: bigint; } /** * Modify liquidity parameters */ export interface ModifyLiquidityParams { tickLower: number; tickUpper: number; liquidityDelta: bigint; salt: `0x${string}`; } /** * Pool slot0 state */ export interface Slot0 { sqrtPriceX96: bigint; tick: number; protocolFee: number; lpFee: number; } /** * Fee tiers (in hundredths of a bip) */ export declare const FEE_TIERS: { readonly LOWEST: 100; readonly LOW: 500; readonly MEDIUM: 3000; readonly HIGH: 10000; }; /** * Tick spacing for fee tiers */ export declare const TICK_SPACINGS: Record; /** * Native currency constant */ export declare const NATIVE_CURRENCY: Currency; /** * Check if currency is native */ export declare function isNativeCurrency(currency: Currency): boolean; /** * DEX backend kind — selects which contracts the swap router targets. * * v4 — PoolManager precompile (0x0400). Singleton manager, * hooks per pool, native currency, flash accounting. * Cheapest gas. Default for chains that ship the precompile. * v3 — Concentrated liquidity (factory + non-fungible position * manager + swap router). Use for chains that don't have * the precompile (Ethereum mainnet, Arbitrum, etc.). * v2 — Constant-product (factory + router). Fallback for * long-tail pools that haven't migrated. * precompile — Alias of v4 (kept for back-compat). * gateway — Off-chain gateway URL that internally layers * v4 → v3 → v2 → cross-chain routing and returns the best * path. Default for whitelabels. */ export type DexBackend = { kind: 'v4'; chainId?: number; } | { kind: 'v3'; chainId?: number; } | { kind: 'v2'; chainId?: number; } | { kind: 'precompile'; chainId?: number; } | { kind: 'gateway'; url: string; }; /** * V4 hook permissions — bitfield of which lifecycle hooks the contract implements. * Set on the hook address itself per Uniswap V4 hook-permission encoding scheme. */ export interface HookPermissions { beforeInitialize: boolean; afterInitialize: boolean; beforeAddLiquidity: boolean; afterAddLiquidity: boolean; beforeRemoveLiquidity: boolean; afterRemoveLiquidity: boolean; beforeSwap: boolean; afterSwap: boolean; beforeDonate: boolean; afterDonate: boolean; beforeSwapReturnDelta: boolean; afterSwapReturnDelta: boolean; afterAddLiquidityReturnDelta: boolean; afterRemoveLiquidityReturnDelta: boolean; } /** Empty pool — no hook contract attached. */ export declare const NO_HOOKS: Address; //# sourceMappingURL=types.d.ts.map