Skip to main content
Glama
pyalgobot

angelone-mcp

by pyalgobot

get_margin

Calculate the required span and exposure margin for a basket of positions before placing orders, using exchange, quantity, price, product type, token, trade type, and order type.

Instructions

Calculate span + exposure margin required for a basket of positions before placing them.

Each position dict needs: exchange, qty, price, productType, token, tradeType (BUY/SELL), orderType.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
positionsYes

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes
Install Server

TDQS

A4.3/5.0
Behavior3/5

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

With no annotations provided, the description carries the behavioral disclosure burden. It usefully discloses that each position dict requires specific fields, but does not state whether the operation is read-only, requires authentication, or has any side effects. The word 'calculate' implies a query-like operation but does not make this explicit.

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 tight sentences: the first states the primary purpose, the second details input requirements. There is no filler or redundant information.

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?

The output schema exists, so return values are covered. The description fully specifies the only parameter's structure and required fields. Minor missing context includes auth prerequisites and behavior with empty or invalid baskets, but for a single-parameter margin calculator this is largely complete.

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?

The schema only defines an array of objects with additionalProperties true (0% coverage), so the description fully compensates by enumerating the required fields: exchange, qty, price, productType, token, tradeType (BUY/SELL), orderType. This provides essential semantics the schema lacks, including tradeType's allowed values.

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 states a specific verb ('Calculate') and resource ('span + exposure margin') for a basket of positions, with the context 'before placing them.' This makes the tool's purpose unambiguous and differentiates it from siblings like place_order, estimate_charges, and get_rms_limit.

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 phrase 'before placing them' provides an explicit context for when to use the tool – as a pre-trade margin check. However, it does not name alternative tools or state when not to use this tool, so it lacks exclusions.

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

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/pyalgobot/angelone-mcp'

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