Skip to main content
Glama

Tapetide - Indian Stock Market MCP

Add Stocks to Portfolio

add_portfolio_stocks
Destructive

Add one or more stocks to the user's portfolio, merging duplicates by weighted-average price. Accepts a single add, a bulk list, or holdings the user pasted from a broker CSV/table (parse it into the holdings array yourself). Example: "Add RELIANCE 10 shares at ₹1,350" → holdings:[{symbol:"RELIANCE",quantity:10,avg_price:1350}]. STRIP exchange suffixes before calling — -EQ, -BE, -SM, -ST, -BZ, -BL, -RE, -IV, -RR, .NS, .BO — and pass plain NSE symbols (APS-SM → APS; SME stocks are supported). When the user has stated symbol, quantity and price, add them directly. When you PARSED or inferred the holdings (broker CSV, a pasted table, a screenshot), show the parsed rows for confirmation first, and ask rather than guess a missing or ambiguous field. Use search_stocks if a symbol does not resolve. Call read_me for the full broker-CSV procedure.

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": {
      "holdings": "<holdings>"
    },
    "name": "add_portfolio_stocks"
  }
}

Input Schema

NameRequiredDescriptionDefault
holdingsYesArray of stocks to add (1-100 items)
portfolioNoOptional. The portfolio's name or id, from the index get_user_portfolio returns. Omit to use the default portfolio.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changed
    • addedInput schema / properties / portfolio
      Added value: +{
      +  "description": "Optional. The portfolio's name or id, from the index get_user_portfolio returns. Omit to use the default portfolio.",
      +  "type": "string"
      +}
  2. First observed

TDQS

A4.6/5.0
Behavior4/5

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

Beyond annotations it discloses the important non-obvious behavior that duplicates merge by weighted-average price, which an agent could not infer from destructiveHint/idempotentHint alone. It does not say whether the call is reversible or what happens to positions not mentioned, so it stops short of full behavioral coverage for a destructive mutation.

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?

Front-loaded with purpose and effect, then format rules, then the confirmation policy. Dense with zero filler, though the long enumerated suffix list and the example add bulk that could have been delegated to read_me or the schema.

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

Completeness5/5

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

For a two-parameter mutation with no output schema, the description covers the input construction, the confirmation/ambiguity policy, symbol normalization, and a pointer to read_me for the lengthy CSV procedure. Nothing an agent needs to invoke it correctly is missing.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is already 100%, but the description still adds real meaning: it shows the exact holdings object shape with a worked example, mandates stripping exchange suffixes before calling (with the explicit suffix list) so symbol resolution succeeds, and clarifies that portfolio may be omitted to use the default.

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?

Specific verb and resource ("Add one or more stocks to the user's portfolio") plus the distinguishing behavior of merging duplicates by weighted-average price. That merge semantic cleanly separates it from update_portfolio_stock and remove_portfolio_stocks without needing to open either schema.

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?

It gives an explicit decision rule: add directly when the user stated symbol, quantity and price; show parsed rows for confirmation and ask rather than guess when holdings were parsed or inferred. It also names the escape hatches (search_stocks for unresolved symbols, read_me for the broker-CSV procedure).

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

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.