Skip to main content
Glama
acidsolution

Schwab MCP Server

by acidsolution

query_market_data

Execute SQL queries to analyze loaded market data, including price history and options chains, for financial research and decision-making.

Instructions

Run SQL query against loaded market data (price_history and options tables). First use load_price_history or load_option_chain to load data, then query it. Only SELECT queries are allowed. Use get_data_schema to see table schemas and example queries.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
sqlYesSQL SELECT query to run against loaded market data. Available tables: 'price_history' (OHLCV data) and 'options' (option chain with Greeks). Only SELECT queries are allowed.
Behavior4/5

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

With no annotations provided, the description carries the full burden of behavioral disclosure. It effectively communicates key constraints: data must be pre-loaded, only SELECT queries are permitted, and specific tables are available. However, it doesn't mention potential limitations like query timeout, result size limits, or error handling, leaving some behavioral aspects unspecified.

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 efficiently structured with three sentences that each serve a distinct purpose: stating the tool's function, providing prerequisites and constraints, and directing to related tools. There is no wasted text, and critical information is front-loaded.

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

Completeness4/5

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

Given the tool's complexity (SQL query execution with dependencies) and lack of annotations/output schema, the description is mostly complete. It covers purpose, prerequisites, constraints, and related tools. However, it doesn't explain what the query returns (e.g., result format, error responses), which would be helpful since there's no output schema.

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 description coverage is 100%, so the schema already fully documents the single 'sql' parameter. The description adds minimal value beyond the schema by reiterating that it's a SELECT query against specific tables, but doesn't provide additional syntax, format examples, or constraints not already in the schema description.

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 tool's purpose with specific verbs ('run SQL query') and resources ('against loaded market data'), explicitly naming the tables ('price_history and options tables'). It distinguishes from siblings by specifying this is for querying loaded data, unlike tools like get_quote or load_price_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?

The description provides explicit usage instructions: 'First use load_price_history or load_option_chain to load data, then query it' and 'Only SELECT queries are allowed.' It also directs users to get_data_schema for table schemas and examples, clearly differentiating when to use this tool versus alternatives.

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/acidsolution/schwab-mcp-server'

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