Skip to main content
Glama
shioaji-mcp

shioaji-mcp

by xianyuntang

get_contract

Fetches contract specifications—name, reference, price limits, unit, day-trade, margin, and short info—for a stock, futures, option, or index code.

Instructions

Contract details: name, reference, limit up/down, unit, day-trade, margin/short info... code: stock '2330', continuous futures 'TXFR1'/'TXFR2', option 'TXO31200G6', index 'IX0001' (TAIEX).

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": {
      "code": "<code>"
    },
    "name": "get_contract"
  }
}

Input Schema

NameRequiredDescriptionDefault
codeYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

B3.3/5.0
Behavior2/5

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

No annotations are provided, so the description carries the full behavioral burden. It lists returned fields but does not state that the operation is read-only, whether authentication is required, how invalid codes are handled, or any rate-limit behavior.

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 two sentences, front-loads the purpose and returned fields, then supplies code examples. It is efficient, though the trailing ellipsis and informal field list slightly reduce polish.

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?

For a simple one-parameter lookup, the description covers purpose, parameter formats, and returned fields. However, with no output schema and no annotations, it does not explain the response structure or error behavior, leaving some gaps for an agent.

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 description coverage is 0%, so the description must compensate for the single 'code' parameter. It does so with concrete examples for stock ('2330'), continuous futures ('TXFR1'/'TXFR2'), option ('TXO31200G6'), and index ('IX0001'), giving an agent clear format guidance.

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 resource ('Contract details') and lists the fields returned, making the retrieval purpose clear. It does not explicitly differentiate from market-data siblings like get_snapshots or get_kbars, but the contract-specification focus is evident.

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?

There is no explicit when-to-use guidance, no mention of alternatives, and no prerequisites. The code-format examples help with parameter usage but do not tell an agent when this tool should be selected over siblings.

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