Skip to main content
Glama

TradingCalc MCP: Options, Forex, Risk Stats, Prediction Markets, On-Chain & Crypto Futures

Forex Breakeven

workflow.run_forex_breakeven
Read-only

Breakeven price for a forex position accounting for spread and round-trip commission, in pips and in price. Commission is quoted per standard lot (100,000 units) and expressed in the pair's own quote currency; because both commission and pip value scale with lot size, the commission-in-pips figure is independent of position size by construction. Precious-metal pairs (XAU, XAG, XPT, XPD) are refused with an error, because their pip and lot size differ by broker. Edge cases: entryPrice above zero; spreadPips and commissionPerLotRoundTrip zero or more (commission default 0, in the quote currency per 100,000 units round trip); The pair is BASE/QUOTE with two different ISO 4217 currency codes, in any letter case; crypto tickers and precious metals (XAU, XAG, XPT, XPD) are refused. A pip is 0.01 for a pair quoted in JPY and 0.0001 for every other pair, and a standard lot is 100,000 units. Not covered: swap, slippage, requotes, account-currency conversion, and a commission quoted per side or per million. Use when user asks "where's my true breakeven after spread and commission?". Returns: pipSize, commissionPips, totalCostPips, breakevenPrice.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "pair": "<pair>",
      "side": "<side>",
      "entryPrice": "<entryPrice>",
      "spreadPips": "<spreadPips>"
    },
    "name": "workflow.run_forex_breakeven"
  }
}

Input Schema

NameRequiredDescriptionDefault
pairYesCurrency pair in BASE/QUOTE format, e.g. "EUR/USD"
sideYesTrade direction: "long" or "short"
entryPriceYesEntry price in the pair's own quote terms, e.g. 1.0850 for EUR/USD
spreadPipsYesSpread at entry, in pips
commissionPerLotRoundTripNoRound-trip commission per standard lot, in the pair's own quote currency. Default 0 (pure-spread broker model).

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed2 schema fields changed
    • addedInput schema / properties / entryPrice / description
      Added value: +"Entry price in the pair's own quote terms, e.g. 1.0850 for EUR/USD"
    • addedInput schema / properties / side / description
      Added value: +"Trade direction: \"long\" or \"short\""
  2. Added

TDQS

A4.5/5.0
Behavior5/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Annotations already declare readOnlyHint=true, destructiveHint=false, openWorldHint=false, so safety is covered; the description adds genuinely new behavior: unsupported metals are refused with an error rather than silently mishandled, and the reason (broker-varying pip and lot size) is given. It also discloses the modeling assumptions (commission per side/per million not supported, no swap or slippage) and why commission-in-pips is position-size invariant.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness3/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The computational contract and input conventions are front-loaded, which is good, but the single dense paragraph repeats itself: the precious-metals refusal appears twice (once up front and again under "Edge cases"), and the pair format is restated in the same breath. Some duplication could be trimmed without losing information.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

With no output schema, the description compensates by naming the returned fields (pipSize, commissionPips, totalCostPips, breakevenPrice). All five parameters are semantically grounded, defaults are stated, and the modeling boundaries an agent needs in order to answer follow-up questions are enumerated.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 100%, so baseline is 3, but the description adds rules the schema does not carry: pip size is 0.01 for JPY-quoted pairs and 0.0001 otherwise, a standard lot is 100,000 units, commission is in the pair's own quote currency, and pair must be two distinct ISO 4217 codes in any letter case. These are load-bearing computational semantics, not repetition.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The opening sentence names the exact computation (breakeven price for a forex position), the cost components it accounts for (spread and round-trip commission), and the units returned (pips and price). The forex/spread/commission framing plus the explicit refusal of metals and crypto clearly separates it from generic siblings such as run_funding_breakeven or run_breakeven_planning.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

It gives an explicit trigger ("Use when user asks 'where's my true breakeven after spread and commission?'") and an explicit out-of-scope list (swap, slippage, requotes, account-currency conversion, commission quoted per side or per million), which implicitly routes the agent to run_forex_swap_cost for the swap case. It stops short of naming those sibling tools directly, so it is clear but not fully routing.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.