Skip to main content
Glama

Check Credit Balance

get_credit_balance
Read-onlyIdempotent

Returns the current API credit balance for the authenticated account, plus the automatic top-up state of the account (autoTopup: configured, enabled, pack, monthly charge cap and count, last error) so an agent can tell whether a zero balance is a hard stop or refills itself on the next billable call, and expiring: the next dates on which part of the balance expires, with the credits on each. Free to call. Agents should check the balance before starting large batch jobs and surface "insufficient_credits" errors to the user with a link to top up. Cost: free.

Tool call template

This tool declares no required parameters. Add optional parameters from the input schema as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {},
    "name": "get_credit_balance"
  }
}

Input Schema

NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.5/5.0
Behavior5/5

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

Annotations already declare it read-only, idempotent and closed-world, so the bar is lower, yet the description adds substantive behavior: the call is free, and zero balance must be interpreted against the autoTopup state (configured, enabled, pack, cap, last error) to know if it is a hard stop or self-refills. It also explains that balances expire on dates, which is non-obvious semantics an agent 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-loads the core purpose, then the operational meaning of the fields, then the guidance. The dense parenthetical for autoTopup is justified, but the ending duplicates itself: 'Free to call' and 'Cost: free' say the same thing in one sentence pair.

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, so the description must carry the return-value burden, and it does: balance, autoTopup sub-fields, and expiring credits with dates and amounts. An agent has everything needed to call it and interpret the result.

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?

Zero parameters, so the baseline is 4 and there is nothing for the description to disambiguate. The description spends its space on return-value semantics instead, which is the right allocation.

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?

States a specific verb and resource: 'Returns the current API credit balance for the authenticated account,' then enumerates the sub-objects returned (autoTopup, expiring). The resource is distinct enough from siblings like get_pricing or create_topup_link that an agent won't confuse them, though the description never explicitly routes between them.

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?

Gives explicit when-to-use guidance: check the balance before starting large batch jobs, and handle 'insufficient_credits' errors by surfacing them to the user with a top-up link. No when-not guidance, but the tool has no real alternatives to exclude.

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