Skip to main content
Glama

Last Price

record_cost

Record a cost in your workspace, such as a vendor or infrastructure cost, so the Value Receipt and the cost analytics count it: pass amount, and optionally currency (default USD), cost_type (default usage), agent_id, customer_id and metadata. This writes a record that is not undone by another tool, so record what was really spent. Needs a claimed Last Price credential. Needs a claimed workspace: a sandbox key from self-registration is refused (403) until a person claims the workspace.

Input Schema

NameRequiredDescriptionDefault
amountYesWhat it cost, in the currency.
agent_idNoThe agent: its id, as it shows in your workspace. An agent's own credential can name only its own agent.
currencyNoThe currency code. Defaults to USD.
metadataNoAnything worth keeping with the record.
cost_typeNoWhat kind of cost it is. Defaults to usage.
customer_idNoThe customer: its id, as it shows in your workspace.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Added

TDQS

A4.4/5.0
Behavior5/5

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

Goes well beyond the annotations by disclosing that the write cannot be undone by another tool, that a claimed Last Price credential is required, and that a self-registered sandbox key gets a 403 until a person claims the workspace. Annotations only cover the read-only/destructive/idempotent flags, so this auth and irreversibility context is genuinely additive.

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 purpose, effect, and parameters in the first sentence, then prerequisites in the second. Both sentences earn their place, though the second runs long and packs three distinct constraints together.

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?

Given a write tool with no output schema, the description supplies the missing pieces: what the recorded cost affects, that it is permanent, and the exact credential and workspace state required. Nothing an agent needs in order to call it correctly is absent.

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 schema already documents every parameter. The description restates the defaults for currency (USD) and cost_type (usage) and lists which parameters are optional, but adds no format, enum, or interaction detail beyond the schema; 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?

States a specific verb and resource ("Record a cost in your workspace") plus concrete examples (vendor, infrastructure cost) and the downstream effect (Value Receipt, cost analytics). It is clearly distinguishable from read-side siblings like list_costs and get_cost_analytics.

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?

Gives a clear condition for use with the irreversibility warning ("record what was really spent") and states two prerequisites that gate invocation. It does not explicitly name alternative tools such as list_costs or get_cost_analytics, so it stops short of full when-not guidance.

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