import { ethers } from 'ethers'; import { applySlippageBps } from '../../../core/constants/index.js'; import { type QuoteBNBResult, type QuoteSellParams, type RouteParams, type UserType } from './bundle-swap-types.js'; /** Pancake 买卖 minOut;实现见 core applySlippageBps。 */ export declare const applyPancakeSlippage: typeof applySlippageBps; export declare function splitQuotedMins(quotedTotal: bigint, amounts: bigint[], slippageBps?: number): bigint[]; export declare function isSameWalletBuySell(buyers: Array<{ address: string; }>, sellers: Array<{ address: string; }>): boolean; /** 同钱包无币刷量卖出必须 minOut=0:同块先买后卖,卖出到账必然低于买入报价。 */ export declare function resolveBuyFirstSellMins(sameWallet: boolean, quotedTotal: bigint, sellAmounts: bigint[], slippageBps?: number): bigint[]; export declare function quoteBuyOutput(params: { routeParams: RouteParams; buyAmountWei: bigint; provider: ethers.JsonRpcProvider; v2RouterAddress?: string; }): Promise; export declare function quoteSellOutput({ routeParams, sellAmountWei, provider, v2RouterAddress, }: QuoteSellParams): Promise; /** * 根据 userType 计算利润率 */ export declare function getProfitRateBps(_userType?: UserType): number; export declare function calculateProfitAmount(estimatedBNBOut: bigint, _userType?: UserType): bigint; /** 换手按卖出所得收万六会像万五点多:用所得能买回的数量把计价额抬到买侧。 */ export declare function grossUpPancakeSellProceedsToBuySide(params: { provider: ethers.JsonRpcProvider; tokenAddress: string; sellAmountWei: bigint; sellProceedsWei: bigint; quoteTokenIn: string; version: 'v2' | 'v3'; fee?: number; v2RouterAddress?: string; }): Promise; /** * ✅ 获取 ERC20 代币 → 原生代币(BNB)的报价 * 用于将 ERC20 利润转换为 BNB * 使用共享的报价函数 */ export declare function getERC20ToNativeQuote(provider: ethers.JsonRpcProvider, tokenAddress: string, tokenAmount: bigint, version?: 'v2' | 'v3', fee?: number): Promise;