Skip to main content
Glama
Aaditya2502

TradeMCP

by Aaditya2502

trade_get_portfolio

Read-onlyIdempotent

Retrieve a snapshot of your portfolio: holdings, cash, equity, and unrealized profit/loss. Supports markdown or JSON output.

Instructions

Get the current portfolio: holdings, cash, equity, and unrealized P&L.

Read-only snapshot of all open positions with per-position and aggregate profit/loss.

Args: params (PortfolioInput): Validated input containing: - response_format (ResponseFormat): "markdown" (default) or "json"

Returns: str: Markdown summary, or JSON with this schema: { "as_of": str, # ISO 8601 UTC timestamp "cash_balance": float, "invested": float, "market_value": float, "total_equity": float, "unrealized_pnl": float, "position_count": int, "positions": [ { "symbol": str, "quantity": int, "avg_cost": float, "last_price": float, "invested": float, "market_value": float, "unrealized_pnl": float, "unrealized_pnl_pct": float } ] } On failure: "Error: "

Examples: - "How is my portfolio doing?" -> default markdown - "Give me my positions as JSON" -> response_format="json"

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
paramsYes

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes
Behavior4/5

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

Annotations indicate readOnlyHint, idempotentHint, and destructiveHint false, which align with the description's 'Read-only snapshot' statement. The description further clarifies output structure (markdown/json) and error messages, adding value beyond annotations.

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?

Well-structured with separate sections for description, arguments, returns, and examples. Every sentence adds value, and the front-loaded purpose sentence immediately communicates the tool's function.

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?

Covers all relevant aspects: purpose, single parameter, output schema in detail, error behavior, and usage examples. With no missing elements, it fully informs an AI agent for correct invocation.

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?

The single parameter (response_format) is explained in the description with defaults and examples, complementing the schema's description. Although schema description coverage is listed as 0%, the actual schema includes descriptions, and the tool description enhances 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 explicitly states it retrieves the current portfolio with holdings, cash, equity, and unrealized P&L. It clearly distinguishes from sibling tools like trade_get_backtest or trade_get_indicators by focusing on the live portfolio snapshot.

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?

Provides concrete examples ('How is my portfolio doing?', 'Give me my positions as JSON') that illustrate typical usage. Does not explicitly mention when not to use it, but the examples sufficiently convey appropriate context.

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/Aaditya2502/trade-mcp'

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