Skip to main content
Glama

fxapis — MetaTrader 5

List positions

list_positions
Read-onlyIdempotent

Open positions on one account as last observed; brokerPositionId is what close_position and modify_position take. Pages with limit and cursor. Example: {"account_id": ""}

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
limitNoItems per page, 1–100. Default 25.
cursorNonext_cursor from the previous page.
account_idYesThe fxapis account id (a UUID) from list_accounts — not the MT5 login number.
include_closedNoAlso return positions that have closed. Default false.
response_formatNoconcise (default): what a next step needs. detailed: every field the API returns.

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
hintNo
itemsYes
totalYes
truncatedNo
next_cursorYesPass as cursor for the next page; null on the last.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.1/5.0
Behavior4/5

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

Annotations already carry readOnly/idempotent/non-destructive, so the bar is low, and the description adds 'as last observed' — a real behavioral disclosure that the data is a snapshot rather than a live broker read. Pagination behavior is also noted. It does not state any auth/permission requirements, but nothing contradicts the annotations.

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?

Three compact clauses, front-loaded with purpose, then the ID linkage, then pagination. Nothing is redundant or padded. The trailing example ({"account_id": "<id>"}) is near-zero value since the schema already marks account_id required, which is the only slight waste.

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?

With an output schema present, return shape need not be described, and annotations cover the safety profile. The description covers purpose, the staleness caveat, pagination, and the ID's downstream use. The gaps (include_closed and response_format semantics, account_id disambiguation) are already fully handled by the schema, so little is missing.

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 description coverage is 100%, so the schema already documents limit range, cursor source, account_id (including the UUID-vs-MT5-login warning), include_closed and response_format. The description only restates that pagination uses limit and cursor, adding no meaning beyond structured data — baseline 3.

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?

States a specific verb+resource ('Open positions on one account') and scopes it precisely to a single account and a point-in-time observation. It also names the sibling consumers (close_position, modify_position) that the returned brokerPositionId feeds, which lets an agent distinguish this from list_orders/list_deals without opening 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 Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The cross-reference to close_position and modify_position effectively tells the agent this is the discovery step before position mutation. The 'as last observed' caveat signals a freshness limitation. It stops short of explicitly saying when NOT to use it versus list_deals or list_orders, so it is clear context but not full routing guidance.

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.

Resources