Skip to main content
Glama

Exchange Rate

exchange_rate
Read-onlyIdempotent

Twelve Data live forex exchange rate for a currency pair symbol (e.g. 'EUR/USD'). Optional dp (decimal places) and timezone. Returns rate, timestamp, and pair identifiers.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
dpNoDecimal places for the rate (0–11).
formatNoResponse format: "JSON" (default) or "CSV".
symbolYesTicker/symbol. Stocks e.g. "AAPL", "MSFT"; forex "EUR/USD"; crypto "BTC/USD"; ETFs "SPY". Comma-separate for a batch (e.g. "AAPL,MSFT"). Market indices (SPX, N225, …) need a Grow-or-higher Twelve Data key passed via _apiKey — the shared key cannot quote them.
timezoneNoOptional timezone, e.g. "America/New_York" or "UTC".

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
rateNo
symbolNo
timestampNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed7 schema fields changed
    • changedInput schema / properties / symbol / description
      Previous value: -"Ticker/symbol. Stocks e.g. \"AAPL\", \"MSFT\"; forex \"EUR/USD\"; crypto \"BTC/USD\"; ETFs \"SPY\"; indices \"IXIC\". Comma-separate for a batch (e.g. \"AAPL,MSFT\")."New value: +"Ticker/symbol. Stocks e.g. \"AAPL\", \"MSFT\"; forex \"EUR/USD\"; crypto \"BTC/USD\"; ETFs \"SPY\". Comma-separate for a batch (e.g. \"AAPL,MSFT\"). Market indices (SPX, N225, …) need a Grow-or-higher Twelve Data key passed via _apiKey — the shared key cannot quote them."
    • removedOutput schema / properties / code
      Removed value: -{
      -  "description": "Response code",
      -  "type": "number"
      -}
    • removedOutput schema / properties / message
      Removed value: -{
      -  "description": "Response message",
      -  "type": "string"
      -}
    • addedOutput schema / properties / rate
      Added value: +{
      +  "type": "number"
      +}
    • removedOutput schema / properties / status
      Removed value: -{
      -  "description": "Response status",
      -  "type": "string"
      -}
    • addedOutput schema / properties / symbol
      Added value: +{
      +  "type": "string"
      +}
    • addedOutput schema / properties / timestamp
      Added value: +{
      +  "type": "number"
      +}
  2. Changed4 schema fields changed
    • addedInput schema / properties / dp / description
      Added value: +"Decimal places for the rate (0–11)."
    • addedInput schema / properties / format / description
      Added value: +"Response format: \"JSON\" (default) or \"CSV\"."
    • addedInput schema / properties / symbol / description
      Added value: +"Ticker/symbol. Stocks e.g. \"AAPL\", \"MSFT\"; forex \"EUR/USD\"; crypto \"BTC/USD\"; ETFs \"SPY\"; indices \"IXIC\". Comma-separate for a batch (e.g. \"AAPL,MSFT\")."
    • addedInput schema / properties / timezone / description
      Added value: +"Optional timezone, e.g. \"America/New_York\" or \"UTC\"."
  3. Changed2 schema fields changed
    • addedInput schema / examples
      Added value: +[
      +  {
      +    "symbol": "EUR/USD"
      +  },
      +  {
      +    "dp": 4,
      +    "symbol": "GBP/USD"
      +  }
      +]
    • changedOutput schema / (root)
      Previous value: -nullNew value: +{
      +  "properties": {
      +    "code": {
      +      "description": "Response code",
      +      "type": "number"
      +    },
      +    "message": {
      +      "description": "Response message",
      +      "type": "string"
      +    },
      +    "status": {
      +      "description": "Response status",
      +      "type": "string"
      +    }
      +  },
      +  "type": "object"
      +}
  4. First observed

TDQS

B3.1/5.0
Behavior3/5

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

Annotations already cover safety (readOnly, idempotent, non-destructive). The description adds return format (rate, timestamp, pair identifiers) and mentions optional dp/timezone, but doesn't disclose that batch requests are possible or that indices require a special API key (though that's in the schema). It adds some value beyond annotations but not rich behavioral context.

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?

The description is a single, front-loaded sentence with no fluff. However, it omits important capabilities (batch, CSV format, key requirement) that could have been included without much length. Still, it's efficient and easy to parse.

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

Completeness2/5

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

Despite a rich schema and output schema, the description misrepresents the tool as forex-only, omits batch and API-key nuances, and provides no guidance relative to siblings. For a tool with 4 parameters and many similar options, the description should clarify scope and usage more thoroughly.

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 the baseline is 3. The description redundantly mentions dp and timezone without adding meaning beyond the schema. It doesn't explain the format parameter or the key requirement for indices, all of which are already in the schema. No extra value is provided.

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

Purpose4/5

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

The description states a specific verb+resource ('live forex exchange rate') and gives an example symbol, but it narrows the scope to forex while the schema actually accepts stocks, crypto, ETFs, and indices. This understates the tool's breadth and doesn't explicitly differentiate it from siblings like price or quote, though the return info (rate, timestamp, pair identifiers) helps.

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

Usage Guidelines2/5

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

No guidance on when to use this tool versus alternatives such as currency_conversion, price, or quote. The description implies usage for exchange rates but provides no explicit context, exclusions, or comparisons. An agent would have to infer the right choice from the name and schema alone.

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.