Skip to main content
Glama

Get balance

get_balance
Read-onlyIdempotent

Use when you need the Customer's prepaid Credits before spending: the balance plus each Grant (such as the Starter Grant) with its Credits left and expiry. Not for past charges: use get_usage. For one call's price, pass estimate=true to that tool. Price: Free. Grants are spent first.

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_balance"
  }
}

Input Schema

NameRequiredDescriptionDefault

No arguments

Output Schema

NameRequiredDescriptionDefault
grantsNoUnexpired Grants with Credits left, soonest expiry first.
balance_creditsNoThe spendable Balance in Credits: active Grants included, an expired Grant's leftover never.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed2 schema fields changed
    • changedOutput schema / properties / grants / items / additionalProperties
      Previous value: -trueNew value: +{}
    • removedOutput schema / properties / grants / items / properties
      Removed value: -{}
  2. Changed1 schema field changed
    • changedOutput schema / (root)
      Previous value: -nullNew value: +{
      +  "$schema": "http://json-schema.org/draft-07/schema#",
      +  "additionalProperties": true,
      +  "properties": {
      +    "balance_credits": {
      +      "description": "The spendable Balance in Credits: active Grants included, an expired Grant's leftover never.",
      +      "type": "integer"
      +    },
      +    "grants": {
      +      "description": "Unexpired Grants with Credits left, soonest expiry first.",
      +      "items": {
      +        "additionalProperties": true,
      +        "properties": {},
      +        "type": "object"
      +      },
      +      "type": "array"
      +    }
      +  },
      +  "type": "object"
      +}
  3. First observed

TDQS

A4.6/5.0
Behavior4/5

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

Annotations already declare readOnly, idempotent, non-destructive and closed-world, so the safety profile needs no restating. The description adds genuinely new behavior: the call is free of charge (it does not itself consume Credits) and Grants are drawn down first. It stops short of anything about staleness or caching, which is why this is a 4 rather than a 5.

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 usage trigger and the return contents are front-loaded, and the sibling redirects follow immediately. The trailing short fragments ('Price: Free.' / 'Grants are spent first.') are terse but read as clipped notes rather than smoothly integrated sentences, costing a little polish.

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?

With zero parameters, rich annotations and an output schema already describing the return shape, the description only needs to cover usage and routing, and it does so fully. An agent has everything required to decide to call this instead of get_usage or an estimate call.

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?

The tool takes no parameters, so the baseline is 4. The only parameter-like mention (estimate=true) refers to the get_usage sibling rather than to this schema, which is correct and not misleading given the empty input object.

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 concrete resource (the Customer's prepaid Credits) and exactly what is returned: the balance plus each Grant with its Credits left and expiry. It also names the sibling it must not be confused with (get_usage), so an agent can separate the two without opening 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?

Gives an explicit trigger ('use when you need the ... Credits before spending'), an explicit exclusion ('Not for past charges: use get_usage'), and a redirect for a related question ('For one call's price, pass estimate=true to that tool'). This is the full when/when-not/alternative pattern.

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