API Tools
rubin.trade
Provides trading account info, market data, and order books for a perpetual exchange.
ENDPOINT 1
https://mcp.mainnet.rubin.trade/mcp
MCP server metadata
- Name
- ritbit-mcp
- Version
- 0.0.1
Trading tools for the ritbit perpetuals DEX. Call whoami first to learn the master account, subaccount, and your authorization scope. Use list_markets to discover tickers. Reads (balance/positions/PnL) are keyed by the master account. Prefer GTT limit orders; mind the stateful-order rate limit (2/block, 20/100 blocks). AUTHORIZATION & AUTONOMY: this session may place, close and cancel orders on the configured subaccount within the operator guardrails (max notional, allowed markets — see whoami). The on-chain key scope PHYSICALLY cannot withdraw or transfer funds, so the worst case is bounded by the subaccount collateral. You are authorized to act on the user's stated intent without asking for confirmation before every single order; place the order, then report the verified confirmation.outcome. (For irreversible bulk actions like close_all_positions, do confirm first.) ORDERS vs POSITIONS: these are different. An open ORDER is a resting/untriggered instruction on the book; a POSITION is what you hold after an order fills. A filled market/limit order leaves NO open order — it becomes a position. If the user asks loosely "what is open?", check BOTH get_open_orders and get_positions, or just call get_portfolio (both at once). CLOSING/OPENING: use close_position / close_all_positions to exit (reduce-only market), and open_position for a market entry with an optional stop-loss/take-profit bracket. NEWS: get_news pulls the ritbit news feed (curated crypto/markets/business headlines). Factor it into "assess the situation" reads and answer "what's the latest?" — it has no importance score, so weigh impact from the content yourself. FUNDING: if an order fails for insufficient collateral, that is NOT an auth problem — do NOT suggest re-authorizing or reconnecting (a trading key can never deposit). Tell the user the balance is too low and point them to deposit (whoami.depositUrl), or reduce the order size.
Known tools 26
whoamiReport what this session controls: the master account/subaccount, whether it can trade or is read-only, and the exact on-chain authorization scope (which messages, which subaccount, and that it CANNOT withdraw/transfer).
Potential side effectsget_marketGet details for one perpetual market (clobPairId, atomicResolution, quantumConversionExponent, tick/step sizes, oracle price, status).
Inferred read-onlyget_orderbookGet the live orderbook (bids/asks) for a market, optionally truncated to a depth.
Inferred read-onlyget_candles_multiGet recent OHLCV candles for a market across MULTIPLE resolutions in one call — by default ALL indexer resolutions (1MIN, 5MINS, 15MINS, 30MINS, 1HOUR, 4HOURS, 1DAY) — so the agent can read the trend across timeframes at once.
Inferred read-onlyget_balanceGet the subaccount collateral (USDC asset position) and the on-chain wallet bank balances (gas).
Inferred read-onlyget_equityGet the subaccount summary: equity, freeCollateral, marginEnabled, open perpetual positions and asset positions.
Inferred read-onlyget_positionsGet perpetual POSITIONS with size, side, entryPrice, unrealizedPnl, realizedPnl and netFunding.
Inferred read-onlyget_open_ordersGet currently active ORDERS for the subaccount, optionally filtered by market and side.
Inferred read-onlyget_portfolioOne-call snapshot of everything the account has "open": equity & freeCollateral, every open POSITION (with notional, unrealized PnL and estimated liquidation price), every active ORDER (resting + untriggered TP/SL), and account margin risk.
Inferred read-onlyget_position_riskMargin health for the subaccount: equity, freeCollateral, total maintenance/initial margin, maintenanceMarginBufferUsd (the EXACT liquidation guard — liquidatable when < 0), marginUsageRatio (1.
Inferred read-onlyget_fillsGet executed fills for the subaccount, including price, size, fee and maker/taker liquidity.
Inferred read-onlyget_pnlGet historical PnL ticks for the subaccount (equity, totalPnl, netTransfers over time).
Inferred read-onlycancel_all_ordersCancel every OPEN order for the subaccount in a market (handles SHORT_TERM and LONG_TERM automatically).
Inferred read-onlyplace_stop_lossPlace a reduce-only Stop loss (conditional market order) that triggers at triggerPrice.
Inferred read-onlyplace_take_profitPlace a reduce-only Take profit (conditional market order) that triggers at triggerPrice.
Inferred read-onlyclose_positionClose all or part of an open perpetual position with a reduce-only MARKET order.
Inferred read-onlyclose_all_positionsFlatten EVERY open perpetual position with reduce-only MARKET orders (one per market).
Inferred read-onlyopen_positionEnter a NEW position with a MARKET order, sized by base `size` OR quote `notionalUsd` (exactly one required; notionalUsd converts at the oracle price and is floored to the step size).
Inferred read-onlyget_newsFetch the latest headlines from the ritbit news feed (curated crypto / markets / business channels, newest first).
Inferred read-onlyCONNECT WITH APPROVAL
Client installation
Review this server and its permissions before adding it. Secret placeholders must be set locally.
Codex
~/.codex/config.toml
[mcp_servers.ritbit-mcp]
url = "https://mcp.mainnet.rubin.trade/mcp"
enabled = true
Claude Code
.mcp.json
{
"mcpServers": {
"ritbit-mcp": {
"type": "http",
"url": "https://mcp.mainnet.rubin.trade/mcp"
}
}
}
Claude Desktop
Settings → Connectors → Add custom connector
Name: ritbit-mcp
Remote MCP URL: https://mcp.mainnet.rubin.trade/mcp
Add this remote URL as a custom connector in Claude Desktop. Availability depends on the user plan and workspace policy.
Cursor
.cursor/mcp.json
{
"mcpServers": {
"ritbit-mcp": {
"url": "https://mcp.mainnet.rubin.trade/mcp"
}
}
}
Visual Studio Code
.vscode/mcp.json
Add to Visual Studio Code{
"servers": {
"ritbit-mcp": {
"type": "http",
"url": "https://mcp.mainnet.rubin.trade/mcp"
}
}
}
Generic MCP
Client-specific MCP configuration
{
"name": "ritbit-mcp",
"transport": "streamable-http",
"url": "https://mcp.mainnet.rubin.trade/mcp"
}
MCP Inspector
Run the official MCP Inspector locally and enter the indexed Streamable HTTP endpoint.
TRUST AND VERIFICATION EVIDENCE
Loading Trust v2 evidence…
Checking the associated registrable domain. The BuiltWith key remains server-side.
Evidence is source-attributed and does not guarantee that a third-party server is safe. Risk labels are conservative metadata heuristics.