Skip to main content
Glama
simoneb

directa-mcp

by simoneb

preview_limit_order

Idempotent

Preview a limit order's cost before placing it. Get commission estimates and pre-trade disclosure from Darwin to avoid unexpected expenses.

Instructions

Ask Darwin what an order would cost, without placing it. Use this before place_limit_order, and whenever the user asks about commissions.

The order is submitted and deliberately left unconfirmed, so it never reaches the market, and Darwin answers with its pre-trade disclosure: the instrument's full name, the amount, the commission that would apply, and any conflict-of-interest note. This is the only way to obtain commission figures — no dAPI command reports them, and they depend on the order's value, so they cannot be looked up in advance.

Read on_market in the response before describing the outcome. It should be false. If it is true, Darwin was not configured to ask for confirmation and the order IS live — say so immediately and prominently.

Subject to the same DIRECTA_ENABLE_ORDERS gate as place_limit_order, since this does send an order command to a real account.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
sideYes
priceYes
symbolYes
order_idNo
quantityYes

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Behavior5/5

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

The description reveals critical behavioral traits beyond annotations, such as: the order is 'deliberately left unconfirmed, so it never reaches the market,' and the warning to read `on_market` because if true 'the order IS live.' It also discloses the commission dependency on order value and the gate requirement. This adds depth to the sparse annotations (readOnlyHint=false, idempotentHint=true).

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?

The description is organized into three compact paragraphs that each serve a purpose: the first states intent and usage, the second explains what happens and why, and the third adds a safety warning. No sentence is redundant, and the tool's complexity justifies the length.

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?

While parameter semantics are thin, the description covers the core aspects needed for safe invocation: purpose, when to use, expected response fields, a safety check (on_market), and the permissions gate. The presence of an output schema covers return structure, so the description doesn't need to list every field. However, a brief note on parameter meaning would make it fully self-contained.

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

Parameters2/5

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

The input schema has no descriptions and schema description coverage is 0%, so the description must compensate. It does not provide any per-parameter definitions or constraints beyond what the schema already lists (symbol, side, quantity, price, order_id). Though it references 'order's value,' it does not explain how parameters interact or what each parameter means. This is a significant gap.

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 opens with a clear verb and resource: 'Ask Darwin what an order would cost, without placing it.' It distinguishes itself from the sibling tool place_limit_order by explicitly saying 'Use this before place_limit_order,' making the tool's purpose unambiguous.

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 provides explicit when-to-use guidance: 'Use this before place_limit_order, and whenever the user asks about commissions.' It also states that 'This is the only way to obtain commission figures,' ruling out alternatives, and notes the same DIRECTA_ENABLE_ORDERS gate as place_limit_order, which clarifies when it can be invoked.

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/simoneb/directa-mcp'

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