mcpserver.lol
registry/tradingcalc
Connection check verified live · 27h ago

tradingcalc

Crypto futures math: PnL, liquidation, position sizing, carry trade. 19 tools. Not AI estimates.

Tools 23
GitHub stars
Installs / wk
Licence
Transport streamable-http
Last checked 27h ago

Tools & capabilities

23 tools

Read from the running server on 27h ago.

primitive.average_entry input*symbol*exchangeCode
Calculate the weighted average entry price from multiple buy/sell fills (DCA). Use when user has filled at multiple prices and asks "what's my average entry?" Returns: averagePrice…
primitive.hedge_ratio leveragespotSize*hedgeRatiofundingRatePct
Calculate the short perpetual futures position size needed to hedge a spot holding. Use when user asks "how much should I short to hedge my BTC?" or "what margin do I need for a 10…
system.verify
Run the full regression suite — 22 canonical test vectors across all 12 calculators — and return a pass/fail report with counts and timestamp. Call this before using results in pro…
workflow.run_breakeven_planning side*sizeBase*entryPrice*feeOpenPctfeeClosePct
Calculate the break-even exit price that covers all trading fees. Use when user asks "what price do I need to just break even?" Returns: breakevenPrice, totalFees.
workflow.run_breakout_acceptance venue*candlestimeframeinstrument*prev_candlessession_date* +2
Market Profile breakout acceptance — did price accept (hold) beyond the value area / range, or reject back inside (fakeout)? Optional buy/sell delta. Use for "did the break above V…
workflow.run_carry_trade notional*hold_days*interval_hourstransfer_fee_pctfunding_rate_long*funding_rate_short*
Delta-neutral carry trade (funding arbitrage) analysis. Use when user asks "is this carry trade worth it?" — long on exchange A, short on exchange B, collect the funding rate sprea…
workflow.run_compound_funding reinvestPctdurationDays*intervalHoursfundingRatePct*initialCapital*
Project capital growth from reinvesting perpetual futures funding income (compounding carry). Use when user asks "how much will I make compounding 0.01% funding for 90 days?" or "w…
workflow.run_dca_entry side*entries*fee_open_pctfee_close_pct
DCA entry planner: weighted average entry price, breakeven, and per-level contribution from multiple fill prices and sizes. Use when user bought at several prices and asks "what's…
workflow.run_exit_target side*leverage*sizeBase*entryPrice*feeOpenPcttargetMode* +2
Calculate the exact exit price needed to hit a target PnL or ROE percentage. Use when user asks "at what price do I take profit to make $500?" or "where should I set TP for 20% ROE…
workflow.run_funding_arbitrage durationDays*positionSize*intervalHourstransferFeePctlongFundingRate*shortFundingRate*
Calculate funding rate arbitrage profit: annualized yield, net profit, and breakeven days for a long/short basis trade across two exchanges. Use when user asks "is this funding arb…
workflow.run_funding_breakeven side*size*hold_hours*entry_price*fee_open_pctfunding_rate* +1
Price move needed to cover funding cost + fees over a holding period. Use when user asks "how much does BTC need to move for me to profit after funding?" or "is funding killing my…
workflow.run_funding_cost days*side*sizeBase*entryPrice*fundingRate*
Calculate the total funding cost (or income) for holding a perpetual futures position. Use when user asks "how much funding will I pay holding X days?" or "is funding eating my pro…
workflow.run_liquidation_safety mmrside*leverage*entryPrice*
Calculate the liquidation price for an isolated-margin futures position. Use when user asks "where will I get liquidated?" or "how close is my liq price?". Returns: liquidationPric…
workflow.run_max_leverage mmraccountSize*volatilityPct*maxDrawdownPct*
Calculate the maximum safe leverage based on account size, max acceptable drawdown, and asset daily volatility. Use when user asks "what's the max leverage I should use on BTC?" or…
workflow.run_open_analysis venue*candlestimeframeinstrument*prev_candlessession_date* +1
Market Profile open analysis — where and how price opened vs the prior session value area. Returns open location, open type (OD/OTD/ORR/OAIR), key levels (VAH/VAL/VPOC/IB), and bul…
workflow.run_pnl_planning side*size*exitPrice*entryPrice*feeOpenPctfeeClosePct
Calculate net PnL, ROE, fees and gross profit/loss for a futures trade. Use when user asks "what's my profit/loss on this trade?" Returns: grossPnl, fees, netPnl, netPnlUsdt, roe (…
workflow.run_position_sizing side*leverageriskUsdt*stopLoss*entryPrice*feeOpenPct +1
Calculate the correct position size given a maximum risk in USDT and a stop-loss price. Use when user asks "how many coins should I buy?" or "size my position so I risk exactly $X"…
workflow.run_pre_trade_check mmrside*symbolexchangeleverage*risk_pct* +7
Full pre-trade decision card: orchestrates position sizing, breakeven, liquidation, and funding cost in one call. Use when user describes a full trade setup and asks "should I take…
workflow.run_risk_reward mmrside*leverage*risk_pct*stop_loss*entry_price* +4
Full risk:reward analysis — the single best tool when user describes a trade with entry, stop, and target. Calculates R:R ratio, position size, liquidation price, breakeven, and P&…
workflow.run_scale_out side*exits*total_size*entry_price*fee_open_pctfee_close_pct
Scale-out planner: P&L, ROI, and cumulative P&L for each partial exit level. Use when user wants to take profit at multiple targets — "close 30% at $90k, 30% at $95k, 40% at $100k…
workflow.run_scenario_planning side*size*deltasPct*entryPrice*feeOpenPctfeeClosePct
Run a scenario analysis: compute PnL for multiple price-change percentages at once. Use when user asks "show me my P&L if BTC moves -10%, -5%, +5%, +10%". Returns: array of { delta…
workflow.run_session_structure venue*candlestimeframeinstrument*prev_candlessession_date* +1
Market Profile day-type classifier — trend / balance / neutral_trend / normal / normal_var, from TPO, initial balance, range extension and value migration. Use for "is this a trend…
workflow.run_value_migration venue*candlestimeframeinstrument*prev_candlessession_date* +2
Market Profile value-area migration across sessions — is value migrating up, down, or overlapping (directional conviction vs balance)? Use for "is value moving higher day over day?…