Skip to main content
Glama

contract_qualify

Resolve a partial contract specification into a full contract ID and exchange before using market data or order tools.

Instructions

Qualify a partial contract specification to get the full conId and resolved exchange. MUST be called before using contracts in market data or order tools.

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": {
      "symbol": "<symbol>",
      "secType": "<secType>"
    },
    "name": "contract_qualify"
  }
}

Input Schema

NameRequiredDescriptionDefault
rightNoC or P for options
strikeNoStrike price for options
symbolYesSymbol to qualify
secTypeYesSecurity type
currencyNoCurrency (default: USD)
exchangeNoExchange (default: SMART)
multiplierNoContract multiplier
lastTradeDateOrContractMonthNoExpiry for options/futures

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv1.0.1

TDQS

A3.8/5.0
Behavior3/5

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

With no annotations, the description carries the full burden; it discloses the prerequisite ordering and the key return values (conId, resolved exchange), which is meaningful context. It is silent on failure behavior when a partial spec matches multiple contracts or is ambiguous, and doesn't state permissions or side-effect profile explicitly.

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?

Two sentences, both earning their place, with the capability stated first and the mandatory precondition second. Zero filler.

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?

For an eight-parameter resolution tool whose schema is fully documented, the description covers purpose, outputs, and the ordering constraint an agent most needs. The remaining gap is the ambiguity/multi-match outcome, which matters for correct handling but is a single missing detail rather than a structural omission.

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% with enums on secType and right, so the schema already documents all eight fields. The phrase 'partial contract specification' implies that only symbol and secType are required and the rest narrow the match, but the description adds no syntax or format detail beyond that.

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 uses a specific verb+resource ('Qualify a partial contract specification') and names the concrete outputs (full conId and resolved exchange), so an agent knows exactly what it produces. It does not explicitly differentiate itself from siblings like contract_details or contract_search, which keeps it from a 5.

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

Usage Guidelines4/5

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

The prerequisite is stated forcefully: it 'MUST be called before using contracts in market data or order tools,' which tells the agent when to reach for it. It offers no when-not guidance and does not name an alternative for resolving contracts another way.

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

Deploy Server

Other Tools