Skip to main content
Glama

get_auto_topup

Get a user's auto top-up rule for credit_type_id (auto_topup, or null), or all their rules (auto_topups) when credit_type_id is omitted, plus their saved card. Rules show threshold, enabled, max_per_day, charges_last_24h, last_status/last_error and disabled_reason (set when cred turned a failing rule off). Costs 1 CRD (platform credit) per call, charged even when the call is then rejected (a 429 RATE_LIMITED costs nothing). Error results include request_id; quote it to support.

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": {
      "user_id": "<user_id>"
    },
    "name": "get_auto_topup"
  }
}

Input Schema

NameRequiredDescriptionDefault
api_keyNoCred API key (optional if set via the x-api-key header)
user_idYesExternal user ID of the card holder
project_idNoCred project ID (optional; the API key already identifies the project. Signed in with 1Profile and owning several projects, it picks one)
x402_paymentNoBase64 x402 PaymentPayload, only when a previous call failed with an x402 PaymentRequired because the account is out of CRD
credit_type_idNoCredit type UUID

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changed
    • changedInput schema / properties / project_id / description
      Previous value: -"Cred project ID (optional; the API key already identifies the project)"New value: +"Cred project ID (optional; the API key already identifies the project. Signed in with 1Profile and owning several projects, it picks one)"
  2. First observed

TDQS

A4.5/5.0
Behavior5/5

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

With no annotations at all, the description carries the full burden and does so: it discloses the 1 CRD cost per call, that the charge applies even to rejected calls, the 429 RATE_LIMITED exemption, the inclusion of error request_ids for support escalation, and what disabled_reason means semantically. This is exactly the kind of operational context annotations would otherwise provide.

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?

Three sentences, each doing distinct work (return shape, cost model, error handling), with the core purpose front-loaded. The opening sentence is heavily nested with parenthetical field lists, which slightly slows parsing but no sentence is filler.

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?

There is no output schema, so the description must describe return content, and it enumerates the rule fields (threshold, enabled, max_per_day, charges_last_24h, last_status/last_error, disabled_reason) plus the saved card. Combined with the cost and error notes, an agent can call this correctly; only auth details and pagination/volume expectations for the all-rules mode are absent.

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 adds genuine meaning the schema does not: the behavioral effect of omitting credit_type_id is spelled out, tying the parameter to the two different response shapes. It says nothing about the api_key, project_id, or x402_payment parameters, which remain schema-only.

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 ('Get a user's auto top-up rule') and precisely delineates the two modes of return, naming the response keys auto_topup vs auto_topups. It also notes the saved card is included, so an agent knows exactly what this tool yields versus siblings like save_auto_topup or delete_auto_topup.

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?

Explicitly defines the selection rule: pass credit_type_id for a single rule, omit it to get all rules. That is real when-to-use guidance. It stops short of naming alternatives (e.g., using save_auto_topup to change a rule) or stating prerequisites such as needing a paid account.

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