Skip to main content
Glama

MoneyTools x402 agent toolkit

Position risk calculator

position_risk_calc
Read-onlyIdempotent

Liquidation price, distance to liquidation, margin, round-trip fees, funding cost and break-even move for a leveraged long/short. Free: 10 calls/day; then $0.001/call via x402 (MCP params._meta["x402/payment"] or HTTP) or X-API-Key credits. [served by tools.moneytools.dev]

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "entryPrice": "<entryPrice>",
      "leverage": "<leverage>",
      "side": "<side>"
    },
    "name": "position_risk_calc"
  }
}

Input Schema

NameRequiredDescriptionDefault
sideYeslong | short
feeBpsNotaker fee bps per side (default 5)
sizeUsdNoposition size USD (default 1000)
leverageYes1-200
holdHoursNodefault 24
entryPriceYesentry price
fundingRatePct8hNofunding % per 8h
maintenanceMarginPctNodefault 0.5

Output Schema

NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. Added

TDQS

A3.8/5.0
Behavior4/5

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

Beyond the annotations (readOnly, idempotent, non-destructive, openWorld), the description discloses a concrete rate limit (10 free calls/day, then $0.001/call) and the two authentication paths (x402 payment via params._meta["x402/payment"] or HTTP, or X-API-Key credits). Rate limits and auth requirements are exactly the kind of behavioral context annotations cannot express. It does not, however, note whether the computation is deterministic across exchange conventions or how errors surface.

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?

One dense sentence front-loads the computed outputs, followed by a compact pricing/auth sentence. No filler, no redundancy with the schema, and the most decision-relevant information comes first.

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, the description need not explain return values, and it correctly focuses on purpose, cost, and authentication. For an 8-parameter, 3-required calculation tool with full schema coverage, this is close to complete; the only gap is a lack of any cross-reference to related risk or pricing tools.

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% and an output schema exists, so the schema already documents every parameter including defaults for feeBps, sizeUsd, holdHours and maintenanceMarginPct. The description adds conceptual mapping (fees, funding, margin are the modeled quantities) but no syntax, units, or constraint detail beyond what the schema states.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description enumerates the concrete outputs computed (liquidation price, distance to liquidation, margin, round-trip fees, funding cost, break-even move) and the scenario (leveraged long/short), so an agent knows exactly what the tool returns. It lacks any differentiation from sibling tools, though siblings in the list (typed_data_risk, address_profile, etc.) are far enough in domain that confusion is unlikely.

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

Usage Guidelines3/5

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

Usage is implied by the output list — an agent infers it should call this when it needs liquidation/break-even math for a leveraged position. There is no explicit 'use this when' statement, no exclusions, and no mention of any alternative tool for a related calculation; the only guidance given concerns cost and payment mechanics.

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