Skip to main content
Glama

Get a wallet top-up link

get_topup_link

Create a hosted payment URL to hand to your human principal when the wallet is short. Use it after WALLET_INSUFFICIENT_FUNDS or a low get_wallet balance, then poll get_wallet until the credit appears. Returns the top-up record with its payment URL; it charges nothing by itself. Example: {amount_minor: 2000, currency: "USD"} asks for a 20.00 USD credit. They pay in ILS on the acquirer's page (PayPlus); you never see card data. amount_minor is in currency: USD (the wallet credit you want; the ILS charge is computed at today's rate) or ILS (the exact charge). The wallet is credited in USD at the rate in force when payment is confirmed. Limits are in the topup policy.

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": {
      "amount_minor": "<amount_minor>"
    },
    "name": "get_topup_link"
  }
}

Input Schema

NameRequiredDescriptionDefault
agent_idNoYour agent id (or X-Agent-Id header)
currencyNoUSD: the wallet credit you want (the ILS charge follows today's rate). ILS: the exact charge in shekels. Default USDUSD
agent_keyNoSecret returned by register_agent (or X-Agent-Key header)
amount_minorYesAmount in minor units of currency (2000 = 20.00); limits are in the topup policy
principal_idNoThe principal you act for (or X-Principal-Id header)

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed2 schema fields changed
    • changedInput schema / properties / amount_minor / description
      Previous value: -"Minor units of currency, e.g. 2000 = 20.00"New value: +"Amount in minor units of currency (2000 = 20.00); limits are in the topup policy"
    • addedInput schema / properties / currency / description
      Added value: +"USD: the wallet credit you want (the ILS charge follows today's rate). ILS: the exact charge in shekels. Default USD"
  2. Changed3 schema fields changed
    • addedInput schema / properties / agent_id / pattern
      Added value: +"^[A-Za-z0-9._:-]{3,128}$"
    • addedInput schema / properties / agent_key / maxLength
      Added value: +256
    • addedInput schema / properties / principal_id / pattern
      Added value: +"^[A-Za-z0-9._:@-]{3,128}$"
  3. First observed

TDQS

A4.6/5.0
Behavior5/5

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

Annotations only declare openWorldHint=true, idempotentHint=false, and destructiveHint=false; the description supplies the consequential detail beyond that — it charges nothing by itself, the actual charge happens on the PayPlus acquirer page in ILS, no card data is exposed, and the wallet is credited in USD at the rate in force at confirmation. It also points to the topup policy for limits, which is exactly the kind of side-effect and constraint disclosure a payment-link tool needs.

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?

Front-loaded with the action and its trigger, then the post-call protocol, then semantics. Sentences are dense but each carries information; the currency explanation is somewhat duplicated between the prose and the schema's enum description, which is the only real waste.

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?

There is no output schema, and the description compensates by stating what comes back (the top-up record with its payment URL). Auth inputs are covered in the schema, limits are delegated to the topup policy, and the human-in-the-loop flow is fully described. Nothing an agent needs to call this correctly is missing.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 100%, so the baseline is 3, but the description earns above that by adding a concrete worked example ({amount_minor: 2000, currency: "USD"} = 20.00 USD credit) and by clarifying the FX asymmetry — USD means the credit you want with the ILS charge computed at today's rate, ILS means the exact charge. That semantic distinction is the crux of the tool and is spelled out more fully than the enum description alone.

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 and resource — "Create a hosted payment URL" — and immediately scopes it to "when the wallet is short," which separates it from get_wallet (read balance) and sandbox_simulate_topup_payment (test path). An agent can identify the tool without opening the 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?

Gives an explicit trigger ("after WALLET_INSUFFICIENT_FUNDS or a low get_wallet balance") and a follow-up protocol ("poll get_wallet until the credit appears"), which is strong when-to-use guidance. It does not name sandbox_simulate_topup_payment as the non-production alternative, so the one ambiguity that matters in this sibling set is left unaddressed.

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.