Skip to main content
Glama

getAiModelPricing

Real-time token pricing, context limits, latency (TTFT), and benchmark scores for OpenAI, Anthropic, Gemini, and open-weights LLMs. Use when comparing commercial and open-weights LLM API token pricing (USD per 1M input/output tokens), context window limits, latency (TTFT in ms), and coding benchmarks. Do not use for consumer chat subscriptions (e.g., ChatGPT Plus) or bare-metal GPU server rental (use getCloudServerPricing).

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

Input Schema

NameRequiredDescriptionDefault
task_categoryNoPrimary LLM workload category to filter benchmark and pricing matrices (defaults to 'all').all

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed4 schema fields changed
    • addedInput schema / additionalProperties
      Added value: +false
    • addedInput schema / properties / task_category / default
      Added value: +"all"
    • addedInput schema / properties / task_category / enum
      Added value: +[
      +  "all",
      +  "coding",
      +  "reasoning",
      +  "vision",
      +  "fast_cheap"
      +]
    • addedInput schema / properties / task_category / examples
      Added value: +[
      +  "coding"
      +]
  2. Changed1 schema field changed
    • changedInput schema / properties / task_category / description
      Previous value: -"Filter models by primary use case"New value: +"Primary LLM workload category to filter benchmark and pricing matrices (defaults to 'all')."
  3. First observed

TDQS

A4.5/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 behavioral burden, and it discloses real-time freshness, provider coverage, units, and included metrics. It does not mention auth, rate limits, or error behavior, but for a read-only pricing lookup it provides strong context.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is compact and front-loaded: it first says what data is covered, then when to use it, then when not to. Every clause contributes to selection or scoping, with no wasted text.

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?

For a one-parameter, no-output-schema pricing lookup, the description is complete enough: it lists the returned data categories, units, provider scope, and exclusions. The input enum is fully documented in the schema, so no important gap remains.

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?

The single optional `task_category` parameter has full schema coverage with enum values and a description. The tool description adds no parameter-level meaning beyond the schema, so the baseline of 3 is appropriate.

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 states a specific resource and scope: real-time token pricing, context limits, latency, and benchmark scores across explicit LLM providers. It clearly distinguishes itself from `getCloudServerPricing` and consumer subscription pricing, so an agent can identify the tool without opening the 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?

It gives explicit when-to-use guidance ('Use when comparing...') and explicit exclusions for consumer subscriptions and bare-metal GPU rental. The alternative tool is named directly for the GPU-rental exclusion.

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