Skip to main content
Glama

credits_history

Credit usage history: balance, 30-day spend by reason, and ledger entries (newest first). Each entry has delta, reason (pipeline_run, ai_agent, schedule_run, chat_turn, agent_job, builder_call, debug_chat, mcp_usage, llm_usage = model tokens beyond the flat fee (one row per run/call), purchase, signup_grant, refund, ...), detail (what it was for), balance_after. kind: "spend" (charges only) or "credit" (grants/purchases/refunds only). limit max 200.

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": "credits_history"
  }
}

Input Schema

NameRequiredDescriptionDefault
kindNo
limitNo
offsetNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed3 schema fields changed
    • addedInput schema / properties / kind
      Added value: +{
      +  "anyOf": [
      +    {
      +      "type": "string"
      +    },
      +    {
      +      "type": "null"
      +    }
      +  ],
      +  "default": null,
      +  "title": "Kind"
      +}
    • addedInput schema / properties / limit
      Added value: +{
      +  "default": 50,
      +  "title": "Limit",
      +  "type": "integer"
      +}
    • addedInput schema / properties / offset
      Added value: +{
      +  "default": 0,
      +  "title": "Offset",
      +  "type": "integer"
      +}
  2. First observed

TDQS

A3.7/5.0
Behavior4/5

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

With no annotations, the description carries the full burden and does well: it discloses the ordering guarantee (newest first), the contents of each ledger row (delta, reason, detail, balance_after), the full reason vocabulary, and the limit ceiling of 200. Gaps remain on pagination/total-count behavior and whether offset pages past the limit.

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 resource and return shape, then parameter semantics — a sensible order with no filler. The long reason enumeration costs some space but is genuinely informative since the schema declares no enum; the `kind`/`limit` guidance is stated compactly at the end.

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?

For a no-annotation, no-output-schema, three-parameter read tool, the description covers return structure, ordering, reason vocabulary, and two parameter constraints — enough to call it correctly. What it lacks is offset/paging semantics and any indication of result size or total count.

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 coverage is 0%, so the description must supply all parameter meaning. It does for two of three: `kind` is defined as "spend" (charges only) vs "credit" (grants/purchases/refunds only), and `limit` is capped at 200 — both values absent from the schema. `offset` is never mentioned, leaving its paging semantics undocumented.

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?

The description opens with a specific verb+resource framing ("Credit usage history") and immediately enumerates the three things returned: balance, 30-day spend by reason, and ledger entries. That distinguishes it from purchase-oriented siblings like credits_checkout_url and credit_packs, though it never explicitly names an alternative.

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?

Usage is only implied: an agent infers it should call this to inspect balance or spend history, and that `kind` narrows to charges or grants. There is no explicit when-to-use/when-not statement, no mention of paging through results, and no pointer to a sibling for the related cases (checkout, packs).

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