open_fibx tool and pre-filled from the conversation. The model opens it; the user presses Simulate and Swap.
Quick Start
How It Works
- Your AI editor spawns
npx fibx mcp-startas a subprocess. - The editor communicates with FibX over stdin/stdout using JSON-RPC 2.0 messages.
- Wallet-dependent tools read the local session file. Run
fibx auth setup(orauth connect,auth login,auth import) before using those tools, or pair a wallet from inside the app withconnect_wallet; public tools such as quotes, the token list, the policy, and Aave market discovery do not need a session. - Transactional tools execute against live blockchains and carry the MCP
destructiveHintannotation. A client may use that hint to request confirmation, depending on its behavior and configuration. Every transaction also passes the local signing policy before a signature is requested. open_fibxis bound to the resourceui://fibx/app.html. A host that renders MCP Apps shows the app inline and the tool’s JSON result seeds it; a host that does not simply gets the JSON — a complete snapshot of chain, session, balances, policy and quote — and the model reads that instead.
stderr is used for logging, while stdout is reserved for JSON-RPC protocol messages.Editor Setup
Add the FibX MCP server to your AI editor. FibX uses stdio transport — the editor spawnsnpx fibx mcp-start and communicates over standard input/output.
- Cursor
- Claude Desktop
- VS Code
- Windsurf
- Antigravity
- ChatGPT / Others
Open MCP settings with Command + Shift + P and search for “Open MCP settings”. Create or edit Test by asking Cursor: “What tools do you have available?” — it should list the FibX MCP server.
.cursor/mcp.json in your project root:Wallet operations need a session. Create one with
fibx auth setup in a terminal, or — over MCP — with connect_wallet, which pairs your own wallet by QR. The FibX app offers the same pairing from its Connect button.The FibX App
open_fibx is the entry point in any host that renders MCP Apps UI. The
server’s own instructions tell the model so: a question about the wallet, a
balance, a price or a swap opens the whole app, pre-filled with whatever the
conversation supplied — chain, tokens, amount. Inside it:
- the header shows the chain and the connected address, or a Connect button that pairs a wallet by QR;
- two token boxes with balances, a rate chip, and the Fibrous route;
- one primary button whose label is the state — Connect wallet, Enter an amount, Insufficient ETH balance, Simulate, Swap, Waiting…, Confirmed — so a swap cannot skip its simulation;
- the signing policy as a collapsible section, editable in place, and a refusal from it shown with the rule named.
Available Tools
FibX exposes 19 tools. The reference below groups them by the app, read-only, transactional, and session behavior.The App
Read-Only
Transactional
These tools carry the MCPdestructiveHint annotation. Clients may use the hint
to request confirmation, but confirmation behavior is client-dependent. All
three accept simulate=true; its behavior is specific to each tool.
simulate=true returns a no-broadcast preview, but the available checks differ
by tool. If a swap needs ERC-20 approval, the preview reports
requiresApproval: true without submitting the approval or estimating swap
gas. aave_action returns normalized request metadata without on-chain
validation or a gas estimate. A preview does not guarantee that later
execution will succeed.Session and Configuration
These change local state rather than chain state.set_policy_rule,
clear_policy_rule, and logout also carry destructiveHint — each can
remove a bound that was protecting the wallet, or end the session outright.
Tool Details
open_fibx
Open the FibX app. In a host that renders MCP Apps UI this is the entry point for anything about the wallet, a balance, a quote or a swap.
Output:
chain, auth (as get_auth_status reports it), balances
(null without a session), policy, terms (the resolved from/to/amount),
quote (the Fibrous route when all three were given) and quoteError. A quote
that could not be fetched sets quoteError rather than failing the call, so
the app still opens. The app requests one host permission, clipboardWrite,
for the Copy link button on the pairing screen.
Example prompts: “What’s in my wallet?”, “How much USDC would 0.01 ETH get me?”, “Swap 0.01 ETH to USDC”
list_tokens
List the tokens Fibrous supports on a chain. Feeds the app’s token picker; useful headlessly to resolve a symbol beforeget_quote or swap_tokens.
Output:
chain and tokens, each with symbol, name, address,
decimals, and price where known.
get_quote
Get a swap quote without a wallet or session.
Output: Routed swaps return
input, output, rate, slippage, router,
chain, and a nested quote with outputAmount, minReceived, usdIn,
usdOut, priceImpact, and route — the Fibrous route with protocol names,
as the FibX app draws it. Direct native/wrapped-native pairs return input,
output, rate, operation (wrap or unwrap), and chain.
get_auth_status
Check whether FibX is authenticated, which signing path is active, and whether the Fibrous API is reachable.
Output: Object with
authenticated, walletAddress, sessionType
(walletconnect, privy, or private-key), authType,
requiresApprovalPerTransaction (true for a WalletConnect session — the
wallet itself prompts for every transaction), chain, fibrousStatus
connect_wallet
Start a WalletConnect pairing. Returns immediately; show the QR, then poll withget_connect_status. On approval the pairing replaces the active
session, whatever path it used.
Output:
uri (the wc: link), qrDataUri (a PNG data URI of the QR), pairingId
get_connect_status
Poll a pairing started byconnect_wallet by its pairingId. Reports whether
the wallet has approved, and the connected address once it has.
get_policy
Read the local signing policy without changing it. No session needed. Output:state (active, absent, or unreadable), rules, path,
message. absent means nothing limits what this wallet will sign;
unreadable means a file exists but could not be parsed, which refuses every
transaction until it is fixed or removed.
Example prompts: “What’s my current signing policy?” or “Is anything limiting what fibx can sign?“
get_balance
Fetch token balances for the active wallet. The native-token entry is returned even when its balance is zero; ERC-20 entries are limited to non-zero balances.
Output: Object with
wallet, chain, and balances (e.g. ETH, USDC with amounts)
get_portfolio
Get a consolidated portfolio across all supported chains, including USD-valued token holdings and DeFi positions.
Output: Object with total portfolio USD value, per-chain assets, and DeFi position summaries
Example prompts: “Show me my portfolio” or “What’s my total net worth across all chains?“
swap_tokens
Execute a token swap through Fibrous. Handles routing and any required ERC-20 approval.
Execution output:
txHash, amountIn, amountOut, tokenIn, tokenOut,
router, chain, and explorer when available.
Preview output: Direct wrap/unwrap previews return success, mode,
operation, amountIn, tokenIn, tokenOut, and chain. Routed previews
also return amountOut, router, and requiresApproval; estimatedGas is
included only when the swap can be estimated without first broadcasting an
approval.
Example prompt: “Swap 0.1 ETH to USDC on Base”
send_tokens
Transfer native or ERC-20 tokens.
Execution output:
txHash, amount, token, recipient, chain, and
explorer when available.
Preview output: Both paths return success, mode, amount, token,
recipient, and chain. Native-token previews also return estimatedGas;
ERC-20 previews validate the transfer contract call without a gas field.
Example prompt: “Send 50 USDC to 0x1234…“
get_tx_status
Look up a transaction receipt by hash.
Output: Object with
hash, status, blockNumber, from, to, gasUsed,
chain, and explorer when available.
get_aave_status
Get Aave V3 account health on Base.
Output: Object with
wallet, healthFactor, totalCollateralUSD, totalDebtUSD, availableBorrowsUSD
get_aave_markets
List Aave V3 reserve markets on Base. No wallet or session is required.
Output: Object with
chain, marketCount, and markets. Each market
includes symbol, supplyAPY, borrowAPY, totalSupply, totalBorrow, ltv,
and isFrozen.
aave_action
Execute an Aave V3 operation on Base. ETH supply and repay can auto-wrap, ETH withdraw can auto-unwrap, and borrowing the ETH market returns WETH. Usemax
only for full repay or withdraw.
Execution output:
action, amount, token, txHash, chain, and
explorer when available. A repay with no remaining debt instead returns
status and no transaction hash.
Preview output: success, mode (PREVIEW (no TX sent)), action,
amount, token, chain, and note. The note states that no on-chain
validation, gas estimate, or transaction was performed.
Example prompts: “Supply 0.5 ETH to Aave” or “Repay max USDC on Aave”
config_action
Manage custom RPC URLs. Useful when encountering rate limits on public endpoints.
Output: Object with
action, chain, url, or rpcUrls depending on the action
Example prompts: “I’m getting rate limited on Base, set a custom RPC” or “Reset all RPCs to default”
set_policy_rule
Set one rule on the local signing policy —expiry, allowedChains,
<chain>.maxValue, or <chain>.allowedDestinations. Lists are comma-separated.
Output:
ok, rule, value, and the resulting rules
Setting a rule that already exists replaces its value — a cap can be
widened as easily as it was tightened, which is why this tool carries
destructiveHint. maxValue bounds only the native value of a transaction;
use allowedDestinations to bound where tokens may go.
Example prompts: “Cap Base transactions at 0.05 ETH” or “Only allow sending to my own address on Base”
clear_policy_rule
Remove one rule from the local signing policy, or the whole policy.
Output:
ok, changed, rule, the remaining rules, and a message
logout
End the WalletConnect pairing, if any, and clear the local session.Supported Chains
Environment Variables
If using Privy authentication, ensure
fibx-server is running and accessible before starting the MCP server.