Skip to main content
Glama

Count cars for sale by make, model and price

inventory_facets
Read-onlyIdempotent

Use this when the shopper asks what the dealer has rather than for one car: which makes, models or trims are in stock, which colors, how many trucks, or the cheapest and dearest price, e.g. body_type: "pickup". It counts every matching car, so answer from it instead of counting search results. Do not use it to show cars (that is inventory_search).

It counts every car that matches, not one page: how many in all, and how many of each make, model, trim, body type, drivetrain, fuel and color, plus the lowest and highest year, listed price before fees, and miles. Use it for whole-lot questions ("what trucks do you have?", "which colors does the Tahoe come in?", "do you have anything electric?"), or before searching when you do not know what to filter on. It lists no cars: inventory_search does that, with the make, model or trim the shopper picks.

It takes the same filters as inventory_search: when these stores span the whole country, pass query, make or near, or the answer is too_broad. With near and no rooftop_slug, it counts every dealer in CarEdge's marketplace within the radius, the same cars inventory_search finds there. Each list is most common first and holds at most 20 values. The filters only inventory_search has, such as features or dti_grade, are not taken here.

filter_values holds, under each inventory_search argument's name, the values that argument can take among these cars, with counts, in the spelling it accepts. days_on_market is the fewest and most days these cars have been listed.

price_before_fees is the range of listed prices before the store's fees, in dollars. The cars themselves show price_with_fees, which is higher by the store's fees, so it is not any one car's price. The cheapest car's price_with_fees comes from inventory_search with sort: "price_asc" and limit: 1.

freshness says how old each store's data is, and inventory_unavailable means CarEdge cannot see the lot right now, not that it is empty.

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

Input Schema

NameRequiredDescriptionDefault
makeNoExact make, e.g. 'Chevrolet'.
nearNo
modelNoModel words, e.g. 'Wrangler'.
queryNoA few words, e.g. 'red' or 'electric'.
body_typeNoe.g. 'suv', 'pickup'.
conditionNonew, used or certified; leave out for new and used.
rooftop_slugNoOne store, from `stores_list`.

Output Schema

NameRequiredDescriptionDefault
dataNo
errorNo
freshnessNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.9/5.0
Behavior5/5

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

Annotations cover the read-only/idempotent safety profile, and the description adds behavior beyond that: each list is most-common-first and capped at 20 values, `price_before_fees` excludes store fees and is not any single car's price, `freshness` reports data age, and `inventory_unavailable` means the lot is invisible rather than empty. It also discloses that `inventory_search`-only filters such as `features` and `dti_grade` are rejected here.

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 important routing and scope guidance is front-loaded and the paragraphs are organized by concern (when to use, what it returns, filters, price fields, data quality). It runs long and restates the "does not list cars" point twice, which is the only real waste.

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 7-parameter aggregation tool with an output schema, the description covers the decision to call it, the filter contract, the too_broad guard, the 20-value cap, and the meaning of the derived output fields. Nothing an agent needs in order to call it correctly and interpret the result is missing.

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

Parameters5/5

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

Schema coverage is already 86%, yet the description still adds meaning: the filters mirror `inventory_search`, `near` without `rooftop_slug` widens the count to every CarEdge marketplace dealer within the radius, and unsupported filters are called out. The `body_type: "pickup"` example anchors the filter syntax.

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 opening sentence states a specific verb and resource — it counts every matching car and breaks the lot down by make, model, trim, body type, drivetrain, fuel, color and price — and explicitly contrasts with `inventory_search` ("Do not use it to show cars"). An agent can distinguish the two without reading either 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 concrete when-to-use examples ("what trucks do you have?", "which colors does the Tahoe come in?"), a proactive use case (before searching when the filter is unknown), and an explicit exclusion routing to `inventory_search` for listing cars. It also names the failure condition — passing neither `query`, `make` nor `near` on a national store yields `too_broad`.

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