Skip to main content
Glama
foxisyw

AI Trading Co-Pilot MCP Server

by foxisyw

okx_get_positions

Retrieve all open trading positions from OKX with their P&L, leverage, and margin ratio using your API key.

Instructions

Get all open positions with P&L, leverage, margin ratio. Requires OKX API key.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
instTypeNoPosition typeSWAP
Behavior2/5

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

With no annotations, the description carries the full burden of behavioral disclosure. It mentions the API key requirement but fails to disclose that the optional instType parameter (default SWAP) filters the results, contradicting the 'all open positions' phrasing. It also doesn't clarify scope (e.g., authenticated account) or any response limitations. This is a notable omission for a read tool.

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 a single concise sentence that front-loads the primary action and key outputs. Every word adds value, and there is no redundant phrasing or filler. It is appropriately sized for the tool's simplicity.

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

Completeness3/5

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

The tool is relatively simple (one optional parameter, no output schema, no annotations), but the description omits important contextual details such as the default filter behavior (SWAP) and whether 'all' means all for the authenticated account. The auth requirement is helpful, but the missing filter disclosure leaves the description incomplete for an agent making decisions.

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?

The schema fully documents the only parameter (instType) with a description ('Position type') and enum values, so baseline is 3. The tool description adds no extra semantic detail beyond the schema; the meaning of 'SWAP' vs 'SPOT' is implied but not explained, which is acceptable given the schema coverage.

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 clearly states the tool's action ('Get all open positions') and includes specific data points (P&L, leverage, margin ratio) that distinguish it from siblings like okx_get_balance or okx_close_position. The verb is specific and the resource is well-defined.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

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

No guidance is given on when to use this tool versus alternatives. The only additional context is the auth requirement ('Requires OKX API key'), which is a prerequisite, not a usage guideline. There is no mention of scenarios where this tool is preferred over other OKX tools.

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

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