boros-mcp

v0.3.0
@pendle/boros-mcp Checked 1 day ago Published 2 months ago

MCP server for Boros — Pendle's interest rate derivatives trading platform

These tools were reported by the server itself during our smoke test (tools/list), not copied from the README.

get_markets

Unified market lookup. Two modes: LIST MODE (no `marketIds`): list UI-whitelisted markets with optional filtering and sorting. Use to discover markets, compare volume/APR/OI, find by name/symbol. By default matures are hidden — set `includeMatured:true` to include. The cross-margin sentinel marketId 16777215 is never returned. Pass `include:["all"]` (or legacy `fullDetail:true`) to surface raw imData/config/metadata/extConfig/data per market. ID MODE (`marketIds` set): bulk fetch by ID, preserves request order, dedups, INCLUDES matured markets. Returns missing IDs in the `missing` array (c…

ParameterTypeDescription
filterarrayFilter conditions (LIST mode only).
fullDetailbooleanLegacy alias for include:["all"]. Adds raw imData/config/metadata/extConfig/data/state blocks. Default false.
includearrayExtra fields beyond default (marketId, name, symbol, status, maturity, maturityIso, isMatured, isIsolatedOnly, underlyingSymbol, markApr, volume24h). Default fields are always returned; passing them h…
includeMaturedbooleanInclude markets past maturity (LIST mode only; default false).
limitintegerMax results to return (LIST mode only; default 20, max 50).
marketIdsarrayWhen provided, switches to ID mode (bulk fetch by ID, preserves order, dedups, includes matured). Max 100. Omit for LIST mode.
skipnumberPagination skip (LIST mode only).
sortobjectSort criteria (LIST mode only).

get_orderbook

Get the order book for a market, showing aggregated bid/ask levels at a given tick size. Use this to see current market depth, best bid/ask, and liquidity distribution. Do NOT use this for historical data — use get_market_ohlcv or get_market_trades instead. For bulk historical order-book snapshots, download the archive: https://historical-data.boros.finance (see boros_glossary docs.historicalDataArchive).

ParameterTypeDescription
marketId *integerMarket ID (positive integer 1..2^24-1; resolve via get_markets).
includeAmmbooleanInclude AMM liquidity in the order book (default true)
minSizenumberFilter out levels smaller than this YU size (default 0 = keep all). Useful for cutting LP dust rungs.
tickSizenumberTick size for order book aggregation as DECIMAL (0.001 = 0.1%). Pass as a bare number or numeric string. Allowed values (closed backend enum): 0.0001, 0.001 (default), 0.01, 0.1.
topNintegerClient-side trim of the top-N levels per side (default 20). The server has no `topN` parameter — this is applied locally after `minSize`. The server caps every response at 50 levels/side UNCONDITION…

get_market_trades

Get recent executed trades on a market (public, anonymous tape — no trader address). Sorted newest-first. Use this to see the most recent fills (size, rate, timestamp). Multiple rows can share a txHash — those are partial fills against different price levels. Do NOT use this to look up YOUR trades — use get_transaction_history. Do NOT use this for candlestick/OHLCV data — use get_market_ohlcv instead. For the full historical trade tape (months), download the archive: https://historical-data.boros.finance (see boros_glossary docs.historicalDataArchive).

ParameterTypeDescription
marketId *integerMarket ID (positive integer 1..2^24-1; resolve via get_markets).
limitintegerMax trades to return (default 20, max 50)
resumeTokenstringCursor from previous response for next page.

get_market_ohlcv

Get OHLCV candlestick chart data for a market. Candles are built from EXECUTED TRADES (last-traded APR), not the mark rate, AMM implied rate, or oracle funding rate. OHLC values are APR DECIMALS (0.05 = 5%), not prices. Use this for trade-rate trend analysis. Empty buckets are FORWARD-FILLED with the previous close and volume=0; those rows are flagged with synthetic=true so an LLM doesn't read them as low-volatility periods. Do NOT use this for individual trade details — use get_market_trades instead. For indicator overlays (underlying APR, future premium, fear & greed, funding-rate MAs), us…

ParameterTypeDescription
marketId *integerMarket ID (positive integer 1..2^24-1; resolve via get_markets).
endTimestampintegerEnd timestamp (Unix seconds). Silently clamped to "now" if in the future. Set to (oldest timestamp from prior page) - 1 to page backwards.
limitintegerNumber of candles to return (default 50, max 200 = the backend cap). Ignored when startTimestamp is provided. To reach older history, pass startTimestamp + endTimestamp; see tool description.
startTimestampintegerStart timestamp (Unix seconds; not milliseconds). When paging older history, set startTimestamp = endTimestamp - 200 * timeFrameSeconds.
timeFramestringCandle time frame: 5m (5 minutes), 1h (1 hour), 1d (1 day), 1w (1 week). Default: 1h.

get_market_indicators

Get market indicators over time as overlays for chart analysis. All rate fields are decimals (0.05 = 5%). Indicators: u = underlying perp funding rate (annualized; CEX or DEX venue per market); fp = quarterly futures premium (annualised decimal); fgi = fear & greed index (integer 0-100, exposed as fearGreedIndex + fearGreedClassification); ap = underlying asset spot USD price; udma = N-day moving average of u, computed for each value of udmaPeriods (1-365 days, up to 10 periods). Use this for fundamental analysis overlays. When udma is selected, the lookback window is automatically expanded to…

ParameterTypeDescription
marketId *integerMarket ID (positive integer 1..2^24-1; resolve via get_markets).
select *arrayIndicators to fetch: u (underlying perp funding rate, annualized; CEX or DEX venue per market), fp (quarterly futures premium), fgi (fear & greed index), ap (asset spot USD price), udma (rolling mean…
endTimestampintegerEnd timestamp (Unix seconds). Must be >= startTimestamp. Set to (oldest timestamp from prior page) - 1 to page backwards.
limitintegerNumber of data points to return (default 20, max 200). Ignored when startTimestamp is provided. To page beyond 200, use endTimestamp; see tool description.
startTimestampintegerStart timestamp (Unix seconds; not milliseconds). When paging older history, set startTimestamp = endTimestamp - 200 * timeFrameSeconds.
timeFramestringCandle time frame: 5m (5 minutes), 1h (1 hour), 1d (1 day), 1w (1 week). Default: 1h.
udmaPeriodsarrayMoving-average windows in days for udma (e.g. [7, 30]). Each period must be 1-365; up to 10 periods allowed. Defaults to [7, 30] when udma is selected.

get_strategies

Get cross-market funding-rate arbitrage opportunities. Each row pairs two Boros markets on the same underlying asset — a longMarket leg (pay fixed, receive floating) and a shortMarket leg (receive fixed, pay floating) — that together capture the spread between two implied APRs. Use this to discover two-leg arbitrage candidates. There is no on-chain "strategy" object — execution is two independent place_order calls (one per leg). Do NOT confuse with vault strategies or saved trade templates. Filter passes (backend-side): aprTimesMaxLeverage > 0 AND daysToMaturity > 10.

get_tvl

Get Boros protocol *collateral* TVL in USD — the sum of every collateral ERC-20 held by the MarketHub contract on Arbitrum, broken down per token. Each entry shows the raw on-chain balance (in token decimals — divide by `decimals` for human units), USD price, and USD value. This is NOT vault TVL (use get_amm_info for per-vault TVL) and NOT open interest. Token prices are cached oracle snapshots refreshed ~every 60s.

get_assets

Get supported tokens registered on Boros (collateral + non-collateral entries), including token addresses, decimals, USD prices, and minimal metadata. By default only deposit-eligible collaterals are returned (isCollateral=true, positive tokenId). Set includeNonCollateral=true to also list non-collateral entries: the PENDLE reward token plus market-underlying price refs (NVDA, XAU, SOL, oil, etc.). All non-collateral entries share tokenId = -1 (sentinel — not unique) and cannot be deposited as margin; identify them by address or symbol. Use this to look up an asset's tokenId / decimals befor…

ParameterTypeDescription
filterarrayFilter conditions.
includeNonCollateralbooleanInclude non-collateral entries (PENDLE reward token + market-underlying price refs like NVDA/XAU/SOL/oil). All share tokenId = -1 sentinel and cannot be deposited. Default false.
sortobjectSort criteria.

get_amm_info

Get the AMM (Automated Market Maker) swap-state for a market: total float / normalized-fixed reserves, LP token total supply, fee rate, current implied APR, rate bounds, maturity, cutoff, and whether the pool has been disabled (`disabled` is always returned — true means liquidated / withdraw-only, so the quoted impliedRate is frozen, not live). Vault economics (totalValue, totalSupplyCap, lpApy, lpPrice) ride on the same response — request them via include instead of a second call. Use get_vault_info for your own deposit position, fillPercent, or the all-vaults list. For order-book depth (…

ParameterTypeDescription
ammIdintegerAMM ID (positive). Resolve via market info. Reverse-resolves to marketId via market list. Takes precedence over marketId if both provided.
includearrayExtra fields beyond default (ammId, marketId, marketName, isPositive, feeRate, impliedRate, impliedRatePercent, disabled). Default fields are always returned; passing them here is a no-op. Use "all" f…
marketIdintegerMarket ID (positive integer 1..2^24-1; resolve via get_markets). Direct lookup key. Provide either marketId or ammId.

get_vault_info

Get Boros LP vault info: TVL (totalValue, a raw 18-decimal bigint string — always 1e18, never token-native decimals; divide by 1e18), LP token supply, supply cap, lpPrice, lpApy (combined fees+incentives), and optionally your deposit position. With marketId: single-vault detail. Without marketId: summary list — by default only ACTIVE vaults (maturity > now) plus any matured vaults where the caller still holds LP. Pass includeMatured=true for the full set. Per-vault user blocks are suppressed by default; pass fullDetail=true to include them (response can exceed 50 KB). Use this for: vault T…

ParameterTypeDescription
accountIdintegerAccount ID 0..255, default 0. Only used when userAddress is provided.
fullDetailbooleanOnly meaningful in list mode (no marketId). When true, include the full per-vault user position object. Default false.
includeMaturedbooleanList mode only. When true, include vaults whose maturity has passed (residual LP only). Default false — matured vaults appear only when the caller has a non-zero LP balance there.
limitintegerMax vaults to return in list mode (default 50, max 100 — matches the backend hard cap).
marketIdintegerMarket ID (positive integer 1..2^24-1; resolve via get_markets). Specific vault. Omit to get the all-vaults summary.
userAddressstringYour wallet address (0x...). Include user-specific vault position data (only materialised in single-vault mode or when fullDetail=true). When set in list mode, also surfaces matured vaults where the c…

get_amm_user_rewards

Get accrued and unclaimed LP-vault rewards (Boros amm_lp_rewards Merkle campaign) in USD for a wallet, summed across all vaults. Rewards come as PENDLE (incentive) plus the vault collateral token (swap fees); the USD figures here aggregate both. Distribution is weekly via Merkle-root publication (Thursdays); newly-deposited LPs may show $0 until the next root. Aggregation is per ROOT WALLET (not per accountId). NOTE: `perMarket[].unclaimedRewards` is a RESERVED backend field, hardcoded to "0" for every user — it is not a real per-market figure and is neither filterable nor sortable here; use…

ParameterTypeDescription
userAddress *stringYour wallet address (0x...).
filterarrayFilter conditions applied to `perMarket[]` only — top-level USD totals are unchanged. Nested `allTimeRewards.*` fields are not addressable.
sortobjectSort criteria for `perMarket[]`.

add_liquidity

Simulate or execute adding single-sided cash liquidity to a market's AMM pool. Default mode is 'simulate' — ALWAYS run mode:'simulate' first, show the fee preview, then ONLY call mode:'execute' AFTER explicit user confirmation. UNITS: `humanCash` / `cashAmount` are in the BOROS-INTERNAL 18-DECIMAL cash unit (NOT token-native decimals — Boros normalizes every collateral to 18d after deposit). One cash unit ≈ 1 USD-equivalent of the market's collateral. `minLpOut` (raw 18d bigint string) is REQUIRED for mode:'execute' unless `acknowledgeNoSlippageProtection:true` is set. The public sim d…

ParameterTypeDescription
marketId *integerMarket ID (positive integer 1..2^24-1; resolve via get_markets). AMM pool to deposit cash into.
acknowledgeNoSlippageProtectionbooleanSet to `true` ONLY when explicitly told by the user to skip MEV protection. When true, `minLpOut` defaults to '1' wei — the lowest value the API accepts, i.e. effectively NO protection.
cashAmountstringRaw cash amount as 18d bigint string. Provide either humanCash or cashAmount.
humanCashnumberHuman-readable cash amount to deposit (e.g. 100.5). Boros-internal 18d cash unit (NOT token-native).
minLpOutstringMinimum LP tokens to receive, as a raw 18d bigint string. Required for mode:"execute" unless `acknowledgeNoSlippageProtection:true` is set.
modestring"simulate" (default): fee-only preview. "execute": sign and submit via the agent key. ALWAYS simulate first.

remove_liquidity

Simulate or execute burning LP tokens to receive single-sided cash from a market's AMM pool. Default mode is 'simulate' — ALWAYS run mode:'simulate' first, show the fee preview, then ONLY call mode:'execute' AFTER explicit user confirmation. UNITS: `humanLp` / `lpAmount` are in 18-decimal LP tokens. `minCashOut` is a raw 18d bigint string in the BOROS-INTERNAL 18-DECIMAL cash unit (NOT token-native). `minCashOut` is REQUIRED for mode:'execute' unless `acknowledgeNoSlippageProtection:true` is set — the public sim does NOT project cash-out today, so omitting opens the burn to MEV/sandwich…

ParameterTypeDescription
marketId *integerMarket ID (positive integer 1..2^24-1; resolve via get_markets). AMM pool to burn LP tokens from.
acknowledgeNoSlippageProtectionbooleanSet to `true` ONLY when explicitly told by the user to skip MEV protection. When true, `minCashOut` defaults to '1' wei — the lowest value the API accepts, i.e. effectively NO protection.
humanLpnumberHuman-readable LP amount to burn (e.g. 10.5). 18-decimal LP tokens.
lpAmountstringRaw LP amount as 18d bigint string. Provide either humanLp or lpAmount.
minCashOutstringMinimum cash to receive, as raw 18d bigint string in the Boros-internal cash unit. Required for mode:"execute" unless `acknowledgeNoSlippageProtection:true` is set.
modestring"simulate" (default): fee-only preview. "execute": sign and submit via the agent key. ALWAYS simulate first.

get_funding_rate_symbols

List the upstream funding-rate sources Boros tracks. Each entry is one (exchange, perp-ticker, asset) tuple feeding the indexer. This is NOT a list of tradeable Boros markets and `fundingRateSymbol` is NOT a Boros marketId — call get_markets and join on metadata.fundingRateSymbol to map a symbol to its Boros marketIds.

ParameterTypeDescription
filterarrayFilter conditions. LIKE on `fundingRateSymbol`/`assetSymbol`/`exchange` is the typical use; lowercase both sides since `exchange` casing is non-canonical.

get_settlement_summary

Get periodic funding-rate settlement aggregates (market-wide), one row per market per settlement bucket, sorted newest-first. Bucket cadence is per market (commonly 1h, 4h, or 8h — matches the upstream perp funding interval; resolve via the `periodTimestamp` deltas in the response). This is funding settlement, NOT market-maturity expiry settlement. Use get_pnl_history for a single account's funding paid/received; use get_market_indicators for upstream perp funding source rates per market; use get_pnl_by_market for live unrealized funding. Use this only for market-wide settlement history.

ParameterTypeDescription
fromTimestamp *integerStart of range (Unix seconds; not milliseconds).
toTimestamp *integerEnd of range (Unix seconds; not milliseconds).
filterarrayFilter conditions. Filter on raw `settlementApr` (decimal), not the enriched `period`/`block` objects.
marketIdsarrayMarkets to include: 1-100 ids. Never pass an empty array (backend 400s) — OMIT the field to cover all whitelisted markets. There are ~183 markets, so an explicit "all markets" list exceeds the 100 c…
sortobjectSort criteria. Default desc on `periodTimestamp` matches the existing newest-first server order.

get_liquidation_events

Get recent forced-liquidation events sorted newest-first. Each event shows the violator and liquidator positions before/after, mark APR at liquidation, the APR the liquidation trade executed at, the YU size moved, and the tx hash. Filter by market and/or time range. NOT the same as periodic funding settlements (use get_settlement_summary) and NOT a voluntary close (use get_transaction_history). For raw on-chain Liquidate logs see get_on_chain_events. Pagination (max 50 per call): to page older history, set toTimestamp = (oldest event timestamp from prior page) - 1.

ParameterTypeDescription
fromTimestampnumberUnix seconds inclusive lower bound.
limitintegerMax results (default 20, capped at 50).
marketIdintegerMarket ID (positive integer 1..2^24-1; resolve via get_markets). Filter by market.
toTimestampnumberUnix seconds inclusive upper bound.

get_on_chain_events

Query the backend's indexed catalogue of decoded Boros contract events (Router/MarketHub/Market/AMM/MarketFactory) with cursor-based pagination, sorted newest-first by (blockNumber, logIndex). Use this for protocol-wide audits ("all MarketCreated events", "all AgentApproved on the Router", "raw Liquidate logs"). Do NOT use for user-centric questions: trade fills on a known account → get_transaction_history; deposits/withdrawals/cash transfers on a known account → get_transfer_logs; liquidations with rate enrichment → get_liquidation_events; account snapshot → get_portfolio_summary. `so…

ParameterTypeDescription
eventNamestringFilter by exact event name (case-sensitive). NOT validated server-side — the backend takes a free-form string, so a typo or an invented name returns HTTP 200 with 0 rows rather than an error. There…
fromBlockNumberintegerStart block (inclusive)
limitintegerMax results (default 20, capped at 50).
resumeTokenstringCursor from previous response for next page.
sourceAddressstringFilter by source CONTRACT address (e.g. Router 0x8080808080daB95eFED788a9214e400ba552DEf6) — not a user wallet
toBlockNumberintegerEnd block (inclusive)

get_leaderboard

Get leaderboard data for a (period, tokenId). Two modes: LIST MODE (no `userAddress`): top traders by ROI, paginated. Returns rank, wallet, PnL, net balance, trading volume, max capital, ROI per entry. LOOKUP MODE (`userAddress` set): single-wallet lookup — returns rank/PnL/balance/volume/ROI for that wallet. `userInLeaderboard` is true iff the user qualifies (≥$2k account value AND ≥$100k notional volume); otherwise PnL/balance/volume zeros may mean "below threshold" OR "never traded". Computed from a daily UTC-midnight snapshot (lags up to ~24h). ROI = PnL / (starting account value…

ParameterTypeDescription
tokenId *integerCollateral token ID (see get_assets).
accountIdintegerAccount ID 0..255, default 0. Used only in LOOKUP MODE.
limitintegerNumber of entries (LIST mode only; default 20, max 50).
offsetnumberPagination offset (LIST mode only).
periodstringLeaderboard period (default 7d).
userAddressstringYour wallet address (0x...). When set, switches to LOOKUP MODE for a single user.

get_maker_incentives

Get maker incentive campaign data for a market: three tracks — per-side (long/short) add-liquidity PENDLE rewards, filled-volume epoch PENDLE rewards, and the maker-fee rebate. Boros currently rewards limit-order makers only; takers get nothing here. Denominations differ per track: the two incentive tracks pay PENDLE, while makerFeeRebate is denominated in the MARKET'S COLLATERAL TOKEN — see the `rewardTokens` map in the response, do not assume one token for everything. Pass `maker` (your wallet) to populate currentEligibleShare, accumulatedReward and the rebate amounts; without it, those…

ParameterTypeDescription
marketId *integerMarket ID (positive integer 1..2^24-1; resolve via get_markets).
makerstringMaker wallet address (optional)

get_portfolio_summary

Aggregate portfolio snapshot for an account: per-collateral-token totals (collateral, equity, initial/available margin), open-position count, open-order count, margin utilization, and optionally unrealized PnL. COLLATERAL FIGURES ARE ACCOUNT ID 0 ONLY: the discovery call GET /v1/accounts/market-acc-infos-by-root hardcodes accountId 0 server-side and cannot be pointed at a sub-account, so for accountId 0 it does find every funded marketAcc (cross + isolated, including dust accounts with cash but no positions) but for ANY non-zero accountId every collateral/margin number here is 0 and `accounts`…

ParameterTypeDescription
userAddress *stringYour wallet address (0x...).
accountIdintegerAccount ID 0..255, default 0. Default 0 for main account.
includePnlbooleanIf true, fetch per-(marketAcc,marketId) unrealized PnL (adds N parallel calls). Default false to keep the summary fast.

get_positions

List open positions (non-zero size) for an account from the indexer. Per row: market, direction (long/short), signed size in YU, entry fixedApr, all-time cumulative trade PnL (in the marketAcc collateral token), maturity flag, decoded marketAcc. unrealisedPnl / settlementPnl / isCross are available via `include`. Margin, positionValue and liquidation APR are NOT on this endpoint at all (no `include` value returns them) — use get_collateral for margin/liquidationApr/positionValue. cumulativePnl is shipped formatted via the 18-dec internal scaling.

ParameterTypeDescription
userAddress *stringYour wallet address (0x...).
accountIdintegerAccount ID 0..255, default 0. Default 0 for main account.
filterarrayFilter conditions. Operates on the underlying record, regardless of `include` projection. Filter on raw `fixedApr` (decimal), not `fixedAprPercent` (string with `%` suffix).
includearrayExtra fields per position beyond default (marketId, marketName, marketSymbol, sideLabel, signedSize, cumulativePnl, fixedAprPercent). Default fields are always returned; passing them here is a no-op.…
sortobjectSort criteria. Sortable fields are numeric only — sort on raw `fixedApr`, not `fixedAprPercent`.

get_collateral

Get per-marketAcc margin/equity (totalCash, netBalance, initialMargin, availableInitialMargin, availableMaintMargin, per-position margin/liquidationApr/orders). ACCOUNT ID 0 ONLY when marketAccs is omitted: the discovery call GET /v1/accounts/market-acc-infos-by-root hardcodes accountId 0 server-side, so it can only ever return accountId-0 marketAccs (cross + isolated, including dust accounts with cash but no positions). For ANY non-zero accountId you MUST pass marketAccs explicitly — otherwise this tool reports zero collateral even for a fully funded sub-account, and a "no funded marketAcc"…

ParameterTypeDescription
userAddress *stringYour wallet address (0x...).
accountIdintegerAccount ID 0..255, default 0. Default 0 for main account.
filterarrayFilter conditions. Sortable/filterable balance fields are `*Formatted` decimal strings; nested `positions[]` fields are not addressable.
marketAccsarraySpecific marketAcc addresses to query (POST /v1/accounts/market-acc-infos; honours any accountId). If omitted, marketAccs are discovered via GET /v1/accounts/market-acc-infos-by-root, which is account…
sortobjectSort criteria.

get_pnl_by_market

Get a snapshot of per-market PnL for a (marketAcc, marketId) position: live unrealisedPnl + all-time realised trade PnL (allTimeTradePnl, NET of fees) + all-time funding-rate settlement PnL (allTimeSettlementPnl), plus derived allTimePnl (trade+settlement) and netPnl (trade+settlement+unrealised). Backed by GET /v1/accounts/active-positions — the standalone /pnl-by-market endpoint was deprecated. The since-open breakdown is no longer surfaced (only all-time + unrealised). For cross marketAcc, marketId picks which market to summarise; for isolated marketAcc, marketId must equal the marketAcc…

ParameterTypeDescription
marketAcc *stringPacked marketAcc: 0x followed by 52 hex chars (54 chars total). Cross accounts carry 0xFFFFFF in the marketId segment.
marketId *integerMarket ID (positive integer 1..2^24-1; resolve via get_markets). Market to summarise PnL for. For isolated marketAcc this must equal the marketAcc embedded marketId.
includearrayExtra fields beyond default (marketAcc, marketId, marketName, marketSymbol, unrealisedPnl, allTimeTradePnl, allTimeSettlementPnl, allTimePnl, netPnl). Default fields are always returned; passing them…

get_entered_markets

Get the list of markets a cross margin account has entered. Only applicable to cross accounts — entering a market is required before trading on it under cross margin (entry can also happen implicitly inside place_order via the `enterMarket` flag, paying a small fee). Isolated accounts do not use this concept. Pass the cross marketAcc directly, OR pass userAddress + accountId + tokenId to have it packed for you. Note: a market can be `entered` while position size is 0 — exit via enter_exit_markets requires zero position AND zero open limit orders. Matured markets cannot be exited at all tod…

ParameterTypeDescription
accountIdintegerAccount ID 0..255, default 0. Used only when marketAcc is omitted.
filterarrayFilter conditions. Operates on the underlying record, regardless of projection.
marketAccstringPacked marketAcc: 0x followed by 52 hex chars (54 chars total). Cross accounts carry 0xFFFFFF in the marketId segment. Either pass this OR (userAddress + accountId + tokenId).
sortobjectSort criteria.
tokenIdintegerCollateral token ID (see get_assets). Used only when marketAcc is omitted.
userAddressstringYour wallet address (0x...). Used with accountId + tokenId to pack a cross marketAcc when marketAcc is omitted.

get_orders

List a user's orders (LIMIT, MARKET, TAKE_PROFIT_MARKET, STOP_LOSS_MARKET). Two sort modes: `sort:'updated'` (default): newest by last-updated event index — supports filtering by `marketId` and `isActive`. Paginating mid-stream can miss/duplicate orders that were updated between pages. Default `isActive:true` returns only currently-open orders (typically resting LIMIT / TP / SL). Use this for "open orders" / "pending orders" queries. `sort:'placed'`: newest by placed event index (immutable cursor) — guarantees no orders missed when fully enumerating, but ignores the `marketId`, `isActive…

ParameterTypeDescription
userAddress *stringYour wallet address (0x...).
accountIdintegerAccount ID 0..255, default 0. Default 0 for main account.
includearrayExtra fields per order beyond default (orderId, marketId, marketName, marketSymbol, sideLabel, statusLabel, orderTypeLabel, size, unfilled, impliedAprPercent). Default fields are always returned; pass…
isActiveboolean | nullActive status filter (sort="updated" only). Default true. Pass false for filled/cancelled, null to include every status.
limitintegerNumber of orders (max 50, default 20).
marketIdintegerMarket ID (positive integer 1..2^24-1; resolve via get_markets). Filter by market ID. Honored only when sort="updated".
orderTypearrayOrder-kind filter (sort="updated" only): 0 LIMIT, 1 MARKET, 2 TAKE_PROFIT_MARKET, 3 STOP_LOSS_MARKET. Omit for all kinds. Time-In-Force (GTC/IOC/FOK/POST_ONLY) is a separate concept and is not filtera…
resumeTokenstringCursor token from previous response.
sortstringSort: "updated" (default, supports marketId/isActive filters) or "placed" (immutable cursor, ignores filters).

get_pnl_history

Get funding-rate SETTLEMENT history (one row per periodic funding payment) — NOT a combined PnL series. Each record carries yieldPaid, yieldReceived, fee, the net settlement (yieldReceived - yieldPaid - fee), the position side/size/value at settlement time, and both all-time (cumulativeSettlementPnl) and since-open (sinceOpenSettlementPnl) cumulative settlement PnL. Note: cumulativeSettlementPnl excludes per-row fee while per-row `settlement` subtracts it — they will not reconcile by exact sum. Does NOT include realized trade PnL — use get_transaction_history for per-trade PnL, or get_pn…

ParameterTypeDescription
userAddress *stringYour wallet address (0x...).
accountIdnumberAccount ID (default 0 for main account)
includearrayExtra fields per settlement record beyond default (marketId, marketName, marketSymbol, sideLabel, settledAt, settlementRatePercent, positionSize, settlement, cumulativeSettlementPnl). Default fields a…
limitintegerNumber of settlement records to return (max 50, default 20).
marketIdintegerMarket ID (positive integer 1..2^24-1; resolve via get_markets). Filter by market ID.
resumeTokenstringCursor token from previous response for next page.

get_transaction_history

Get historical trading FILLS (one record per fill: tradeSize, tradeRate, tradeValue, fee, realized pnl, txHash, maker/taker flag, and the pre/post position snapshot via include:["prevPositionS","postPositionS","prevPositionF","postPositionF"] — S = signed size, F = fixed-rate cost basis). Backed by GET /v1/accounts/position-update-events (requires marketAcc + marketId per request). Sorted newest-first by event index; de-duplicate on `id`. Behaviour: pass marketId to query that market (even if the position is closed or matured) — resumeToken pagination is only supported in single-market mod…

ParameterTypeDescription
userAddress *stringYour wallet address (0x...).
accountIdnumberAccount ID (default 0 for main account)
includearrayExtra fields per fill beyond default (marketId, marketName, marketSymbol, sideLabel, tradedAt, tradeRatePercent, tradeSize, tradeValue, pnl, fee). Default fields are always returned; passing them here…
limitnumberNumber of transactions per market (max 50, default 20).
marginModestringMargin mode (default cross). Only used when marketId is set.
marketIdintegerMarket ID (positive integer 1..2^24-1; resolve via get_markets). Filter by market ID. If omitted, queries all markets with active positions (no pagination across closed markets).
resumeTokenstringCursor token from previous response (single-market mode only).

get_transfer_logs

Boros internal collateral ledger — vault deposits/withdrawals, cross↔isolated transfers, isolated↔isolated transfers, and AMM↔cross (vault deposit/withdraw) cash moves. NOT ERC-20 Transfer events. Withdrawals appear as `pending` during cooldown and flip to `success` on finalisation (or `failed` on cancel). Direction is encoded by fromType→toType — `amount` is always non-negative. tokenId filter can be derived from get_assets. Use get_transaction_history for trade fills, get_pnl_history for funding settlements, get_gas_info(scope:"history") for gas budget movements.

ParameterTypeDescription
userAddress *stringYour wallet address (0x...).
accountIdnumberAccount ID (default 0 for main account)
includearrayExtra fields per transfer log beyond default (at, transferType, amount, amountSymbol, status, fromType, toType). Default fields are always returned; passing them here is a no-op. Use "all" for everyth…
limitnumberNumber of records to return (max 50)
resumeTokenstringCursor token from previous response for next page
tokenIdintegerCollateral token ID (see get_assets). Filter by collateral token.

get_gas_info

Unified gas read. Combines: off-chain Boros gas BUDGET (USD ledger debited by send-txs-bot), per-action gas HISTORY (USD), and Arbitrum L2 gas PRICE (gwei + USD per non-AMM limit order). The BUDGET is per-wallet (per `root` EOA), NOT per-accountId; backend rejects only when balance goes strictly negative. Top up: pay_gas (debits margin) or vault_pay_treasury (debits wallet token balance). The L2 PRICE is what the bot wallet pays per tx, NOT what the user is charged. `scope` selects what to return: - 'all' (default): { budget, history (latest `limit`), price } — needs userAddress. - 'balanc…

ParameterTypeDescription
limitintegerNumber of history records to return (max 50). Used only when scope is "all" or "history".
resumeTokenstringCursor token from previous response for next page of history.
scopestringWhich gas reads to return. Default "all".
userAddressstringYour wallet address (0x...). Required when scope is "all", "balance", or "history". Ignored for "price".

place_order

Simulate or execute an order on a Boros market. Default mode is 'simulate' — ALWAYS run mode:'simulate' first, show the preview to the user, then ONLY call mode:'execute' AFTER explicit user confirmation. The execute path re-runs the simulation internally before signing; calldata uses the current mid-rate at execute-time, so re-simulate after any meaningful delay. UNITS: `size` is YU (yield units), ALWAYS POSITIVE — direction comes from `side` (LONG/SHORT). NEVER sign size to indicate short. `limitApr` and `slippage` are DECIMALS (0.05 = 5%, NOT 5). `marginMode:'cross'` = per-token shared…

ParameterTypeDescription
marketId *integerMarket ID (positive integer 1..2^24-1; resolve via get_markets).
orderType *stringOrder type. market → defaults to FOK (all-or-nothing); limit → defaults to GTC (rests on book).
side *stringTrade direction (accepts either case)
size *stringNotional size in YU (yield units), human-readable decimal (e.g. "1000.5"). ALWAYS POSITIVE — direction is set by `side`, never by signing size.
acknowledgeHighRatebooleanRequired when |limitApr| exceeds max(1, |markApr|*5) for the target market. The floor scales with each market's current markApr — typical 5%-mark books reject limitApr:5 (= 500%) as a percent-vs-dec…
includeAmmbooleanAMM routing toggle. true (default) = route via market AMM if one exists (resolved from market.extConfig.ammId / market.metadata.ammId, else 0). false = force orderbook-only. Forced to orderbook-only i…
limitAprnumberLimit APR as DECIMAL (0.05 = 5%, NOT 5). Required for orderType:"limit"; optional for "market" (acts as a rate guard with IOC). Values exceeding max(1, |markApr|*5) for the target market require ackno…
marginModestringMargin mode. cross (default): one bucket per (root, accountId, tokenId) — shared across all entered markets for that token. isolated: per-market bucket keyed by marketId, walled off from cross. Move…
modestring"simulate" (default): preview only — fill, margin, price impact, liquidation APR. "execute": re-simulate, then sign and submit via the agent key. ALWAYS simulate first; execute requires explicit use…
slippagenumberMax slippage as DECIMAL (0.05 = 5%, NOT 5). Effective only for FOK market orders — backend silently ignores it for GTC/ALO/SOFT_ALO (those are guarded by limitApr/limitTick instead). If omitted, def…
timeInForcestringOrder time-in-force policy. Defaults when omitted: orderType=limit → GTC; orderType=market → FOK. Values: GTC = rest unmatched remainder on book until filled or cancelled (standard limit). IOC = t…

close_position

Simulate or execute closing a position. Default mode is 'simulate' — ALWAYS run mode:'simulate' first, surface simulation.priceImpactPercent, matched rate, closeTradePnl, and marginRequired to the user, then ONLY call mode:'execute' AFTER explicit user confirmation. The tool AUTO-FLIPS your input `side` (the position side) to derive the counter-order side internally — pass the side of the OPEN position, NOT the close direction. Omit `size` to close the full active position. Reduce-only is NOT enforced server-side and the on-chain `placeSingleOrder` has NO reduce-only flag — the only gu…

ParameterTypeDescription
marketId *integerMarket ID (positive integer 1..2^24-1; resolve via get_markets). Market of the position to close.
side *stringSide of the EXISTING position (long or short; any case). The tool flips internally to derive the counter-order side.
closeTypestringClose order type. market → defaults to FOK; limit → defaults to GTC.
includeAmmbooleanAMM routing toggle. true (default) = route via market AMM if one exists (resolved from market.extConfig.ammId / market.metadata.ammId, else 0). false = force orderbook-only. Forced to orderbook-only i…
limitAprnumberLimit APR for limit close orders as DECIMAL (0.05 = 5%, NOT 5). No upper bound.
marginModestringMargin mode. cross (default): one bucket per (root, accountId, tokenId) — shared across all entered markets for that token. isolated: per-market bucket keyed by marketId, walled off from cross. Move…
modestring"simulate" (default): preview the close fill, PnL, and margin impact. "execute": re-simulate, then sign and submit via the agent place-order calldata endpoint with flipped side. ALWAYS simulate first;…
sizestringNotional size to close in YU, human-readable decimal. Omit for full close. Always positive.
slippagenumberMax slippage as DECIMAL (0.05 = 5%, NOT 5). Effective only for FOK market orders — backend silently ignores it for GTC/ALO/SOFT_ALO (those are guarded by limitApr/limitTick instead). If omitted, def…
timeInForcestringOrder time-in-force policy. Defaults when omitted: orderType=limit → GTC; orderType=market → FOK. Values: GTC = rest unmatched remainder on book until filled or cancelled (standard limit). IOC = t…

cancel_orders

Cancel one or more limit orders on a market. Provide specific orderIds or set cancelAll to true. Stale-id handling: with `atomic:false` the on-chain bulkCancels silently skips ids that are filled/cancelled. With `atomic:true` the contract reverts on any unknown id. The backend pre-flight simulator may also reject the whole batch when an id is unknown to its state — observed inconsistently in 2026-Q2 testing, so the safest pattern is still to filter stale ids client-side via get_orders before calling, especially under atomic:true. `cancelledCount` reflects the number of orders actually remove…

ParameterTypeDescription
marketId *integerMarket ID (positive integer 1..2^24-1; resolve via get_markets).
atomicbooleantrue (default): whole batch reverts if any cancel fails (and the contract treats any unknown id as failure). false: best-effort on-chain — stale ids are silently skipped. The backend pre-flight simu…
cancelAllbooleanCancel all open orders on this market. Mutually exclusive with orderIds.
marginModestringMargin mode. cross (default): one bucket per (root, accountId, tokenId) — shared across all entered markets for that token. isolated: per-market bucket keyed by marketId, walled off from cross. Move…
orderIdsarrayArray of order ID strings to cancel. Mutually exclusive with cancelAll:true.

cash_transfer

INTERNAL margin move between your own cross and isolated buckets on Boros. NOT an ERC-20 transfer — there is no recipient address. To move funds out of Boros use `withdraw`; to deposit fresh tokens use `deposit`; to top up gas budget use `pay_gas`. Default mode is 'simulate' — ALWAYS run mode:'simulate' first to preview pre/post margin state, show the user, then ONLY call mode:'execute' AFTER confirmation. Execute requires gas budget; top up via pay_gas if needed. AMOUNT UNITS: prefer `humanAmount` (token units, e.g. 20 = 20 USDC) over `amount` to avoid scale mistakes. Boros stores ALL c…

ParameterTypeDescription
direction *stringTransfer direction
marketId *integerMarket ID (positive integer 1..2^24-1; resolve via get_markets). Isolated account.
amountstringRaw X18 integer (Boros internal cash unit; 1e18 = 1 token of the collateral, regardless of the ERC-20 native decimals). For 20 USDT0 pass "20000000000000000000". Prefer `humanAmount` unless you alread…
humanAmountnumberAmount in TOKEN UNITS (e.g. 20 = 20 USDT0, 0.5 = 0.5 WETH). NOT USD — for non-stablecoin collateral this is units of the token. MCP scales by 1e18 for the X18 wire. Mutually exclusive with amount.
modestring"simulate" (default): preview pre/post margin state. "execute": sign and submit via the agent key. ALWAYS simulate first.

pay_gas

Top up the off-chain gas budget by paying treasury for a specific market. DEDUCTED FROM YOUR MARGIN ACCOUNT (cross or isolated per marginMode) — this moves collateral into a non-withdrawable gas budget. Required before placing orders if gas balance is low.

ParameterTypeDescription
amount *numberAmount in USD to top up the off-chain gas budget (must be > 0)
marketId *integerMarket ID (positive integer 1..2^24-1; resolve via get_markets). Market treasury receives the payment.
marginModestringMargin mode. cross (default): one bucket per (root, accountId, tokenId) — shared across all entered markets for that token. isolated: per-market bucket keyed by marketId, walled off from cross. Move…

place_orders

ADVANCED — liquidity-provisioning / market-making batch placement. Places up to 100 heterogeneous order entries in ONE agent transaction (one signature, one txHash). Each entry is one of two kinds: - kind:'single' — compiles to one on-chain placeSingleOrder call. Power-user controls: raw limitTick XOR human-readable rate; absolute desiredRate XOR relative slippage; per-entry ammId (0 = orderbook-only, n = AMM route); optional preCancelOrderId (atomic strict cancel-and-replace one resting id). - kind:'bulk' — compiles to one on-chain bulkOrders multicall covering N per-market sub-orders…

ParameterTypeDescription
entries *arrayHeterogeneous batch of order entries (max 100). Each entry becomes one on-chain call (placeSingleOrder OR bulkOrders), all bundled under one tryAggregate tx.
acknowledgeHighRatebooleanRequired when any single-entry `rate` exceeds max(1, |markApr|*5) for its market. The threshold scales with the market's current markApr — markets that already trade at extreme APR (oil at –117%,…
atomicbooleantrue (default): whole batch reverts if any entry fails. false: best-effort — survivors execute independently, but `ok` is still false if ANY sub-call reverted (inspect `reverts[]`).

enter_exit_markets

Enter or exit markets. Entering a market allows trading on it under the chosen margin mode. Exiting requires zero position size AND zero open limit orders in that same bucket. Markets flagged `isIsolatedOnly:true` by get_markets REQUIRE marginMode:"isolated" — a cross entry on one of those still succeeds and still charges the entry fee, but the account can never place an order there. Isolated enter/exit targets exactly ONE marketId per call (backend rule); call again per market. NOTE: entering a market draws a one-time per-market entrance fee in collateral, on top of the off-chain gas budget…

ParameterTypeDescription
action *stringWhether to enter or exit the markets
marketIds *arrayArray of market IDs to enter or exit (1..100; exactly 1 when marginMode is "isolated")
marginModestringMargin mode. cross (default): one bucket per (root, accountId, tokenId) — shared across all entered markets for that token. isolated: per-market bucket keyed by marketId, walled off from cross. Move…

simulate_place_order

Preview a place-order WITHOUT a connected wallet. Returns matched size/cost/rate, margin required, price impact, fee breakdown, maker incentives, and the resolved tick/rate the order would snap to. No authentication or agent setup needed — use for quick order quotes before wallet connection. UNITS: `size` is YU (yield units), ALWAYS POSITIVE — direction comes from `side` (LONG/SHORT). `limitApr` and `slippage` are DECIMALS (0.05 = 5%, NOT 5). Use this tool when: - User wants to estimate an order without connecting a wallet. - Building a quote preview / order-entry UI. - Exploring market…

ParameterTypeDescription
marketId *integerMarket ID (positive integer 1..2^24-1; resolve via get_markets).
orderType *stringOrder type. market → defaults to FOK; limit → defaults to GTC.
side *stringTrade direction (accepts either case)
size *stringNotional size in YU (yield units), human-readable decimal (e.g. "1000.5"). ALWAYS POSITIVE — direction is set by `side`.
includeAmmbooleantrue (default) = route via market AMM if one exists. false = orderbook-only.
limitAprnumberLimit APR as DECIMAL (0.05 = 5%). Required for limit orders; optional for market (rate guard).
slippagenumberMax slippage as DECIMAL (0.05 = 5%, NOT 5). Effective only for FOK market orders — backend silently ignores it for GTC/ALO/SOFT_ALO (those are guarded by limitApr/limitTick instead). If omitted, def…
timeInForcestringOrder time-in-force policy. Defaults when omitted: orderType=limit → GTC; orderType=market → FOK. Values: GTC = rest unmatched remainder on book until filled or cancelled (standard limit). IOC = t…

deposit

Simulate or execute depositing ERC-20 collateral from your wallet into your Boros margin account on Arbitrum. Default mode is 'simulate' — ALWAYS run mode:'simulate' first to preview pre/post collateral balance, maintenance margin, and margin ratio, then ONLY call mode:'execute' AFTER explicit user confirmation. mode:'execute' opens a browser page; YOUR WALLET (MetaMask/Rabby) signs — the agent key is NOT used. Two on-chain txs required (approve + deposit), and you pay gas in ETH on Arbitrum. Native ETH is not auto-wrapped — hold WETH (tokenId 2) instead. Use `humanAmount` rather than `…

ParameterTypeDescription
tokenId *integerCollateral token ID (see get_assets). Asset to deposit (must have isCollateral:true).
amountstringRaw amount (in the token's smallest unit; e.g. 1000000 = 1 USDT0). Provide either amount or humanAmount.
humanAmountnumberHuman-readable amount (e.g. 100.5 USDT). Provide either amount or humanAmount.
marketIdintegerMarket ID (positive integer 1..2^24-1; resolve via get_markets). Isolated-margin deposit (market must already be entered). Omit for cross margin.
modestring"simulate" (default): preview pre/post account state. "execute": opens a browser page for wallet signing. ALWAYS simulate first.

withdraw

Request an on-chain withdrawal of collateral from your CROSS margin account. Opens a browser page; YOUR WALLET (root EOA) signs — the agent key is NOT used. Two-step withdrawal: this submits the request, then the protocol auto-finalizes after a cooldown (~15 min on mainnet; can be longer if your account is flagged by the on-chain withdrawal-policy enforcement). There is no separate claim step. To withdraw isolated collateral, first run `cash_transfer({direction:"ISOLATED_TO_CROSS"})`. IMPORTANT: re-running this while a withdrawal is already pending ADDS the new amount to the existing pending…

ParameterTypeDescription
tokenId *integerCollateral token ID (see get_assets). Asset to withdraw.
amountstringRaw amount (in the token's smallest unit). Provide either amount or humanAmount.
humanAmountnumberHuman-readable amount (e.g. 50.0 USDT). Provide either amount or humanAmount.

vault_pay_treasury

Top up your off-chain gas budget by pulling collateral tokens DIRECTLY from your EOA wallet (instead of from already-deposited margin). Opens a browser page; YOUR WALLET (root EOA) signs Router.vaultPayTreasury(tokenId, amount) and you pay gas. Tokens transfer to the Boros Router; the backend credits the equivalent USD value to your gas budget after the tx confirms. PREFER `pay_gas` when you have margin collateral — it is agent-signed (no wallet popup) and cheaper. Use `vault_pay_treasury` only when (a) you have not yet deposited collateral, or (b) your agent is unavailable, or (c) you speci…

ParameterTypeDescription
tokenId *integerCollateral token ID (see get_assets). Must have isCollateral:true.
amountstringRaw amount in token smallest unit (e.g. 1000000 = 1 USDT0). Provide either amount or humanAmount.
humanAmountnumberHuman-readable amount (e.g. 0.5 WETH). Provide either amount or humanAmount.

cancel_withdraw

Cancel YOUR pending COLLATERAL WITHDRAWAL that is still queued (cooldown or post-cooldown but pre-finalize). Opens a browser page; YOUR WALLET (root EOA) signs — the agent key is NOT used. The contract returns the entire accumulated `user.unscaled` balance back to your cross account; subsequent `withdraw` calls restart the cooldown clock from zero. Use this for vault-withdrawal cancellation only. Do NOT use for: cancelling limit orders (use `cancel_orders`), revoking a trading agent (use `revoke_agent`), or cancelling a deposit (deposits are atomic — no cancel exists). Run `get_collateral`…

ParameterTypeDescription
tokenId *integerCollateral token ID (see get_assets). Asset whose pending withdrawal to cancel.
forcebooleanSkip the no-pending-detected guard and submit the on-chain cancel anyway. Use only when you believe the indexer is stale (e.g. you JUST submitted withdraw and it has not propagated yet). Default false…

setup_agent

Bootstrap the MCP trading agent on Arbitrum One (chainId 42161). Opens a localhost browser page; the user connects MetaMask/Rabby and signs ONE EIP-712 typed message (NOT a transaction — no gas paid by the user; send-txs-bot relays the approval on-chain). Required before any trading tool can run. The agent is bounded by contract to 12 trade/AMM router selectors — it CANNOT withdraw, transfer cash to other wallets, change account managers, or approve other agents. The browser page asks for a PASSWORD that encrypts the agent key on disk; an empty password is allowed only if the user ticks an…

ParameterTypeDescription
expiryDaysintegerApproval duration in days (1–365). Default 30. The signing page also lets the user adjust this before signing.
forcebooleanOverwrite an already-configured local agent that has not yet expired. Only use AFTER calling revoke_agent on the old agentAddress — otherwise the old approval stays live on-chain until its original…

agent_status

Check agent approval status. Two modes: LOCAL MODE (no args, or only `accountId`): inspect THIS MCP install's configured agent. Returns `configured`, `locked`, `ready`, `passwordProtected` (false → on-disk key is encrypted with empty password and will auto-decrypt on every MCP startup; surfaces a `securityWarning`), `agentAddress`, `rootAddress`, `accountId` (always 0 for the MCP), `chainId` (42161), `expiryDate`, `isExpired`, `daysRemaining`, `secondsRemaining`, `humanRemaining`, `createdAt`, plus on-chain reconciliation against the Boros Router (`GET /v1/agents/expiry-time`). Sets `onChai…

ParameterTypeDescription
accountIdintegerAccount ID 0..255, default 0. LOCAL MODE: ignored (MCP always uses 0). LOOKUP MODE: queries that triple.
agentAddressstringAgent wallet address to look up. Set this (with userAddress) to switch to LOOKUP MODE for a third-party agent.
userAddressstringYour wallet address (0x...). Required when agentAddress is set (LOOKUP MODE).

revoke_agent

Revoke an on-chain trading-agent approval. Opens a browser page; YOUR WALLET (root EOA) signs and broadcasts Router.revokeAgent on Arbitrum (you pay gas). REVOCATION IS IRREVERSIBLE — to use the agent again you must run `setup_agent` (with `force:true`) to issue a fresh approval. If `agentAddress` matches the agent currently used by this MCP install, every subsequent place_order / cancel_orders / pay_gas will revert at agentExecute until you re-run `setup_agent`. Re-running `setup_agent` ALONE does NOT revoke — it only generates a new key locally; the old on-chain approval keeps signing ri…

ParameterTypeDescription
accountIdintegerAccount ID — only 0 (the main/cross account) is supported today.
agentAddressstringAgent wallet address to revoke (0x...). Defaults to the agent currently configured in this MCP install.

boros_glossary

Returns the Boros domain glossary (apr, side, marketAcc, cross/isolated, tick, YU, agent, router), chain constants, and `docs` — pointers to the canonical Boros documentation sources (incl. the historical-data.boros.finance bulk archive) to WebFetch when you need more than the tools inline. Call once when uncertain about a term or where to read more. Reference only — does not invoke any other tool.