Skip to main content
Glama

get_usage

Read-only

Read the organisation's usage of Ankra - the same report GET /org/billing/usage serves: worker vCPU-hours, ordered playground time, managed service instance time (seconds) and storage (byte-hours), hosted logs bytes and lines, hosted metrics samples and active series (series-hours), and AI requests and tokens - one line per meter and period, optionally split by cluster, by the application a managed service serves, or by managed service instance. Give instance_id for one managed service instance's usage, or application_id for the service usage of one application's instances. Each line says its unit, quantity, coverage and price state: coverage unknown means nothing measured that period and quantity is null - unknown usage, never zero, so never report it as zero; partial means quantity is a lower bound. price_state included means Ankra charges nothing for it during the managed services pilot; priced means a published rate applies and amount_display is what it costs; unpriced means no per-unit rate applies (price_basis says why). Only priced lines carry an amount. Read-only; needs billing.read. The window is at most 93 days; a longer stretch is read in parts.

Input Schema

NameRequiredDescriptionDefault
toNoThe day after the last UTC day to read, YYYY-MM-DD. Defaults to tomorrow; at most 93 days after from.
fromNoFirst UTC day to read, YYYY-MM-DD. Defaults to the first day of the current month; not after today and not more than 400 days back.
group_byNoSplit the lines by meter only (default), or also by cluster, application or managed service instance. Ignored with instance_id or application_id, which split by instance.
granularityNoPeriod of each line: a calendar month (default) or a UTC day.
instance_idNoA managed service instance id: report only that instance's instance time and storage.
application_idNoAn application id: report the instance time and storage of each managed service instance whose reviewed plan serves it.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.4/5.0
Behavior5/5

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

Beyond the readOnlyHint annotation it discloses the required permission ('needs billing.read'), the hard 93-day window, and detailed data semantics: coverage 'unknown' means quantity is null and never zero, 'partial' means a lower bound, and the price_state/amount rules for pilot, priced and unpriced lines. This is exactly the kind of operational context annotations cannot carry.

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?

Purpose is front-loaded and the sentences are dense with load-bearing detail rather than filler, which is justified given no output schema. It is nonetheless a long single block, and the price_state paragraph could be tightened, keeping it out of the top score.

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 no output schema, the description fully carries the return-value burden by explaining each line's unit, quantity, coverage and price state, plus auth, window limits and the grouping/scoping interplay. An agent has everything needed to call it and interpret results correctly.

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 description coverage is 100%, so the six parameters and their enums are already fully documented in the schema, and the description largely restates those semantics (group_by ignored with instance_id/application_id, from/to bounds). It adds only marginal parameter-level meaning beyond the schema, e.g. the 'read a longer stretch in parts' guidance, so the baseline 3 applies.

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?

The description gives a specific verb and resource — reading the organisation's usage report — and pins it to a concrete identity ('the same report GET /org/billing/usage serves') while enumerating the meters covered (vCPU-hours, playground time, storage, logs, metrics, AI tokens). This lets an agent separate it from near-neighbours such as get_node_usage, get_pod_usage and get_billing_standing without opening any 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?

It clearly states the operative context: pass instance_id to scope to one managed instance, application_id to scope to an application's instances, and it warns the window is capped at 93 days so longer stretches must be read in parts. It does not name alternative tools or state explicit when-not conditions, so it stops short of a 5.

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