Skip to main content
Glama

Get broker price (bid/ask)

get_quote
Read-only

Get the CURRENT price (bid and ask) of a symbol directly from the broker of one of the user's accounts. This is the price that account actually trades at: market orders fill at it (buy at the ask, sell at the bid) and its stop loss / take profit trigger on it.

Two price sources exist in TraderWAI:

  • get_ohlc / get_chart: TraderWAI market feed. Same for everyone, with history, for analysis. It can differ slightly from each broker (spread, feed and timing).

  • get_quote: the broker's own live price for one account. No history.

WHEN TO USE EACH: analyzing → get_ohlc / get_chart. Placing or proposing an order → get_quote first, every time. Rules for orders:

  • Never take entry, stop loss or take profit levels from the feed price: compute them from this bid/ask (a market BUY fills at the ask, a market SELL at the bid).

  • A BUY LIMIT must be below the ask and a SELL LIMIT above the bid. On the wrong side the broker fills it immediately at market (or rejects it). If the level the user asked for is on the wrong side, do not send the order: explain it and ask what they meant.

  • BUY STOP above the ask, SELL STOP below the bid (breakout entries; execute_trade with executionType "STOP" on TradeLocker, cTrader, MetaTrader, Capital.com, eToro, Bybit, Toobit, Kraken and tastytrade; elsewhere create_conditional_order).

  • The stop loss of a BUY must be below the bid and the take profit above it (the reverse for a SELL).

  • There is no single "current price": each broker account has its own. Quote the account you are going to trade; if the user has several accounts and did not say which, ask or quote each one.

Supported on TradeLocker, cTrader, Match-Trader, MetaTrader 4/5, Capital.com, eToro, Binance spot, Kraken spot, Bybit, Toobit and tastytrade (futures, *_FUT symbols) accounts. On a platform without live broker prices it returns an error: then use get_ohlc as a reference. The response also includes the latest TraderWAI feed price (traderwaiFeedPrice) so you can see the difference. It connects to the broker in real time and may take a few seconds.

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": {
      "brokerAccountId": "<brokerAccountId>",
      "symbol": "<symbol>"
    },
    "name": "get_quote"
  }
}

Input Schema

NameRequiredDescriptionDefault
symbolYesSymbol in TraderWAI format (e.g. "EUR_USD", "XAU_USD", "NAS100_USD"); it is mapped to the broker's own symbol name.
brokerAccountIdYesThe broker account ID (from get_broker_accounts). Prices can differ between brokers.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.6/5.0
Behavior5/5

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

Annotations already cover read-only and open-world, and the description adds substantial context beyond them: the call hits the broker live and may take seconds, it errors on platforms without live broker prices, and the payload includes traderwaiFeedPrice for comparison. The per-account price independence and the supported-platform list are exactly the kind of preconditions an agent cannot get from the schema.

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

Conciseness4/5

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

Front-loaded with the definition and the two-source distinction, then organized under a clear WHEN TO USE EACH heading with bullets. It is long for a two-parameter read tool and the order-placement rules arguably belong with execute_trade, but every rule is tied to why this price must be fetched first.

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?

For a simple two-param read tool this is more than complete: it covers source of truth, latency, failure mode with a fallback, platform coverage, multi-account handling, and the extra return field. Nothing an agent needs to call it correctly is missing.

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

Parameters3/5

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

Schema coverage is 100%, so both parameters are already fully documented, including the TraderWAI symbol format and that prices differ between brokers. The description reinforces that brokerAccountId must be the account about to be traded, which is useful but largely restates the schema field descriptions rather than adding new semantics.

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?

Opens with a specific verb and resource ('Get the CURRENT price (bid and ask) of a symbol directly from the broker') and immediately scopes it to a single account. It explicitly distinguishes itself from get_ohlc/get_chart by naming both and describing the difference in feed source, spread and history.

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?

Gives an explicit routing rule ('analyzing → get_ohlc / get_chart. Placing or proposing an order → get_quote first, every time') plus concrete when-not guidance (unsupported platform → error → fall back to get_ohlc). It also states the multi-account ambiguity case and tells the agent to ask or quote each account.

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.

Resources