/** * Thrown by {@link ControllerEVMWalletClient} before a transaction is * handed off to the controller for signing/broadcast (BYOK) or to the * remote signing service (server mode) when the sender's native balance * cannot cover `value + gas * feePerGas`. * * The upstream `TransactionController` swallows `eth_estimateGas` * failures (including insufficient-funds errors) and substitutes ~95% of * the block gas limit as a safe fallback so the MetaMask extension UI can * still show a "proceed anyway" warning. fox-sdk has no human gate, so we * surface the failure here as a typed error instead of silently * forwarding a doomed transaction. * * Carries the raw wei numbers so the CLI / agent can render a precise * message without re-fetching balance. */ export declare class InsufficientNativeFundsError extends Error { readonly account: string; readonly balance: bigint; readonly required: bigint; readonly value: bigint; readonly gas: bigint; readonly feePerGas: bigint; constructor(args: { account: string; balance: bigint; required: bigint; value: bigint; gas: bigint; feePerGas: bigint; }); } /** * Thrown by {@link EVMWalletClient.sendToken} before the ERC-20 `transfer` * is signed or broadcast when the sender's on-chain token balance is below * the requested transfer amount. * * Sibling to {@link InsufficientNativeFundsError}: that one guards * `value + gas * feePerGas` against the native balance for every tx; this * one guards `amount` against the ERC-20 balance for token transfers * specifically, since the controller / RPC have no way to surface an * ERC-20 shortfall pre-broadcast (it would only manifest as an on-chain * revert after the tx is mined). * * The error carries raw `bigint`s plus the token address so the catcher * (CLI, agent tool, plugin) can format with whatever decimals / symbol it * already has cached — avoids paying a metadata round-trip on the hot path. */ export declare class InsufficientTokenBalanceError extends Error { readonly account: string; readonly token: string; readonly balance: bigint; readonly required: bigint; constructor(args: { account: string; token: string; balance: bigint; required: bigint; }); }