/** * ClawPay Tiered Fee Structure * * Fee tiers based on transfer amount: * - < $10: 2% (e.g., $0.20 on $10) * - $10-$100: 1% (e.g., $1.00 on $100) * - $100-$1000: 0.5% (e.g., $5.00 on $1000) * - > $1000: 0.25% (e.g., $25 on $10,000) * * b402 uses its own Railgun fork with 0% protocol fees (vs upstream 0.25% each way) */ export interface FeeResult { inputAmount: bigint; feeAmount: bigint; recipientAmount: bigint; feePercent: number; treasuryMPK: string; treasuryVPK: string; } /** * Calculate fee tier based on amount in human-readable USD * @param amountUsd Amount in USD (human-readable, e.g., 100.50) * @returns Fee in basis points (e.g., 100 = 1%) */ export declare function getFeeBasisPoints(amountUsd: number): number; /** * Calculate fee for a transfer * @param amount Amount in wei (bigint) * @param decimals Token decimals (default 18) * @returns Fee calculation result */ export declare function calculateFee(amount: bigint, decimals?: number): FeeResult; /** * Format fee for display * @param feeResult Fee calculation result * @param symbol Token symbol * @param decimals Token decimals */ export declare function formatFee(feeResult: FeeResult, symbol: string, decimals?: number): string; /** * Get fee preview for a given amount (without actual calculation) * Useful for UI display before transaction */ export declare function previewFee(amountUsd: number): { percent: number; estimatedFee: number; }; /** * Check if fee collection is enabled * Can be disabled via environment variable for testing */ export declare function isFeesEnabled(): boolean;