Skip to main content
Glama

Commodity prices: gold, oil, silver, gas, grains

commodity_price
Read-only

Commodity price now for gold, silver, platinum, palladium, copper, crude oil (WTI and Brent), natural gas, gasoline, heating oil, corn, wheat, soybeans, coffee, sugar, cocoa or cotton: the front-month futures price with its unit, the day's change and percent, previous close, day range and 52-week range. XAU, oil and similar names work. Use to price a commodity in an agent, track inflation inputs, or add market context to a brief. Example: commodity=gold. Price $0.001/call via x402 USDC or a card key (/credits), first 10 free; failed calls free. Reads or computes only and changes nothing; each call is charged, so repeats are not free.

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": {
      "commodity": "<commodity>"
    },
    "name": "commodity_price"
  }
}

Input Schema

NameRequiredDescriptionDefault
commodityYesOne of: gold, silver, platinum, palladium, copper, crude-oil, brent, natural-gas, gasoline, heating-oil, corn, wheat, soybeans, coffee, sugar, cocoa, cotton

Schema Changelog

Changes observed during successful MCP inspections.

  1. Added

TDQS

A4.3/5.0
Behavior4/5

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

Annotations already declare readOnly/openWorld/non-idempotent/non-destructive, and the description goes further by explaining the cost model ($0.001/call via x402 USDC or card key, first 10 free, failed calls free) and clarifying that repeats are not free — which is the practical meaning of idempotentHint=false. It stops short of describing latency, rate limits, or staleness of the quote.

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

Conciseness3/5

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

The first sentence is a 17-item run-on enumeration that duplicates the schema's enum and delays the actual behavior; pricing and safety notes are crammed into the same block. Front-loading the purpose and pushing the commodity list to the schema would tighten it considerably.

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 only one required parameter and no output schema, the description carries the return-shape burden itself and does so by naming every returned field. Billing, free tier, and failure behavior are all covered, leaving nothing an agent needs in order to call it correctly.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 100% and the schema already enumerates canonical values, so the description's list is largely redundant. It does add real meaning beyond the schema, however: aliases like 'XAU' and 'oil' are accepted even though they are absent from the enum, which an agent could not learn from the schema alone.

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 ('Commodity price now') and enumerates the exact covered instruments plus the returned fields (front-month futures price, unit, day change, percent, previous close, day/52-week range). This is enough to separate it from crypto_price, btc_price, and hyperliquid_prices 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?

Gives concrete use cases ('price a commodity in an agent, track inflation inputs, or add market context to a brief') and a worked example (commodity=gold). It does not name the sibling to use for crypto or equities, so the boundary is implied by the commodity list rather than stated.

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