Skip to main content
Glama

deposit

Destructive

Record cash credits in any currency into the OpenInvest ledger for bookkeeping only, using an idempotency key to avoid duplicate entries on retries. No real payment system is connected.

Instructions

Record a cash deposit into the ledger, in any currency. Bookkeeping only — no real payment system is connected.

Args: currency: ISO-style currency code, e.g. "CNY", "USD", "AUD". amount: Amount to add; must be > 0. idempotency_key: Reuse the same key when retrying this exact call; recorded once.

Returns: Updated cash balances, or {"status": "error", "error": ...}.

Input Schema

NameRequiredDescriptionDefault
amountYesAmount to add; must be > 0.
currencyYesISO-style currency code, e.g. 'CNY', 'USD', 'AUD'.
idempotency_keyNoOptional client-generated key (e.g. a UUID4). When retrying this SAME call after a timeout or an unknown result, reuse the same key: the ledger records it once and later calls return {"status": "duplicate"} without touching cash or holdings. Only the key is compared, not the arguments — a different order (other symbol/units/price/amount) needs a new key, or it is silently treated as the retry.

Output Schema

NameRequiredDescriptionDefault
resultYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changedv0.45.1
    • addedInput schema / properties / idempotency_key
      Added value: +{
      +  "anyOf": [
      +    {
      +      "type": "string"
      +    },
      +    {
      +      "type": "null"
      +    }
      +  ],
      +  "default": null,
      +  "description": "Optional client-generated key (e.g. a UUID4). When retrying this SAME call after a timeout or an unknown result, reuse the same key: the ledger records it once and later calls return {\"status\": \"duplicate\"} without touching cash or holdings. Only the key is compared, not the arguments — a different order (other symbol/units/price/amount) needs a new key, or it is silently treated as the retry.",
      +  "title": "Idempotency Key"
      +}
  2. Addedv0.34.0
  3. Removedv0.31.5
  4. Changed3 schema fields changedv0.31.4
    • addedInput schema / properties / amount / description
      Added value: +"Amount to add; must be > 0."
    • addedInput schema / properties / amount / exclusiveMinimum
      Added value: +0
    • addedInput schema / properties / currency / description
      Added value: +"ISO-style currency code, e.g. 'CNY', 'USD', 'AUD'."
  5. First observedv0.31.0

TDQS

A4/5.0
Behavior4/5

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

Annotations already mark this as a non-read-only mutation, and the description adds important context beyond them: no real payment system is connected, idempotency-key retry behavior is documented, and return behavior is summarized. It does not fully address the destructiveHint annotation or discuss reversibility/permissions, so it is strong but not complete.

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 description is front-loaded with purpose and scope, then uses short Args/Returns sections. It is appropriately sized, though the Args and Returns sections partly duplicate the input and output schemas.

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

Completeness5/5

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

Given the tool’s complexity, rich input schema, existing annotations, and output schema, the description provides everything an agent needs: it clarifies bookkeeping-only behavior, amount/currency expectations, idempotency retry semantics, and error/return shape at a high level.

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 explains currency format, amount constraints, and idempotency-key behavior in detail. The description’s Args section largely mirrors that information rather than adding substantial new semantics, making the baseline 3 appropriate.

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 states a specific verb and resource: “Record a cash deposit into the ledger,” and clarifies scope with “in any currency” and “Bookkeeping only.” This is clearly distinguishable from sibling tools like withdraw, buy, or record_fee.

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?

It provides useful context that this is bookkeeping-only and not connected to a real payment system, which implies when it should be used. However, it does not explicitly name alternatives or state when not to use this tool versus withdraw, buy, or other ledger mutation tools.

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