Skip to main content
Glama

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

Forex Swap Cost (Live)

workflow.run_forex_swap_cost_live
Read-only

Total swap/rollover cost (or credit) for holding a forex position overnight, converted to a given account currency via a live FX rate (same TrueFX/frankfurter.app source as the other forex _live tools). swapPerLotPerNight is still always a manual input: swap rates are broker-set, with no free live feed available for them. Precious-metal pairs (XAU, XAG, XPT, XPD) are refused with an error, because their pip and lot size differ by broker. Edge cases: same input rules as workflow.run_forex_swap_cost (nights a whole number, swap any sign); when no rate is found for the account currency, available is false and no figure is returned. Not covered: the triple swap on Wednesday and swap rates that change during the hold. Use when user asks "how much will holding this position overnight cost me in my account currency?" and it differs from the pair's own quote currency. Returns everything workflow.run_forex_swap_cost does, plus accountCurrency, totalSwapAccount, fxRate, fxSource, available (false + error if no rate could be found). If available is false, do not use any result field (computed figures and any verdict are null or empty), so read available first.

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>",
      "units": "<units>",
      "swapPerLotPerNight": "<swapPerLotPerNight>",
      "nights": "<nights>",
      "accountCurrency": "<accountCurrency>"
    },
    "name": "workflow.run_forex_swap_cost_live"
  }
}

Input Schema

NameRequiredDescriptionDefault
pairYesCurrency pair in BASE/QUOTE format, e.g. "EUR/USD"
unitsYesPosition size in base-currency units
nightsYesNumber of nights the position is held
accountCurrencyYes3-letter account currency code, e.g. "GBP"
swapPerLotPerNightYesSwap rate per standard lot per night, in the pair's quote currency. Negative = cost, positive = credit.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Added

TDQS

A4.9/5.0
Behavior5/5

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

Beyond the readOnly/openWorld/non-destructive annotations, the description discloses that swap rates are always manual broker-set inputs with no free live feed, that XAU/XAG/XPT/XPD are refused, that missing FX rates set available=false, and that Wednesday triple swaps and intra-hold rate changes are not covered. It also explains the return fields and instructs the caller to read available first.

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

Conciseness5/5

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

The description is long but front-loaded and well organized: purpose first, then constraints, edge cases, exclusions, usage trigger, and return behavior. Each sentence adds operational value for a tool with meaningful caveats, and nothing is redundant.

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 carries the full burden and does so thoroughly: it lists added return fields, explains available=false behavior, states refusal cases, and identifies what is not covered. An agent has enough information to call the tool and interpret the result safely.

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 already 100%, so the baseline is 3. The description still adds useful meaning beyond the schema: it explains why swapPerLotPerNight is a manual broker-set input, clarifies that nights must be a whole number and swap can have any sign, and frames accountCurrency as the target for live FX conversion.

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 description states a precise verb and resource: computing total swap/rollover cost for holding a forex position overnight, converted to the account currency via a live FX rate. It clearly distinguishes this live tool from workflow.run_forex_swap_cost and the other forex _live tools, and calls out precious-metal pair refusal.

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

Usage Guidelines5/5

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

It gives an explicit use case ('how much will holding this position overnight cost me in my account currency?') and the key condition that this tool is for when the account currency differs from the pair's quote currency. It also names the non-live sibling for shared input rules and return shape, and states the precious-metals exclusion.

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.