Skip to main content
Glama

add_trade

Add a trade record (buy or sell) to a stock position. Specify stock ID, market, action, shares, price, and trade date.

Instructions

新增一筆交易記錄到持倉(買入或賣出),執行前會請使用者確認。必填:stockId、market、action(buy/sell)、shares、price、tradeDate。

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
stockIdYes股票代號,例如 2330
marketYesTW 或 US
actionYesbuy 或 sell
sharesYes股數(台股為整數張數×1000)
priceYes成交價格
tradeDateYes交易日期 YYYY-MM-DD
noteNo備註(選填)
Behavior3/5

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

The description adds the behavioral trait that it asks for user confirmation before executing. Annotations show readOnlyHint=false and destructiveHint=false, so no contradiction. However, it does not disclose other aspects like side effects, authorization needs, or error handling.

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 short and front-loaded with the core purpose and required fields. It is efficient at two sentences, though it could be slightly more structured (e.g., separating required vs optional clearly).

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 7 parameters (6 required) and no output schema, the description covers basic purpose and confirmation step. However, it lacks information on return values, error scenarios, and differentiation from similar update mutation. It is adequate but has gaps.

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 coverage is 100%, so the baseline is 3. The description merely lists required parameters without adding extra meaning beyond what the schema already provides. No additional value in parameter understanding.

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 function: adding a trade record (buy or sell) to a position. It specifies the required fields and the action types, distinguishing it from siblings like delete_trade and update_trade.

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 description mentions user confirmation before execution, implying it is a cautious operation. However, it does not explicitly state when to use this tool vs. update_trade or other alternatives. The context is clear but lacks exclusions.

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/kevinlin49361128-stack/stock-analyzer-mcp'

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