Skip to main content
Glama

Price a generation before running it

media_quote
Read-onlyIdempotent

What generate would charge for exactly these settings, at the key's own rates: the units billed, the charge, and the developer's own price for the same request where one is on record. The settings are checked as a real request's would be, so a wrong value fails here, not at the model. Nothing runs and nothing is charged. Needs the key. Live from POST /v1/generations/quote.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "model": "<model>",
      "input": "<input>"
    },
    "name": "media_quote"
  }
}

Input Schema

NameRequiredDescriptionDefault
inputYesThe model's settings, as media_model lists them under params: prompt, size or aspect_ratio, resolution, duration, image_urls, text, voice... A setting left out takes the model's default.
modelYesA media model id from list_media_models.

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 readOnly/idempotent annotations, the description discloses that nothing is executed or billed, that inputs are validated exactly as a real request would be, that a key is required, and that pricing comes live from a specific endpoint. The validation-failure semantics ('a wrong value fails here') are behavior an agent could not infer from the annotations alone.

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 response contents are front-loaded, followed by validation behavior, cost safety, auth, and source. Every sentence carries information, though the trailing endpoint reference ('Live from POST /v1/generations/quote') is implementation detail of marginal value to an agent selecting the tool, and the colon-list construction is slightly dense.

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?

Although there is no output schema, the description enumerates the returned fields, covers the nested 'input' object's semantics, and states the auth requirement and side-effect profile. An agent has everything needed to call it correctly and interpret the result.

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 100%, and the schema already explains that 'input' holds the model's settings and that omitted settings take model defaults. The description adds only the framing that the settings must be 'exactly these settings' as generate would submit them, which is meaningful but modest 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?

The description names a specific operation (price a request) and resource (a generation's settings), and explicitly frames it relative to the sibling 'generate' by answering 'what generate would charge'. It also enumerates what the response contains (units billed, charge, developer's own recorded price), so an agent can distinguish it from generate and estimate without opening a 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?

Usage is clear: run this before generating, since 'nothing runs and nothing is charged' and bad settings 'fail here, not at the model'. That gives a strong pre-flight rationale. It stops short of explicit when-not-to-use guidance or naming other estimation siblings, so it is clear context rather than full routing.

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.