Skip to main content
Glama
victorshevtsov

Shop MCP Server

customers_by_order_count

Identify top customers by total orders placed, with optional date range filtering. Counts all orders including cancelled, returns customer ID, name, and order count, defaulting to 10 results.

Instructions

Top customers by number of orders placed. NOTE: unlike the other analytic tools, this counts ALL orders (cancelled orders are NOT excluded). Optionally filter by date range on order_date. Each row: { customer_id, name, orders }. Default limit 10.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
toNoOnly include orders with order_date <= this ISO date/datetime.
fromNoOnly include orders with order_date >= this ISO date/datetime.
limitNoMax customers to return.
Install Server

TDQS

A4.4/5.0
Behavior4/5

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

With no annotations provided, the description carries the full burden of behavioral disclosure. It clearly warns that all orders are counted, including canceled ones, and documents the output row shape and default limit. It could additionally mention sorting order or pagination behavior, but the most critical behavioral quirk is explicitly called out.

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 states the core purpose first, then adds the critical caveat about canceled orders, then the optional filtering and output details. Every sentence contributes meaningful information without redundancy.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a relatively simple analytic tool with no output schema, the description covers the essential elements: metric, output row format, a critical counting caveat, optional filters, and default limit. It does not explicitly state the sort order, but 'Top customers' reasonably implies descending order by order count.

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?

The input schema already covers all three parameters with 100% description coverage, so the baseline is 3. The description adds value by specifying that from/to filter on order_date and by revealing the default limit of 10, which is not present in the schema.

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 verb-resource combination: 'Top customers by number of orders placed,' which clearly identifies what the tool computes. It also distinguishes itself from sibling analytic tools by explicitly noting that canceled orders are included, making its scope clear relative to alternatives.

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?

The description provides clear context on when to use the tool by contrasting it with 'other analytic tools' regarding canceled orders, which helps an agent avoid misusing it for exclusion-based analyses. It also mentions optional date filtering, but it does not explicitly name an alternative or state exact conditions for when to prefer a different sibling tool.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/victorshevtsov/shop-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server