Skip to main content
Commands use this general pattern:
Commands that accept --chain default to base unless documented otherwise.

quote — Price Quotes (No Auth)

Get a swap price without a wallet, a session, or any setup. It is the fastest pricing entry point for trying FibX or answering a question before a user has logged in. Other public or local commands, including status, tx-status, config, and aave markets, also work without an active session.

Examples

For routed swaps, the output shows the input and output amounts, exchange rate, slippage, router, and chain. A direct native/wrapped-native pair instead reports a 1:1 wrap or unwrap operation without slippage or router fields. To execute the same trade, use trade with the same arguments once authenticated.

auth — Authentication

Manage the wallet session. Authentication is required before commands that inspect or act on a wallet.

auth import

Import an existing private key to create a local wallet session. This is the most direct way to authenticate — if you already have a wallet, use this method. The CLI opens an interactive prompt where you paste the key.
The key is encrypted and stored in a local session file. No external server holds your private key with this method.

auth login / auth verify (Email OTP)

Alternative authentication via email OTP. This creates a server-managed wallet through Privy — useful when you do not have an existing private key.

auth logout

End the active session.

status — Session Status

Check whether a session is active and display the authenticated wallet address.

address — Wallet Address

Print the active wallet address.

wallets — Wallet Details

Show the active wallet details for the current session.

portfolio — Cross-Chain Portfolio

View a consolidated portfolio across all supported chains with USD-valued token holdings and DeFi positions.

Examples

The portfolio view aggregates holdings across Base, Citrea, HyperEVM, and Monad. It also includes Aave V3 collateral and debt positions when available.

balance — Check Balances

Fetch native and ERC-20 token balances for the authenticated wallet.

send — Transfer Tokens

Send native tokens or ERC-20 tokens to a recipient address. FibX performs a command-specific preflight before submission.
If token is omitted, the chain’s native token is used (ETH on Base, cBTC on Citrea, HYPE on HyperEVM, MON on Monad).

Examples


trade: Swap Tokens

Exchange one token for another via Fibrous aggregation. The CLI finds a route, handles token approvals, estimates the main swap path, and submits it.
The trade command automatically detects Wrap (Native → Wrapped) and Unwrap (Wrapped → Native) operations and executes them directly via contract calls, bypassing the aggregator routing to save gas.
If the source is an ERC-20 token with insufficient allowance, trade --simulate returns requiresApproval: true without submitting an approval. Because the swap cannot be estimated safely in that state, the preview omits the gas estimate.
A live routed ERC-20 trade may confirm an approval transaction before estimating and submitting the swap. If the later swap step fails, that approval remains on-chain. --simulate broadcasts neither transaction.

Examples


aave — Aave V3 (Base Only)

Manage Aave V3 lending positions on Base. Supply assets to earn yield, borrow against collateral, repay debt, or withdraw.
Aave V3 operations always target Base. The global --chain option does not change the Aave network, so omit it for aave commands.

Actions

ETH ↔ WETH Auto-Wrap

For the ETH market, supply and repay can wrap ETH to WETH, while withdraw can unwrap WETH to ETH. Borrowing the ETH market returns WETH; the borrowed asset is not auto-unwrapped.
An Aave --simulate result summarizes the normalized request without broadcasting it. It does not perform on-chain validation, simulate the contract call, or estimate gas.
A live supply or repay may submit wrap and approval transactions before the Aave call. An ETH withdraw submits the Aave withdrawal before a separate unwrap transaction; the reported txHash is the Aave withdrawal hash. If a later step fails, earlier transactions remain on-chain. In particular, aave withdraw max ETH unwraps the wallet’s entire WETH balance after the withdrawal, including WETH held before the command.

Health Factor

Before borrowing, always check aave status. The Health Factor indicates liquidation risk:
  • Above 1.5 — Lower liquidation risk, but not risk-free
  • Between 1.1 and 1.5 — Liquidation risk warning
  • Below 1.1 — High liquidation risk, proceed with extreme caution
max is supported only for repay and withdraw; supply max and borrow max are rejected. Use max when fully repaying debt or withdrawing a supplied position to avoid dust residuals.

config — RPC Configuration

View and modify local fibx CLI configuration. Used primarily to set custom RPC URLs when hitting rate limits on public endpoints.
Configuration is stored in the OS-specific FibX config directory and persists across sessions. Typical paths are ~/.config/fibx-nodejs/config.json on Linux and ~/Library/Preferences/fibx-nodejs/config.json on macOS.

Examples


tx-status — Transaction Status

Check the on-chain status of a transaction and retrieve the block explorer link.
Always use the same --chain flag that was used for the original transaction. A Base transaction hash will not be found on Monad.

JSON Output


Error Reference

Common errors across all commands: