Skip to main content
Glama

get_stock_price

Read-only

Stock price for a listed company: latest close or a historical series. Supply ticker or company_name (at least one).

Mode is automatic:

  • Latest (days=0 and no dates, default): most recent completed- session close via web search, with freshness_status (live / recent / stale), is_usable_for_live_quote, age_seconds and age_trading_days. Cached for prefer_cache_seconds; force_refresh=true bypasses. With require_live=true a stale result fails with failure_kind="stale_price" and best_observation.

  • History (days>0 or start_date / end_date as YYYY-MM-DD, dates take precedence): daily closes from Clarifo's database (T-1, up to 1825 days) as series of {date, close, volume} plus summary (total_return_pct, high/low, significant_moves >= 5 %).

Chart: per the server "Charts" guidance; in ChatGPT call render_chart(source_tool="get_stock_price", source_args=, output="python").

To explain a move in a window, combine with company_events, search_filings and search_filing_content for those dates.

Args: share_class: Pick a share class where a company lists several.

Returns (latest): {ticker, price, currency, trading_date, source, freshness_status, ...}; (history): {company, ticker, currency, period, summary, series}. Error: {"error", "failure_kind"}.

Tool call template

This tool declares no required parameters. Add optional parameters from the input schema as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {},
    "name": "get_stock_price"
  }
}

Input Schema

NameRequiredDescriptionDefault
daysNo
tickerNo
end_dateNo
start_dateNo
share_classNo
company_nameNo
require_liveNo
force_refreshNo
prefer_cache_secondsNo

Output Schema

NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.7/5.0
Behavior4/5

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

Beyond the annotations (readOnly, openWorld, non-idempotent) it discloses real behavior: latest comes from web search while history comes from the Clarifo database with T-1 lag, caching for prefer_cache_seconds, force_refresh bypass, and a documented failure path (require_live -> failure_kind='stale_price' plus best_observation). This is well past what the annotations carry; it only stops short of stating rate limits or the source's own reliability caveats.

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 one-line purpose, then a mode block, a chart note, and an Args-style section. The 'Returns' paragraph mostly restates what the output schema already declares, which is the only genuinely redundant material; the rest of the text earns its place.

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 9-parameter, dual-mode tool with no schema descriptions, this covers input rules, mode precedence, caching semantics, failure kinds, and cross-tool composition. An agent has everything needed to choose a mode and call it correctly on the first try.

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

Parameters5/5

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

Schema coverage is 0%, so the description must carry every parameter, and it effectively does: ticker/company_name with the at-least-one rule, days and date precedence, share_class for multi-class listings, require_live's failure behavior, force_refresh's bypass of the cache, and prefer_cache_seconds as the cache window. Meaning is added, not restated.

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+resource ('Stock price for a listed company') and immediately splits into the two supported shapes: latest close vs. a historical series. An agent can tell this apart from get_company_snapshot or get_valuation_history without opening the schema.

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?

Mode selection is spelled out deterministically ('days=0 and no dates' -> latest; 'days>0 or start_date/end_date' -> history, with dates taking precedence). It also names when to pair it with company_events/search_filings to explain a move, and gives the explicit chart hand-off arguments.

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.