Skip to main content
Glama

confirm_fund_order

Destructive

Turn an in-transit fund purchase order into shares at the pricing day's NAV, updating units and average cost. Use it to confirm early or supply your own NAV and fee.

Instructions

Second leg of an off-exchange fund purchase: turn an in-transit order into shares at the pricing day's NAV (units = (amount - fee) / nav; average cost updates, cash unchanged). The fund_confirm job does this automatically every weekday evening, so call it manually only to supply a NAV / fee yourself or to confirm early.

Safe to call twice: an order that is already confirmed returns {"status": "already_confirmed"} (a cancelled one {"status": "cancelled"}) and nothing changes. If the pricing-day NAV is not published yet the result is {"status": "pending_nav"} and the order stays in transit.

Args: order_id: The order to confirm. nav: Unit NAV; omit to use the published NAV of the pricing day. fee: Subscription fee in CNY (default 0).

Returns: Units added, NAV used and new average cost, or {"status": "error", "error": ...}.

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": {
      "order_id": "<order_id>"
    },
    "name": "confirm_fund_order"
  }
}

Input Schema

NameRequiredDescriptionDefault
feeNoActual subscription fee. Omit when unknown; use explicit 0 only for a known zero fee. Without both reported NAV and fee this creates only a tracking projection.
navNoUnit NAV to confirm at. Omit to fetch the pricing day's published NAV (if it isn't published yet the call returns status 'pending_nav' and changes nothing).
order_idYesorder_id from place_fund_order / status.pending_fund_orders.

Output Schema

NameRequiredDescriptionDefault
resultYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed5 schema fields changedv0.68.10
    • addedInput schema / properties / fee / anyOf
      Added value: +[
      +  {
      +    "minimum": 0,
      +    "type": "number"
      +  },
      +  {
      +    "type": "null"
      +  }
      +]
    • changedInput schema / properties / fee / default
      Previous value: -0New value: +null
    • changedInput schema / properties / fee / description
      Previous value: -"Subscription fee in CNY, taken out of the order amount (units = (amount - fee) / nav). Default 0."New value: +"Actual subscription fee. Omit when unknown; use explicit 0 only for a known zero fee. Without both reported NAV and fee this creates only a tracking projection."
    • removedInput schema / properties / fee / minimum
      Removed value: -0
    • removedInput schema / properties / fee / type
      Removed value: -"number"
  2. Addedv0.45.1

TDQS

A3.9/5.0
Behavior2/5

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

The description adds a lot of behavior beyond the annotations: the NAV formula, that average cost updates while cash stays unchanged, and the `already_confirmed` / `cancelled` / `pending_nav` outcomes. However, 'Safe to call twice ... nothing changes' directly conflicts with the declared idempotentHint=false, which tells an agent that repeat calls DO have additional effects; the two signals give opposite retry guidance. That contradiction is why this cannot be scored as strong disclosure despite the otherwise rich detail.

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?

The core purpose, automation caveat, and safety caveat are front-loaded in three tight paragraphs before the Args/Returns block. The Args section largely duplicates schema text that is already at 100% coverage, which is the only wasted space.

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?

For a three-parameter mutation with an output schema, the description covers the state transition, side effects on average cost and cash, the pricing-day dependency, and the non-happy-path statuses an agent must handle. Missing only things like permission requirements or what happens to a cancelled order's cash, which are minor given the output schema exists.

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 each parameter's meaning and defaults are already documented, including the 'omit when unknown' rule for fee and the pending_nav consequence for nav. The description restates those rules and adds the formula context but no syntax or constraints the schema lacks. Baseline 3 is appropriate when the schema carries the parameter burden.

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 names a specific verb and resource plus the accounting mechanics: 'Second leg of an off-exchange fund purchase: turn an in-transit order into shares at the pricing day's NAV (units = (amount - fee) / nav; average cost updates, cash unchanged).' That verb/scope framing separates it from place_fund_order (the first leg) and cancel_fund_order without requiring the agent to open 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 Guidelines5/5

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

It states exactly when NOT to call it ('The `fund_confirm` job does this automatically every weekday evening') and the two conditions that justify a manual call ('supply a NAV / fee yourself or to confirm early'). This is explicit when/when-not/alternative guidance tied to a concrete background job.

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