Skip to main content
Glama
drasticstatic

robinhood-mcp

robinhood_get_quote

Get real-time stock quotes for any ticker symbol. Input a symbol like AAPL to retrieve current price and market data.

Instructions

Get real-time quote for a stock symbol.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
symbolYesStock ticker symbol (e.g., "AAPL", "TSLA")

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Implementation Reference

  • Registration of the 'robinhood_get_quote' tool as an MCP tool via @mcp.tool() decorator. It calls get_quote() from the tools module.
    @mcp.tool()
    def robinhood_get_quote(symbol: str) -> dict:
        """Get real-time quote for a stock symbol.
    
        Args:
            symbol: Stock ticker symbol (e.g., "AAPL", "TSLA")
    
        Returns quote data including last trade price, bid, ask,
        previous close, and trading status.
        """
        _ensure_logged_in()
        return get_quote(symbol)
  • The actual handler/implementation: get_quote() normalizes the symbol, calls rh.stocks.get_quotes via the safe wrapper, and returns the first result.
    def get_quote(symbol: str) -> dict[str, Any]:
        """Get real-time quote for a stock symbol.
    
        Args:
            symbol: Stock ticker symbol (e.g., "AAPL").
    
        Returns:
            Quote data including last_trade_price, bid, ask, etc.
        """
        symbol = _normalize_symbol(symbol)
        result = _safe_call(rh.stocks.get_quotes, symbol)
    
        if isinstance(result, list) and len(result) > 0:
            return result[0]
        raise RobinhoodError(f"No quote found for symbol: {symbol}")
  • Helper function _normalize_symbol() that validates and uppercases ticker symbols, used by get_quote().
    def _normalize_symbol(symbol: str) -> str:
        """Normalize and validate ticker symbols."""
        if not symbol or not isinstance(symbol, str):
            raise RobinhoodError("Symbol must be a non-empty string")
        symbol = symbol.upper().strip()
        if not symbol:
            raise RobinhoodError("Symbol must be a non-empty string")
        return symbol
  • Helper function _safe_call() that wraps robin_stocks API calls with error handling, used by get_quote().
    def _safe_call(func: Callable[..., Any], *args, **kwargs) -> Any:
        """Safely call a robin_stocks function with error handling.
    
        Args:
            func: The robin_stocks function to call.
            *args: Positional arguments.
            **kwargs: Keyword arguments.
    
        Returns:
            The function result.
    
        Raises:
            RobinhoodError: If the call fails.
        """
        try:
            result = func(*args, **kwargs)
            if result is None:
                raise RobinhoodError("API returned None - you may need to login first")
            return result
        except RobinhoodError:
            raise
        except Exception as e:
            raise RobinhoodError(f"API call failed: {e}") from e
  • Input schema for robinhood_get_quote derived from function signature: takes a 'symbol: str' parameter and returns a dict.
    @mcp.tool()
    def robinhood_get_quote(symbol: str) -> dict:
        """Get real-time quote for a stock symbol.
    
        Args:
            symbol: Stock ticker symbol (e.g., "AAPL", "TSLA")
    
        Returns quote data including last trade price, bid, ask,
        previous close, and trading status.
Behavior3/5

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

No annotations are provided, so the description carries full burden. It states 'real-time quote' but doesn't disclose potential delay, market hours, or authentication needs. Adequate but minimal.

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?

Single sentence with no wasted words. Could be more informative without losing conciseness, but it is well-structured for its length.

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

Completeness3/5

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

Given the presence of an output schema, the description adequately indicates the tool's purpose. However, it lacks context on usage constraints or data updates, making it marginally sufficient.

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?

The input schema has 100% description coverage for the single parameter. The description adds no extra meaning beyond the schema, so baseline 3 is appropriate.

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 clearly states the verb 'Get', the resource 'real-time quote', and the input 'stock symbol'. It is specific and distinguishes from sibling tools (e.g., robinhood_get_dividends, robinhood_get_earnings).

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 is provided on when to use this tool versus alternatives, nor any prerequisites or exclusions. The description is too brief to guide selection among similar quote-related tools.

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

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/drasticstatic/robinhood-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server